Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(sdk-python): Port in-line expressions to Python SDK #1166
feat(sdk-python): Port in-line expressions to Python SDK #1166
Changes from 9 commits
9587da0
3c5fe82
b1eebae
1e5d0af
3f567a0
ae54914
42caf83
1d8fd25
2c1e250
af79268
338da9d
78f817b
cdf2d4c
08e1e49
8e3cfbc
4d524b7
0e07334
39c45f8
1821425
d494bba
17356af
301e4be
5313a55
ca93fbd
a011a8d
11954d4
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if the default value is None use
= None
hereOptional[WorkflowThread]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not totally convince if we should do this.
Actually we can do something like:
Even though we can implement it similar to java, I would prefer to reduce the dependencies in python.
Circular dependencies errors are very common in python. They (python devs) are going to get rid of it, and make it a more java like language, but i do not know when.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sauljabin I agree with your proposal, it is unnecessary to depend on the parent condition methods when creating a new WorkflowCondition is so simple. If the code for creating a new WorkflowCondition were more complex, it may make sense to centralize it in one place and rely on this dependency injection or another class to hold the methods.
There is one additional method that may not make sense to port without injecting the parent thread dependency:
Without injecting the parent WorkflowThread at the constructor, this method may not make sense or be easy to use. Instead, we would have to pass it to the method as an argument, which would not save the user much code and (in my opinion) be less readable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right, I did not see the mutate
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 underscore for internal 2 for language related ones.
example
__init__
2 underscore