sparse-intern-71089
06/15/2022, 9:00 AMechoing-dinner-19531
06/15/2022, 12:21 PMbroad-translator-40115
06/15/2022, 1:34 PMechoing-dinner-19531
06/15/2022, 1:49 PMbroad-translator-40115
06/15/2022, 1:52 PMbroad-translator-40115
06/15/2022, 2:59 PMnode_modules
with what looks like all NodeJS inbuilts. These are already a part of the execution environments for lambdas, and should not be included.
I have no idea why this started to happen.
Any pointers? Is there any way I can control how Pulumi is building / treeshaking? (ala. webpack).broad-translator-40115
06/15/2022, 3:02 PMbroad-translator-40115
06/15/2022, 3:42 PMechoing-dinner-19531
06/15/2022, 3:43 PMechoing-dinner-19531
06/15/2022, 3:44 PM@pulumi/pulumi
)broad-translator-40115
06/15/2022, 3:46 PMbroad-translator-40115
06/15/2022, 3:47 PMwith({ variable })
which causing me issues with this.echoing-dinner-19531
06/15/2022, 3:49 PMUnfortunately, no luck with earlier versions, no.Shame that would of made things easier
Do you know of any way I can customize the serialization process?I don't, it's all black magic to me 😆 I'd suggest raising an issue at our github, can get one of the more "nodejs knowledgeable" team members to have a look.
broad-translator-40115
06/15/2022, 3:50 PMnode_modules
, and it doesn't seem like there's any way to add custom logic to this process 😞
https://www.pulumi.com/docs/intro/concepts/function-serialization/broad-translator-40115
06/15/2022, 4:05 PMlambda.CallbackFunction
takes a codePathOptions.extraExcludePackages
field, and if I systemically add every single dependency here, it seems to work.
My guess is that the node bultins are included in some sub-dependency, and pulumi can't figure out to strip it under nested levels like this.
But at least, this works 👌