SalesforceCommerceCloud / sfcc-ci

Salesforce Commerce Cloud CLI
https://npmjs.com/package/sfcc-ci
BSD 3-Clause "New" or "Revised" License
230 stars 92 forks source link

With the recent commit which happened 8 hours ago on Nov 16 2022 in master branch, our builds are failing. #335

Open vvratnas opened 1 year ago

vvratnas commented 1 year ago

sfcc-ci Version

2.9.1

NodeJS Version

10.24.0

sfcc-ci Path

No response

Host OS Details

No response

What happened?

In the console output, we are seeing below error: npm ERR! prepareGitDep 1> npm ERR! prepareGitDep > sfcc-ci@2.9.1 prepare /home/svcjenkins/.npm/_cacache/tmp/git-clone-bb1583c7 npm ERR! prepareGitDep > npm run snyk-protect npm ERR! prepareGitDep npm ERR! prepareGitDep npm ERR! prepareGitDep > sfcc-ci@2.9.1 snyk-protect /home/svcjenkins/.npm/_cacache/tmp/git-clone-bb1583c7 npm ERR! prepareGitDep > snyk protect npm ERR! prepareGitDep npm ERR! prepareGitDep npm ERR! prepareGitDep 2> npm WARN install Usage of the --dev option is deprecated. Use --also=dev instead. npm ERR! prepareGitDep Node.js version 10.24.0 is an unsupported Node.js runtime! Supported runtime range is '>= 12.0.0' npm ERR! prepareGitDep Please upgrade your Node.js runtime. The last version of Snyk CLI that supports Node.js v8 is v1.454.0. npm ERR! prepareGitDep npm ERR! code ELIFECYCLE npm ERR! prepareGitDep npm ERR! errno 2 npm ERR! prepareGitDep npm ERR! sfcc-ci@2.9.1 snyk-protect: snyk protect npm ERR! prepareGitDep npm ERR! Exit status 2 npm ERR! prepareGitDep npm ERR! npm ERR! prepareGitDep npm ERR! Failed at the sfcc-ci@2.9.1 snyk-protect script. npm ERR! prepareGitDep npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! prepareGitDep npm ERR! prepareGitDep npm ERR! A complete log of this run can be found in: npm ERR! prepareGitDep npm ERR! /home/svcjenkins/.npm/_logs/2022-11-16T21_45_17_269Z-debug.log npm ERR! prepareGitDep npm ERR! code ELIFECYCLE npm ERR! prepareGitDep npm ERR! errno 2 npm ERR! prepareGitDep npm ERR! sfcc-ci@2.9.1 prepare: npm run snyk-protect npm ERR! prepareGitDep npm ERR! Exit status 2 npm ERR! prepareGitDep npm ERR! npm ERR! prepareGitDep npm ERR! Failed at the sfcc-ci@2.9.1 prepare script. npm ERR! prepareGitDep npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! prepareGitDep npm ERR! prepareGitDep npm ERR! A complete log of this run can be found in: npm ERR! prepareGitDep npm ERR! /home/svcjenkins/.npm/_logs/2022-11-16T21_45_17_324Z-debug.log npm ERR! prepareGitDep npm ERR! premature close

Relevant log output

No response

clavery commented 1 year ago

Hi @vvratnas. It seems a couple things may be happening here.

  1. You seem to be installing sfcc-ci via a git dependency. That is, instead of the published version at npm: https://www.npmjs.com/package/sfcc-ci
  2. Given changes from today certain packages are updated that are not supported by your version of node (10.24.0 which is a very old version).

I recommend one of two things:

  1. Install sfcc-ci in your build system from NPM: https://www.npmjs.com/package/sfcc-ci
  2. If you must install sfcc-ci from git do not use the master branch. Instead use a tag. The most recent version at npm can be found at this tag https://github.com/SalesforceCommerceCloud/sfcc-ci/tree/v2.9.1