Skip to content
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

fix: all aws-cdk-lib custom resources now use Node18 #26212

Merged
merged 26 commits into from
Jul 6, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
633a498
aws-cdk-lib/triggers
MrArnoldPalmer Jun 7, 2023
e1cee3d
edge function
MrArnoldPalmer Jun 9, 2023
ac487ca
ecr auto-delete
MrArnoldPalmer Jun 9, 2023
6ff96d8
aws-s3 auto-delete-objects
MrArnoldPalmer Jun 9, 2023
369505a
Merge branch 'main' of github.com:aws/aws-cdk into feat/aws-cdk-lib-s…
MrArnoldPalmer Jun 29, 2023
44520cc
change remaining CR runtimes and SDK usage
MrArnoldPalmer Jul 3, 2023
8be6406
Merge branch 'main' of github.com:aws/aws-cdk into feat/aws-cdk-lib-s…
MrArnoldPalmer Jul 3, 2023
f467ca9
Merge branch 'main' of github.com:aws/aws-cdk into feat/aws-cdk-lib-s…
MrArnoldPalmer Jul 5, 2023
620d2b4
fix custom-resource-handlers tests
MrArnoldPalmer Jul 5, 2023
74540f3
fix some tests
MrArnoldPalmer Jul 5, 2023
b3d6654
fix custom-resources tests
MrArnoldPalmer Jul 5, 2023
f2b78cc
fix more tests and unify versions
MrArnoldPalmer Jul 5, 2023
5072965
fix more tests
MrArnoldPalmer Jul 6, 2023
5c09989
fix deps
MrArnoldPalmer Jul 6, 2023
302259c
fix dependencies
MrArnoldPalmer Jul 6, 2023
1fb4d8e
Revert "fix dependencies"
MrArnoldPalmer Jul 6, 2023
153f5a9
unify dependencies for type errors
MrArnoldPalmer Jul 6, 2023
e7020a0
update integ tests to diff assets and snapshots
MrArnoldPalmer Jul 6, 2023
0f9c867
Merge branch 'main' of github.com:aws/aws-cdk into feat/aws-cdk-lib-s…
MrArnoldPalmer Jul 6, 2023
f75a150
update glue test snapshot
MrArnoldPalmer Jul 6, 2023
5541894
update alpha module snapshots
MrArnoldPalmer Jul 6, 2023
cb4aa4d
chore: download Noctilucent instead fo building it
rix0rrr Jul 6, 2023
dec7e85
Merge remote-tracking branch 'origin/huijbers/download-nocti' into fe…
rix0rrr Jul 6, 2023
9d4bafd
Snappy
rix0rrr Jul 6, 2023
ae6a2b0
Snapshots
rix0rrr Jul 6, 2023
d3b0b32
Merge branch 'main' into feat/aws-cdk-lib-sdk-v3
mergify[bot] Jul 6, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix custom-resources tests
  • Loading branch information
MrArnoldPalmer committed Jul 5, 2023
commit b3d6654aa355f9e13920e454562e2d31e054db1b
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,9 @@ async function invokeUserFunction<A extends { ResponseURL: '...' }>(functionArnE

function parseJsonPayload(payload: any): any {
if (!payload) { return { }; }
const text = payload.toString();
// sdk v3 returns payloads in Uint8Array, either it or a string or Buffer
// can be cast into a buffer and then decoded.
let text = new TextDecoder().decode(Buffer.from(payload));
try {
return JSON.parse(text);
} catch {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,10 @@ export async function invokeFunctionMock(req: InvokeCommandInput): Promise<Invoc
}

return {
Payload: new TextEncoder().encode(JSON.stringify(ret)),
Payload: ret
? new TextEncoder().encode(typeof ret !== 'string' ? JSON.stringify(ret) : ret)
// handle undefined explicitly for mocks so we don't encode it
: undefined,
};
} catch (e: any) {
return {
Expand Down