-
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
Triggers: Error case returns bytes #27113
Labels
@aws-cdk/triggers
Related to the triggers package
bug
This issue is a bug.
node18-upgrade
Any work (bug, feature) related to Node 18 upgrade
sdk-v3-upgrade
Tag issues that are associated to SDK V3 upgrade. Not limited to CR usage of SDK only.
Comments
mrgrain
added
sdk-v3-upgrade
Tag issues that are associated to SDK V3 upgrade. Not limited to CR usage of SDK only.
node18-upgrade
Any work (bug, feature) related to Node 18 upgrade
bug
This issue is a bug.
@aws-cdk/triggers
Related to the triggers package
labels
Sep 12, 2023
mergify bot
pushed a commit
that referenced
this issue
Sep 13, 2023
With Triggers a user can invoke a Lambda Function during every stack deployment. When we migrated the handler code to SDKv3, we overlooked that the return payload from the invoked lambda function is now a `Uint8Array`, and not a string anymore. In the error case, we attempt to `JSON.parse()` the error payload which then resulted in a list of bytes being returned to the user. Updated the handler test case to use correct mocks, including returning a payload that is a Uint8Array. Closes #27113 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
|
mikewrighton
pushed a commit
that referenced
this issue
Sep 14, 2023
With Triggers a user can invoke a Lambda Function during every stack deployment. When we migrated the handler code to SDKv3, we overlooked that the return payload from the invoked lambda function is now a `Uint8Array`, and not a string anymore. In the error case, we attempt to `JSON.parse()` the error payload which then resulted in a list of bytes being returned to the user. Updated the handler test case to use correct mocks, including returning a payload that is a Uint8Array. Closes #27113 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
@aws-cdk/triggers
Related to the triggers package
bug
This issue is a bug.
node18-upgrade
Any work (bug, feature) related to Node 18 upgrade
sdk-v3-upgrade
Tag issues that are associated to SDK V3 upgrade. Not limited to CR usage of SDK only.
In the integ test
triggers/test/integ.triggers.ts
Go and find the test handler in the
lib
directory and break it.Run the test case and see it fail with an error similar to the one below.
This is bad for users of Triggers, since they won't be able to debug their Triggers anymore.
The text was updated successfully, but these errors were encountered: