流星1.7 ecmascript和babel-compiler软件包错误

时间:2018-07-12 15:26:22

标签: meteor babel

我正在更新我的项目之一,以使用1.4版流星1.7版,并且发生以下错误。我尝试重新安装流星,降级到1.6,还添加了.babelrc文件,但是没有运气。我认为该错误与ecmascriptbabel-compiler软件包版本有关,因为它在1.4版时可以正常工作。有谁知道如何解决这个问题?非常感谢你!

   While processing files with ecmascript (for target os.osx.x86_64):

   /Users/lauyi/.meteor/packages/meteor-tool/.1.7.0_3.w8zcf.uowlh++os.osx.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.osx.x86_64/tools/isobuild/compiler-plugin.js:447:61:
   Cannot read property 'id' of null
   at InputFile.resolve
   (/Users/lauyi/.meteor/packages/meteor-tool/.1.7.0_3.w8zcf.uowlh++os.osx.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.osx.x86_64/tools/isobuild/compiler-plugin.js:447:61)
   at packages/babel-compiler.js:487:23
   at Array.some (<anonymous>:null:null)
   at requireWithPrefixes (packages/babel-compiler.js:482:26)
   at requireWithPath (packages/babel-compiler.js:415:14)
   at resolveHelper (packages/babel-compiler.js:387:24)
   at packages/babel-compiler.js:360:19
   at Array.forEach (<anonymous>:null:null)
   at walkHelper (packages/babel-compiler.js:359:10)
   at walkBabelRC (packages/babel-compiler.js:340:24)
   at BabelCompiler.BCp._inferHelper (packages/babel-compiler.js:442:17)
   at BabelCompiler.BCp._inferFromBabelRc (packages/babel-compiler.js:287:14)
   at BabelCompiler.BCp.inferExtraBabelOptions (packages/babel-compiler.js:261:10)
   at BabelCompiler.BCp.processOneFileForTarget (packages/babel-compiler.js:184:10)
   at BabelCompiler.<anonymous> (packages/babel-compiler.js:115:26)
   at Array.forEach (<anonymous>:null:null)
   at BabelCompiler.BCp.processFilesForTarget (packages/babel-compiler.js:114:14)

这是我的package.json

{
  "browserslist": [
    "last 2 versions",
    "> 1%"
  ],
  "dependencies": {
    "@babel/runtime": "^7.0.0-beta.53",
    "babel-polyfill": "^6.22.0",
    "babel-runtime": "^6.20.0",
    "browser-compress-image": "^1.0.2",
    "datatables.net-bs": "^1.10.15",
    "exif-js": "^2.3.0",
    "html-purify": "^1.1.0",
    "image-compressor": "github:xkeshi/image-compressor",
    "intl": "^1.2.5",
    "intl-locales-supported": "^1.0.0",
    "jquery": "^2.2.4",
    "knox": "^0.9.2",
    "meteor-node-stubs": "^0.3.3",
    "moment": "^2.17.1",
    "mongo-xlsx": "^1.0.12",
    "open-graph-scraper": "^2.4.2",
    "prop-types": "^15.5.8",
    "rc-tabs": "^9.1.4",
    "react": "^0.14.8",
    "react-addons-create-fragment": "^0.14.8",
    "react-addons-css-transition-group": "^0.14.8",
    "react-addons-linked-state-mixin": "^0.14.8",
    "react-addons-perf": "^0.14.8",
    "react-addons-pure-render-mixin": "^0.14.8",
    "react-addons-test-utils": "^0.14.8",
    "react-addons-transition-group": "^0.14.8",
    "react-addons-update": "^0.14.8",
    "react-autosuggest": "^8.0.0",
    "react-avatar-editor": "^9.1.0",
    "react-bootstrap-table": "^3.4.6",
    "react-categorized-tag-input": "^2.1.2",
    "react-dom": "^0.14.8",
    "react-dropzone-component": "^1.4.1",
    "react-intl": "^2.2.3",
    "react-linkify": "^0.2.0",
    "react-paginate": "^4.4.3",
    "react-player": "^0.20.0",
    "react-radio-group": "^3.0.1",
    "react-rater": "^0.4.2",
    "react-redux": "^5.0.2",
    "react-router": "^3.0.0",
    "react-router-scroll": "^0.4.1",
    "react-select": "^1.0.0-rc.3",
    "react-slick": "^0.14.5",
    "react-tabs": "^0.8.2",
    "react-toastr": "^2.8.2",
    "react-truncate": "^2.1.4",
    "redux": "^3.6.0",
    "redux-devtools": "^3.3.2",
    "request": "^2.81.0",
    "simpl-schema": "^1.4.2",
    "slick-carousel": "^1.6.0",
    "underscore": "^1.8.3",
    "uuid": "^3.1.0",
    "zxcvbn": "^4.4.1"
  },
  "devDependencies": {
    "autoprefixer": "^7.1.1",
    "babel-jest": "^20.0.3",
    "babel-preset-react": "^6.24.1",
    "eslint": "^3.15.0",
    "eslint-config-airbnb": "^14.1.0",
    "eslint-config-google": "^0.7.1",
    "eslint-plugin-compat": "^1.0.3",
    "eslint-plugin-import": "^2.2.0",
    "eslint-plugin-jsx-a11y": "^4.0.0",
    "eslint-plugin-react": "^6.9.0",
    "jest": "^20.0.4",
    "navalia": "^1.2.0",
    "react-test-renderer": "^15.6.1",
    "stylelint": "^7.10.1",
    "stylelint-no-unsupported-browser-features": "^1.0.0"
  },
  "postcss": {
    "plugins": {
      "autoprefixer": {}
    }
  },
  "stylelint": {
    "plugins": [
      "stylelint-no-unsupported-browser-features"
    ],
    "rules": {
      "plugin/no-unsupported-browser-features": true
    }
  },
  "scripts": {
    "test": "jest"
  },
  "jest": {
    "scriptPreprocessor": "<rootDir>/node_modules/babel-jest",
    "testFileExtensions": [
      "js",
      "jsx"
    ],
    "transformIgnorePatterns": [
      "<rootDir>/node_modules"
    ],
    "unmockedModulePathPatterns": [
      "<rootDir>/node_modules/react",
      "<rootDir>/node_modules/navalia"
    ],
    "moduleFileExtensions": [
      "js",
      "json",
      "jsx"
    ]
  }
}

