-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
aws-stepfunctions: state.Retry is not iterable #29274
aws-stepfunctions: state.Retry is not iterable #29274
Comments
The problem seems to be here: https://github.com/aws/aws-cdk/blob/main/packages/aws-cdk-lib/aws-stepfunctions/lib/states/custom-state.ts#L74
This will cause the The solution would be to make the merge a bit smarter and also to validate |
I agree - which is probably why we're not getting an error when specifying the error strategy through |
…29403) ### Issue # (if applicable) Closes #29274 ### Reason for this change CDK users were unable to specify their retry strategy if it was specified inline in their ASL state machine definition ### Description of changes Checks if the state definition has an inline retry policy defined. If it does, add it to the existing strategy defined using `addRetry` (if there is one defined, this is where it was failing before) ### Description of how you validated changes Added unit and integration tests ### Checklist - [x] My code adheres to the [CONTRIBUTING GUIDE](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and [DESIGN GUIDELINES](https://github.com/aws/aws-cdk/blob/main/docs/DESIGN_GUIDELINES.md) ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
|
In which file do we need to make this change? I am getting a same error with "aws-cdk-lib" : "^2.118.0" version @abdelnn |
@abhi-shek01 The fix was released in the most recent version of aws-cdk https://github.com/aws/aws-cdk/releases/tag/v2.133.0 |
Describe the bug
When creating a CustomState within a state machine, and specifying the retry behaviour within the inline definition, we get back an error saying
state.Retry is not iterable
. However, adding the retry behaviour separately with.addRetry
seems to fix this issue. I strongly suspects this is linked to the following PR #28793Expected Behavior
The state machine should create successfully
Current Behavior
Throws
Reproduction Steps
Creating a state machine with the following state
However, doing the following works:
Possible Solution
No response
Additional Information/Context
No response
CDK CLI Version
2.128.0
Framework Version
No response
Node.js Version
v21.6.2
OS
Mac 14.3.1
Language
TypeScript
Language Version
No response
Other information
No response
The text was updated successfully, but these errors were encountered: