You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems the problem of the version of babel-xxx. But I just can solve it, maybe who can help me 😂, thx.
npm run mocha
error output:
>[email protected] mocha /Users/mac/Downloads/play_catch/javascript-problems-and-solutions
> cross-env NODE_ENV=test ./node_modules/.bin/nyc mocha ./src/**/*$FILE*-test.js
/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/_@[email protected]@@babel/helper-plugin-utils/lib/index.js:72
throw Object.assign(err, {
^
Error: Requires Babel "^7.0.0-0", but was loaded with "6.26.3". If you are sure you have a compatible version of @babel/core, it is likely that something in your build process is loading the wrong version. Inspect the stack trace of this error to look for the first entry that doesn't mention "@babel/core" or "babel-core" to see what is calling Babel. at throwVersionError (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/_@[email protected]@@babel/helper-plugin-utils/lib/index.js:65:11) at Object.assertVersion (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/_@[email protected]@@babel/helper-plugin-utils/lib/index.js:13:11) at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-plugin-istanbul/lib/index.js:68:7 at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/_@[email protected]@@babel/helper-plugin-utils/lib/index.js:19:12 at Function.memoisePluginContainer (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:113:13) at Function.normalisePlugin (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:146:32) at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:184:30 at Array.map (<anonymous>) at Function.normalisePlugins (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:158:20) at OptionManager.mergeOptions (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:234:36) at OptionManager.init (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:368:12) at compile (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-register/lib/node.js:103:45) at loader (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-register/lib/node.js:144:14) at require.extensions.<computed> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-register/lib/node.js:154:7) at Object.<anonymous> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/node_modules/append-transform/index.js:62:4) at Module.load (internal/modules/cjs/loader.js:1002:32) at Function.Module._load (internal/modules/cjs/loader.js:901:14) at Module.require (internal/modules/cjs/loader.js:1044:19) at require (internal/modules/cjs/helpers.js:77:18) at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@mocha/lib/mocha.js:250:27 at Array.forEach (<anonymous>) at Mocha.loadFiles (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@mocha/lib/mocha.js:247:14) at Mocha.run (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@mocha/lib/mocha.js:576:10) at Object.<anonymous> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@mocha/bin/_mocha:637:18) at Module._compile (internal/modules/cjs/loader.js:1158:30) at Module.replacementCompile (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/node_modules/append-transform/index.js:58:13) at Module._extensions..js (internal/modules/cjs/loader.js:1178:10) at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/node_modules/append-transform/index.js:62:4 at require.extensions.<computed> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-register/lib/node.js:152:7) at Object.<anonymous> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/node_modules/append-transform/index.js:62:4) at Module.load (internal/modules/cjs/loader.js:1002:32) at Function.Module._load (internal/modules/cjs/loader.js:901:14) at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12) at runMain (/Users/mac/.node-spawn-wrap-55539-79d3b4bf85d8/node:68:10) at Function.<anonymous> (/Users/mac/.node-spawn-wrap-55539-79d3b4bf85d8/node:171:5) at Object.<anonymous> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/bin/wrap.js:23:4) at Module._compile (internal/modules/cjs/loader.js:1158:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10) at Module.load (internal/modules/cjs/loader.js:1002:32) at Function.Module._load (internal/modules/cjs/loader.js:901:14) at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12) at /Users/mac/.node-spawn-wrap-55539-79d3b4bf85d8/node:178:8 at Object.<anonymous> (/Users/mac/.node-spawn-wrap-55539-79d3b4bf85d8/node:181:3) at Module._compile (internal/modules/cjs/loader.js:1158:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10) at Module.load (internal/modules/cjs/loader.js:1002:32) at Function.Module._load (internal/modules/cjs/loader.js:901:14) at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12) at internal/main/run_main_module.js:18:47 { code: 'BABEL_VERSION_UNSUPPORTED', version: '6.26.3', range: '^7.0.0-0'}----------|----------|----------|----------|----------|-------------------|File | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s |----------|----------|----------|----------|----------|-------------------|All files | 0 | 0 | 0 | 0 | |----------|----------|----------|----------|----------|-------------------|npm ERR! code ELIFECYCLEnpm ERR! errno 1npm ERR! [email protected] mocha: `cross-env NODE_ENV=test ./node_modules/.bin/nyc mocha ./src/**/*$FILE*-test.js`npm ERR! Exit status 1npm ERR!npm ERR! Failed at the [email protected] mocha script.npm ERR! This is probably not a problem with npm. There is likely additional logging output above.npm ERR! A complete log of this run can be found in:npm ERR! /Users/mac/.npm/_logs/2020-03-31T05_35_08_282Z-debug.log ✘ RandomYang ~/Downloads/play_catch/javascript-problems-and-solutions master ● npm run mocha >> output.txt/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/_@[email protected]@@babel/helper-plugin-utils/lib/index.js:72 throw Object.assign(err, { ^Error: Requires Babel "^7.0.0-0", but was loaded with "6.26.3". If you are sure you have a compatible version of @babel/core, it is likely that something in your build process is loading the wrong version. Inspect the stack trace of this error to look for the first entry that doesn't mention "@babel/core" or "babel-core" to see what is calling Babel.
at throwVersionError (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/_@[email protected]@@babel/helper-plugin-utils/lib/index.js:65:11)
at Object.assertVersion (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/_@[email protected]@@babel/helper-plugin-utils/lib/index.js:13:11)
at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-plugin-istanbul/lib/index.js:68:7
at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/_@[email protected]@@babel/helper-plugin-utils/lib/index.js:19:12
at Function.memoisePluginContainer (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:113:13)
at Function.normalisePlugin (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:146:32)
at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:184:30
at Array.map (<anonymous>)
at Function.normalisePlugins (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:158:20)
at OptionManager.mergeOptions (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:234:36)
at OptionManager.init (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-core/lib/transformation/file/options/option-manager.js:368:12)
at compile (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-register/lib/node.js:103:45)
at loader (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-register/lib/node.js:144:14)
at require.extensions.<computed> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-register/lib/node.js:154:7)
at Object.<anonymous> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/node_modules/append-transform/index.js:62:4)
at Module.load (internal/modules/cjs/loader.js:1002:32)
at Function.Module._load (internal/modules/cjs/loader.js:901:14)
at Module.require (internal/modules/cjs/loader.js:1044:19)
at require (internal/modules/cjs/helpers.js:77:18)
at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@mocha/lib/mocha.js:250:27
at Array.forEach (<anonymous>)
at Mocha.loadFiles (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@mocha/lib/mocha.js:247:14)
at Mocha.run (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@mocha/lib/mocha.js:576:10)
at Object.<anonymous> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@mocha/bin/_mocha:637:18)
at Module._compile (internal/modules/cjs/loader.js:1158:30)
at Module.replacementCompile (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/node_modules/append-transform/index.js:58:13)
at Module._extensions..js (internal/modules/cjs/loader.js:1178:10)
at /Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/node_modules/append-transform/index.js:62:4
at require.extensions.<computed> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@babel-register/lib/node.js:152:7)
at Object.<anonymous> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/node_modules/append-transform/index.js:62:4)
at Module.load (internal/modules/cjs/loader.js:1002:32)
at Function.Module._load (internal/modules/cjs/loader.js:901:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12)
at runMain (/Users/mac/.node-spawn-wrap-55735-b4037327ec73/node:68:10)
at Function.<anonymous> (/Users/mac/.node-spawn-wrap-55735-b4037327ec73/node:171:5)
at Object.<anonymous> (/Users/mac/Downloads/play_catch/javascript-problems-and-solutions/node_modules/[email protected]@nyc/bin/wrap.js:23:4)
at Module._compile (internal/modules/cjs/loader.js:1158:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10)
at Module.load (internal/modules/cjs/loader.js:1002:32)
at Function.Module._load (internal/modules/cjs/loader.js:901:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12)
at /Users/mac/.node-spawn-wrap-55735-b4037327ec73/node:178:8
at Object.<anonymous> (/Users/mac/.node-spawn-wrap-55735-b4037327ec73/node:181:3)
at Module._compile (internal/modules/cjs/loader.js:1158:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10)
at Module.load (internal/modules/cjs/loader.js:1002:32)
at Function.Module._load (internal/modules/cjs/loader.js:901:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12)
at internal/main/run_main_module.js:18:47 {
code: 'BABEL_VERSION_UNSUPPORTED',
version: '6.26.3',
range: '^7.0.0-0'
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR![email protected] mocha: `cross-env NODE_ENV=test ./node_modules/.bin/nyc mocha ./src/**/*$FILE*-test.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] mocha script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/mac/.npm/_logs/2020-03-31T05_36_12_260Z-debug.log
The text was updated successfully, but these errors were encountered:
It seems the problem of the version of babel-xxx. But I just can solve it, maybe who can help me 😂, thx.
error output:
The text was updated successfully, but these errors were encountered: