未捕获错误:中继转换错误

时间:2016-07-07 20:45:00

标签: reactjs ecmascript-6 graphql relay

我们在生产中面临Relay / GraphQL / React的问题。在master中测试时一切正常,但是在生产中我们在控制台中出现以下错误,导致与Relay / GraphQL / React相关的所有内容都无法正常工作:

Uncaught Error: Relay transform error ``Map is not defined`` in file '/var/app/ondeck/app/react/relay/routes/xxx-route.jsx'. Try updating your GraphQL schema if an argument/field/type was recently added.

我们认为应用程序在部署时会与构建相关,但我们不知道从哪里开始查看。

如果有帮助,这是我的package.json

{
  "private": true,
  "devDependencies": {
    "babel-eslint": "^6.0.4",
    "eslint": "^2.11.1",
    "eslint-plugin-react": "^5.1.1",
    "webpack-notifier": "^1.3.1"
  },
  "dependencies": {
    "autobind-decorator": "^1.3.3",
    "babel-core": "^6.4.0",
    "babel-loader": "^6.2.1",
    "babel-plugin-transform-decorators-legacy": "^1.3.4",
    "babel-polyfill": "^6.7.4",
    "babel-preset-es2015": "^6.3.13",
    "babel-preset-react": "^6.3.13",
    "babel-preset-stage-0": "^6.3.13",
    "babel-relay-plugin": "^0.9.0",
    "extract-text-webpack-plugin": "^1.0.1",
    "graphiql": "^0.7.2",
    "graphql": "^0.6.0",
    "isomorphic-fetch": "^2.2.1",
    "node-sass": "^3.3.3",
    "postal": "^2.0.4",
    "react": "^15.1.0",
    "react-dom": "^15.1.0",
    "react-linkify": "^0.1.1",
    "react-notification-system": "^0.2.6",
    "react-relay": "^0.9.0",
    "react-star-rating-component": "^1.0.0",
    "react-stars": "^2.1.0",
    "react-webpack-rails": "^0.4.1",
    "sass-loader": "^4.0.0",
    "webpack": "^1.12.1"
  },
  "scripts": {
    "build": "webpack -p --config webpack/production.config.js",
    "start": "webpack -w --config webpack/dev.config.js",
    "lint": "eslint --ext .js,.jsx app/react/**"
  },
  "license": "",
  "engines": {
    "node": ">= 0.10"
  }
}

1 个答案:

答案 0 :(得分:0)

为了记录,我需要将Node.js更新到最新版本,以便一切都能再次运行。感谢。