Skip to content

error when serverless uses aws-sdk/client-cloudformationΒ #6779

@mlopez34

Description

@mlopez34

Checkboxes for prior research

Describe the bug

have recently gotten this error:

....
/usr/local/lib/node_modules/serverless/node_modules/@aws-sdk/client-cloudformation/dist-cjs/index.js:343
  static {
         ^

SyntaxError: Unexpected token '{'
    at wrapSafe (internal/modules/cjs/loader.js:1029:16)
    .....

When using serverless to deploy to AWS using github actions
9 hours ago from this post github action successfully deployed, i noticed first failure 4 hours ago and all since then.
noticed that the latest update for client-cloudformation on npm was 7 hours ago so it is most likely this latest update.

currently using the following on github actions:

Have not tested upgrading to Node v20, but that is probably not the solution since I ran locally successfully, and i have node v18.20.2, serverless 3.38.0, npm 10.9.1

Can provide more info if needed
Thanks

Regression Issue

  • Select this option if this issue appears to be a regression.

SDK version number

@aws-sdk/[email protected]

Which JavaScript Runtime is this issue in?

Node.js

Details of the browser/Node.js/ReactNative version

Node v 18.20.5 [email protected] npm: 10.8.2

Reproduction Steps

Ubuntu v 24.04.1
Node v 18.20.5
[email protected]
npm: 10.8.2

Observed Behavior

on github actions, when deploying using serverless which uses this package @aws-sdk/client-cloudformation, the deployment fails since latest update

Expected Behavior

successful deployment

Possible Solution

No response

Additional Information/Context

No response

Metadata

Metadata

Assignees

Labels

bugThis issue is a bug.p1This is a high priority issuepotential-regressionMarking this issue as a potential regression to be checked by team member

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions