-
Notifications
You must be signed in to change notification settings - Fork 4k
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
[stepfunctions-tasks] Complaining "JsiiException: Maximum call stack size exceeded" when building EcsRunTask #9319
Comments
I ran into a similar problem when defining an ECS task. It seems that when a I was able to get this working by implementing a quick monkey-patch on top of json-path's recurseObject to stop on circular references, but I'm hesitant to make it a PR, as I'm not sure if this is the best way to go. Perhaps there's is a better way, e.g. to specify that we only care for environment / command overrides? |
Has there been any updates on this? |
I do have a monkey patch for this that I use myself, but this is unfortunately for npm-based workflows (using patch-package). Haven't had a chance to go through the process of creating a pull request yet to support C# / Java / rest of the tooling options. |
I haven't had a chance to dig into the repo itself. Going to give it a shot myself to try and build the C# package. As far as I understand, C# package uses the ts/js files so I could try to utilize your monkey patch for now. |
If you try to build the C# package, try using this patch instead on the original repo - this applies to the source, rather than the JS output like the other one. Hopefully this will also fix the C# package out of the box. It was originally written for v1.63.0, but it could work on 1.70 as well, if there haven't been many changes in between. |
@t6nn If you can push for this as a PR and get it into the actual codebase for 1.72.0, that would be fantastic. |
…ing encounters a circular object graph Fixes aws#9319 - stack overflow when EcsRunTask is used with WAIT_FOR_TASK_TOKEN integration pattern. Implements circular reference detection by keeping a list of visited objects while resolving all referenced JSONPaths. For the particular issue, a circular reference occurs by ECS container overrides pointing to the container definition, which in turn has a circular dependency with the task definition.
…encounters a circular object graph (#11225) This change fixes #9319 where if an EcsRunTask step was used with the WAIT_FOR_TASK_TOKEN integration pattern, the logic for finding all referenced JSONPath elements in container overrides would encounter a circular reference and terminate with a stack overflow. With this change, `JsonPath.recurseObject` and `JsonPath.recurseArray` would maintain a list of already visited objects and use it to prune circular references back to an already visited object. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
|
Still having this issue when using cdk 1.92.00 (typescript) and since this is approaching 1 year mark of being show stopper for using fargate in step functions in meaningful way (as i would imagine signaling back for success after task is done is somewhat important feature for step function logic) even "monkey-patch" is better than nothing. |
that is slightly odd, your repo uses custom construct, but to my understanding it still uses the same EcsRunTask i am using, but I am still getting "Maximum call stack size exceeded". |
Hmm, interesting. I would double check to make sure in your package-lock.json file that all the dependency versions match up to what your intended versions are. I know that can sometimes be a sneaky way for bugs to appear... |
doh! |
Complaining "JsiiException: Maximum call stack size exceeded" when building EcsRunTask
Reproduction Steps
Error Log
Environment
Other
This is 🐛 Bug Report
The text was updated successfully, but these errors were encountered: