Feb 17 2021 12:07 AM
I follow the steps here to create a build definition: https://docs.microsoft.com/en-us/sharepoint/dev/spfx/toolchain/implement-ci-cd-with-azure-devops
locally I have Node 10.23.3 and npm 6.14.11
However when I run the build definition I get several errors
const envPaths = require('env-paths')
^^^^^
SyntaxError: Use of const in strict mode.
at Module._compile (module.js:433:25)
at Object.Module._extensions..js (module.js:468:10)
at Module.load (module.js:350:32)
at Function.Module._load (module.js:306:12)
at Function.Module.runMain (module.js:491:10)
at startup (node.js:119:16)
at node.js:792:3
Build failed
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@2.3.2 (node_modules\watchpack\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.3.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.13 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@2.3.2 (node_modules\jest-haste-map\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.3.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
And at the end of the log:
54037 error code ELIFECYCLE
54038 error errno 8
54039 error deasync@0.1.21 install: `node ./build.js`
54039 error Exit status 8
54040 error Failed at the deasync@0.1.21 install script.
54040 error This is probably not a problem with npm. There is likely additional logging output above.