Skip to content

[Bug] Converting payloads and other exception-possible actions done after command creation #564

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

Closed
cretz opened this issue Jun 27, 2024 · 0 comments · Fixed by #591
Closed
Labels
bug Something isn't working

Comments

@cretz
Copy link
Member

cretz commented Jun 27, 2024

Describe the bug

When scheduling an activity (and presumably in many cases), we create the command before we try to serialize the parameters. This can cause an issue where if it fails, the command is still in the activations commands list but incomplete. This is usually not a big deal since it's supposed to be a task failure which does not send commands and waits for code fix. But some users are not allowing these failures to be task failures and therefore you get a half-complete command going to Core.

To replicate, simply convert a serialization error for a parameter to an activity to an application error.

There are a couple of approaches to fix. We can take the more drastic approach of not creating the command until we have built it (changes a lot since we are doing a proto-lib-encouraged approach of creating the thing before populating it today). Or we can just make sure to just do things that can fail before creating the command.

Relates to and closes #540.

@cretz cretz added the bug Something isn't working label Jun 27, 2024
cretz added a commit to cretz/temporal-sdk-python that referenced this issue Jul 23, 2024
@cretz cretz closed this as completed in #591 Aug 9, 2024
@cretz cretz closed this as completed in a5b9661 Aug 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant