question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

nodejs14.x support for SAM CLI

See original GitHub issue

Description:

Right now there is no support for Node 14 and whenever I go to build my application running SAM package/build I get the following error:

Building codeuri: functions/sync runtime: nodejs14.x metadata: {} functions: ['SyncFunction']
--
980 |  
981 | Build Failed
982 | Error: 'nodejs14.x' runtime is not supported

Steps to reproduce:

Create a SAM Function that looks like this:

  SyncFunction:
    Type: AWS::Serverless::Function
    Properties:
      CodeUri: functions/sync
      Handler: index.lambdaHandler
      Runtime: nodejs14.x
 ...

Then try and run SAM build, package, you will see this:

Building codeuri: functions/sync runtime: nodejs14.x metadata: {} functions: ['SyncFunction']
--
980 |  
981 | Build Failed
982 | Error: 'nodejs14.x' runtime is not supported

Observed result:

Building codeuri: functions/sync runtime: nodejs14.x metadata: {} functions: ['SyncFunction']
--
980 |  
981 | Build Failed
982 | Error: 'nodejs14.x' runtime is not supported

Expected result:

I wold expect it to run and pass through, honouring Node 14 support 👍

Additional environment details (Ex: Windows, Mac, Amazon Linux etc)

  1. OS: Linux
  2. sam --version: SAM CLI, version 1.16.0
  3. AWS region: `us-east-1z

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
wchengrucommented, Feb 8, 2021

If you are using Linux, the recommended install method now is through brew. https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-sam-cli-install-linux.html If you want to use pip install, the package name of SAM CLI is aws-sam-cli: pip install --upgrade aws-sam-cli

0reactions
NickLiffencommented, Feb 8, 2021

Sorry I copied and pasted the wrong line of code 🤦 Thnks @wchengru and @mgrandis this is now all working with the latest version thank you 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

AWS Lambda now supports Node.js 14
You can now author AWS Lambda functions in Node.js 14 and use its new ... use AWS CLI, AWS Serverless Application Model (AWS...
Read more >
build Failed Error: 'nodejs14.x' runtime is not supported
build Failed Error: 'nodejs14.x' runtime is not supported. In this case, there are two options from what I've ... brew install aws-sam-cli.
Read more >
cli emulation of node14 isn't updated to cli version 1.17
x:latest isn't updated to sam cli 1.17 yet, and therefore nodejs14.x isn't supported as runtime. Steps to reproduce: # docker run -it amazon/aws ......
Read more >
amazon/aws-sam-cli-build-image-nodejs14.x
amazon/aws-sam-cli-build-image-nodejs14.x. Verified Publisher. By Amazon Web Services • Updated a day ago. Image. OverviewTags. No overview available.
Read more >
Building AWS SAM TypeScript Projects With Jest Support
Working With TypeScript and Jest Support: An AWS SAM Tutorial ... Description: AWS SAM Boilerplate Using TypeScript Globals: Function: Runtime: nodejs14.x ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found