这是我的./meteor/version

accounts-base@1.4.2
accounts-password@1.5.1
alanning:roles@1.2.16
aldeed:collection2-core@2.1.2
aldeed:tabular@2.1.1
allow-deny@1.1.0
autoupdate@1.4.1
babel-compiler@7.1.1
babel-runtime@1.2.2
base64@1.0.11
binary-heap@1.0.10
blaze@2.3.2
blaze-html-templates@1.1.2
blaze-tools@1.0.10
boilerplate-generator@1.5.0
browser-policy-common@1.0.11
browser-policy-framing@1.1.0
caching-compiler@1.1.12
caching-html-compiler@1.1.3
callback-hook@1.1.0
cfs:access-point@0.1.49
cfs:base-package@0.0.30
cfs:collection@0.5.5
cfs:collection-filters@0.2.4
cfs:data-man@0.0.6
cfs:file@0.1.17
cfs:filesystem@0.1.2
cfs:http-methods@0.0.32
cfs:http-publish@0.0.13
cfs:power-queue@0.9.11
cfs:reactive-list@0.0.9
cfs:reactive-property@0.0.4
cfs:standard-packages@0.5.10
cfs:storage-adapter@0.2.4
cfs:tempstore@0.1.6
cfs:upload-http@0.0.20
cfs:worker@0.1.5
check@1.3.1
coffeescript@1.0.17
cosmos:browserify@0.10.0
dburles:collection-helpers@1.1.0
ddp@1.4.0
ddp-client@2.3.3
ddp-common@1.4.0
ddp-rate-limiter@1.0.7
ddp-server@2.2.0
deps@1.0.12
diff-sequence@1.1.0
dynamic-import@0.4.1
ecmascript@0.11.1
ecmascript-runtime@0.7.0
ecmascript-runtime-client@0.7.1
ecmascript-runtime-server@0.7.0
ejson@1.1.0
email@1.2.3
es5-shim@4.8.0
fortawesome:fontawesome@4.7.0
fourseven:scss@3.13.0
gadicc:blaze-react-component@1.4.1
geojson-utils@1.0.10
hot-code-push@1.0.4
html-tools@1.0.11
htmljs@1.0.11
http@1.4.1
id-map@1.1.0
jcbernack:reactive-aggregate@0.7.0
jquery@1.11.11
juliancwirko:postcss@1.3.0
launch-screen@1.1.1
less@2.7.12
livedata@1.0.18
localstorage@1.2.0
logging@1.1.20
matb33:collection-hooks@0.8.4
mdg:validated-method@1.1.0
mdg:validation-error@0.5.1
meteor@1.9.2
meteor-base@1.4.0
meteorhacks:aggregate@1.3.0
meteorhacks:async@1.0.0
meteorhacks:collection-utils@1.2.0
meteorhacks:npm@1.5.0
minifier-css@1.3.1
minifiers-js@1.1.8-modules.8
minimongo@1.4.4
mobile-experience@1.0.5
mobile-status-bar@1.0.14
modern-browsers@0.1.2
modules@0.12.2
modules-runtime@0.10.2
momentjs:moment@2.8.4
mongo@1.5.1
mongo-dev-server@1.1.0
mongo-id@1.0.7
mongo-livedata@1.0.12
mrt:smart-publish@0.2.1
nilsdannemann:pdfmake@1.0.38
npm-bcrypt@0.9.3
npm-container@1.2.0
npm-mongo@3.0.7
observe-sequence@1.0.16
okgrow:analytics@2.1.3
ordered-dict@1.1.0
percolate:migrations@0.9.8
percolate:synced-cron@1.3.2
promise@0.11.1
raix:eventemitter@0.1.3
random@1.1.0
rate-limit@1.0.9
react@0.14.6
react-meteor-data@0.2.16
react-runtime@0.14.5
reactive-dict@1.2.0
reactive-var@1.0.11
reload@1.2.0
retry@1.1.0
routepolicy@1.0.13
schat:client-blaze@1.2.0
schat:client-core@1.2.1
service-configuration@1.0.11
session@1.1.7
sha@1.0.9
shell-server@0.3.1
socket-stream-client@0.2.2
spacebars@1.0.15
spacebars-compiler@1.1.3
srp@1.0.10
standard-minifiers-js@1.0.3-modules.8
templating@1.3.2
templating-compiler@1.3.3
templating-runtime@1.3.2
templating-tools@1.1.2
tmeasday:check-npm-versions@0.3.2
tracker@1.2.0
tsega:bootstrap3-datetimepicker@4.17.37_1
twbs:bootstrap@3.3.6
ui@1.0.13
underscore@1.0.10
url@1.2.0
webapp@1.6.2
webapp-hashing@1.0.9

1 个答案:

答案 0 :(得分:0)

使用yarn install代替npm install解决了问题。