为 twilio flex 插件安装包时出现 NPM 错误
NPM error while installing packages for twilio flex plugins
我在安装 NPM 包或 运行 脚本时遇到错误 npm start
Can you please help me to solve the problem
Here is the errors detail
这是日志详细信息,已发送至 .npm/_logs
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli '/Users/irfan/.nvm/versions/node/v14.2.0/bin/node',
1 verbose cli '/Users/irfan/.nvm/versions/node/v14.2.0/bin/npm',
1 verbose cli 'i'
1 verbose cli ]
2 info using npm@6.14.4
3 info using node@v14.2.0
4 verbose npm-session 24b8946923194204
5 silly install runPreinstallTopLevelLifecycles
6 silly preinstall plugin-getting-started@0.0.0
7 info lifecycle plugin-getting-started@0.0.0~preinstall: plugin-getting-started@0.0.0
8 silly install loadCurrentTree
9 silly install readLocalPackageData
10 timing stage:loadCurrentTree Completed in 2419ms
11 silly install loadIdealTree
12 silly install cloneCurrentTreeToIdealTree
13 timing stage:loadIdealTree:cloneCurrentTree Completed in 21ms
14 silly install loadShrinkwrap
15 timing stage:loadIdealTree:loadShrinkwrap Completed in 1603ms
16 silly install loadAllDepsIntoIdealTree
17 timing stage:loadIdealTree:loadAllDepsIntoIdealTree Completed in 1781ms
18 timing stage:loadIdealTree Completed in 4100ms
19 silly currentTree plugin-getting-started@0.0.0
19 silly currentTree ├── @babel/code-frame@7.8.3
.
.
.
20 silly idealTree ├── xmlchars@2.2.0
20 silly idealTree ├── xmlhttprequest@1.8.0
20 silly idealTree ├── xregexp@4.3.0
20 silly idealTree ├── xtend@4.0.2
20 silly idealTree ├── y18n@4.0.0
20 silly idealTree ├── yallist@2.1.2
20 silly idealTree ├── yaml@1.9.2
20 silly idealTree ├── yargs-parser@13.1.2
20 silly idealTree └─┬ yargs@13.3.2
20 silly idealTree └── string-width@3.1.0
21 silly install generateActionsToTake
22 timing stage:generateActionsToTake Completed in 214ms
23 silly diffTrees action count 0
24 silly decomposeActions action count 0
25 silly install executeActions
26 silly doSerial global-install 0
27 verbose correctMkdir /Users/irfan/.npm/_locks correctMkdir not in flight; initializing
28 verbose lock using /Users/irfan/.npm/_locks/staging-bec3f2539599f485.lock for /Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started/node_modules/.staging
29 silly doParallel extract 0
30 silly doReverseSerial unbuild 0
31 silly doSerial remove 0
32 silly doSerial move 0
33 silly doSerial finalize 0
34 silly doParallel refresh-package-json 0
35 silly doParallel preinstall 0
36 silly doSerial build 0
37 silly doSerial global-link 0
38 silly doParallel update-linked 0
39 silly doSerial install 0
40 silly doSerial postinstall 0
41 verbose unlock done using /Users/irfan/.npm/_locks/staging-bec3f2539599f485.lock for /Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started/node_modules/.staging
42 timing stage:executeActions Completed in 14ms
43 timing stage:rollbackFailedOptional Completed in 0ms
44 silly install runPostinstallTopLevelLifecycles
45 silly build plugin-getting-started@0.0.0
46 info linkStuff plugin-getting-started@0.0.0
47 silly linkStuff plugin-getting-started@0.0.0 has /Users/irfan/Desktop/Projects/Clients/Twilio Flex as its parent node_modules
48 silly install plugin-getting-started@0.0.0
49 info lifecycle plugin-getting-started@0.0.0~install: plugin-getting-started@0.0.0
50 silly postinstall plugin-getting-started@0.0.0
51 info lifecycle plugin-getting-started@0.0.0~postinstall: plugin-getting-started@0.0.0
52 verbose lifecycle plugin-getting-started@0.0.0~postinstall: unsafe-perm in lifecycle true
53 verbose lifecycle plugin-getting-started@0.0.0~postinstall: PATH: /Users/irfan/.nvm/versions/node/v14.2.0/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started/node_modules/.bin:/Users/irfan/.nvm/versions/node/v14.2.0/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/Apple/usr/bin:/Library/Frameworks/Mono.framework/Versions/Current/Commands:/Users/irfan/utils/flutter/bin
54 verbose lifecycle plugin-getting-started@0.0.0~postinstall: CWD: /Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started
55 silly lifecycle plugin-getting-started@0.0.0~postinstall: Args: [ '-c', 'npm run bootstrap' ]
56 silly lifecycle plugin-getting-started@0.0.0~postinstall: Returned: code: 1 signal: null
57 info lifecycle plugin-getting-started@0.0.0~postinstall: Failed to exec postinstall script
58 verbose stack Error: plugin-getting-started@0.0.0 postinstall: `npm run bootstrap`
58 verbose stack Exit status 1
58 verbose stack at EventEmitter. (/Users/irfan/.nvm/versions/node/v14.2.0/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
58 verbose stack at EventEmitter.emit (events.js:315:20)
58 verbose stack at ChildProcess. (/Users/irfan/.nvm/versions/node/v14.2.0/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
58 verbose stack at ChildProcess.emit (events.js:315:20)
58 verbose stack at maybeClose (internal/child_process.js:1051:16)
58 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:287:5)
59 verbose pkgid plugin-getting-started@0.0.0
60 verbose cwd /Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started
61 verbose Darwin 19.3.0
62 verbose argv "/Users/irfan/.nvm/versions/node/v14.2.0/bin/node" "/Users/irfan/.nvm/versions/node/v14.2.0/bin/npm" "i"
63 verbose node v14.2.0
64 verbose npm v6.14.4
65 error code ELIFECYCLE
66 error errno 1
67 error plugin-getting-started@0.0.0 postinstall: `npm run bootstrap`
67 error Exit status 1
68 error Failed at the plugin-getting-started@0.0.0 postinstall script.
68 error This is probably not a problem with npm. There is likely additional logging output above.
69 verbose exit [ 1, true ]
不确定这是否是完全相同的问题,但我遇到了类似的问题。就我而言,这是在 craco-config-flex-plugin 和 react 中要求的 webpack 版本不匹配-脚本.
我 运行 使用 npm install -g create-flex-plugin[=19= 再次安装 create-flex-plugin 命令], 然后按照步骤重新创建我的插件,它很旧。
我在安装 NPM 包或 运行 脚本时遇到错误 npm start
Can you please help me to solve the problem Here is the errors detail
这是日志详细信息,已发送至 .npm/_logs
0 info it worked if it ends with ok 1 verbose cli [ 1 verbose cli '/Users/irfan/.nvm/versions/node/v14.2.0/bin/node', 1 verbose cli '/Users/irfan/.nvm/versions/node/v14.2.0/bin/npm', 1 verbose cli 'i' 1 verbose cli ] 2 info using npm@6.14.4 3 info using node@v14.2.0 4 verbose npm-session 24b8946923194204 5 silly install runPreinstallTopLevelLifecycles 6 silly preinstall plugin-getting-started@0.0.0 7 info lifecycle plugin-getting-started@0.0.0~preinstall: plugin-getting-started@0.0.0 8 silly install loadCurrentTree 9 silly install readLocalPackageData 10 timing stage:loadCurrentTree Completed in 2419ms 11 silly install loadIdealTree 12 silly install cloneCurrentTreeToIdealTree 13 timing stage:loadIdealTree:cloneCurrentTree Completed in 21ms 14 silly install loadShrinkwrap 15 timing stage:loadIdealTree:loadShrinkwrap Completed in 1603ms 16 silly install loadAllDepsIntoIdealTree 17 timing stage:loadIdealTree:loadAllDepsIntoIdealTree Completed in 1781ms 18 timing stage:loadIdealTree Completed in 4100ms 19 silly currentTree plugin-getting-started@0.0.0 19 silly currentTree ├── @babel/code-frame@7.8.3 . . . 20 silly idealTree ├── xmlchars@2.2.0 20 silly idealTree ├── xmlhttprequest@1.8.0 20 silly idealTree ├── xregexp@4.3.0 20 silly idealTree ├── xtend@4.0.2 20 silly idealTree ├── y18n@4.0.0 20 silly idealTree ├── yallist@2.1.2 20 silly idealTree ├── yaml@1.9.2 20 silly idealTree ├── yargs-parser@13.1.2 20 silly idealTree └─┬ yargs@13.3.2 20 silly idealTree └── string-width@3.1.0 21 silly install generateActionsToTake 22 timing stage:generateActionsToTake Completed in 214ms 23 silly diffTrees action count 0 24 silly decomposeActions action count 0 25 silly install executeActions 26 silly doSerial global-install 0 27 verbose correctMkdir /Users/irfan/.npm/_locks correctMkdir not in flight; initializing 28 verbose lock using /Users/irfan/.npm/_locks/staging-bec3f2539599f485.lock for /Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started/node_modules/.staging 29 silly doParallel extract 0 30 silly doReverseSerial unbuild 0 31 silly doSerial remove 0 32 silly doSerial move 0 33 silly doSerial finalize 0 34 silly doParallel refresh-package-json 0 35 silly doParallel preinstall 0 36 silly doSerial build 0 37 silly doSerial global-link 0 38 silly doParallel update-linked 0 39 silly doSerial install 0 40 silly doSerial postinstall 0 41 verbose unlock done using /Users/irfan/.npm/_locks/staging-bec3f2539599f485.lock for /Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started/node_modules/.staging 42 timing stage:executeActions Completed in 14ms 43 timing stage:rollbackFailedOptional Completed in 0ms 44 silly install runPostinstallTopLevelLifecycles 45 silly build plugin-getting-started@0.0.0 46 info linkStuff plugin-getting-started@0.0.0 47 silly linkStuff plugin-getting-started@0.0.0 has /Users/irfan/Desktop/Projects/Clients/Twilio Flex as its parent node_modules 48 silly install plugin-getting-started@0.0.0 49 info lifecycle plugin-getting-started@0.0.0~install: plugin-getting-started@0.0.0 50 silly postinstall plugin-getting-started@0.0.0 51 info lifecycle plugin-getting-started@0.0.0~postinstall: plugin-getting-started@0.0.0 52 verbose lifecycle plugin-getting-started@0.0.0~postinstall: unsafe-perm in lifecycle true 53 verbose lifecycle plugin-getting-started@0.0.0~postinstall: PATH: /Users/irfan/.nvm/versions/node/v14.2.0/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started/node_modules/.bin:/Users/irfan/.nvm/versions/node/v14.2.0/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/Apple/usr/bin:/Library/Frameworks/Mono.framework/Versions/Current/Commands:/Users/irfan/utils/flutter/bin 54 verbose lifecycle plugin-getting-started@0.0.0~postinstall: CWD: /Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started 55 silly lifecycle plugin-getting-started@0.0.0~postinstall: Args: [ '-c', 'npm run bootstrap' ] 56 silly lifecycle plugin-getting-started@0.0.0~postinstall: Returned: code: 1 signal: null 57 info lifecycle plugin-getting-started@0.0.0~postinstall: Failed to exec postinstall script 58 verbose stack Error: plugin-getting-started@0.0.0 postinstall: `npm run bootstrap` 58 verbose stack Exit status 1 58 verbose stack at EventEmitter. (/Users/irfan/.nvm/versions/node/v14.2.0/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16) 58 verbose stack at EventEmitter.emit (events.js:315:20) 58 verbose stack at ChildProcess. (/Users/irfan/.nvm/versions/node/v14.2.0/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14) 58 verbose stack at ChildProcess.emit (events.js:315:20) 58 verbose stack at maybeClose (internal/child_process.js:1051:16) 58 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:287:5) 59 verbose pkgid plugin-getting-started@0.0.0 60 verbose cwd /Users/irfan/Desktop/Projects/Clients/Twilio Flex/plugin-getting-started 61 verbose Darwin 19.3.0 62 verbose argv "/Users/irfan/.nvm/versions/node/v14.2.0/bin/node" "/Users/irfan/.nvm/versions/node/v14.2.0/bin/npm" "i" 63 verbose node v14.2.0 64 verbose npm v6.14.4 65 error code ELIFECYCLE 66 error errno 1 67 error plugin-getting-started@0.0.0 postinstall: `npm run bootstrap` 67 error Exit status 1 68 error Failed at the plugin-getting-started@0.0.0 postinstall script. 68 error This is probably not a problem with npm. There is likely additional logging output above. 69 verbose exit [ 1, true ]
不确定这是否是完全相同的问题,但我遇到了类似的问题。就我而言,这是在 craco-config-flex-plugin 和 react 中要求的 webpack 版本不匹配-脚本.
我 运行 使用 npm install -g create-flex-plugin[=19= 再次安装 create-flex-plugin 命令], 然后按照步骤重新创建我的插件,它很旧。