Yomguithereal / react-blessed

A react renderer for blessed.
MIT License
4.45k stars 177 forks source link

TypeError: Invalid Version: undefined when trying to use react-devtools #97

Open dpacmittal opened 5 years ago

dpacmittal commented 5 years ago

I'm trying to use react-devtools and I'm getting this error:

TypeError: Invalid Version: undefined
    at new K (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:63911)
    at Z (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:67537)
    at Function.re [as gte] (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:67745)
    at e.exports (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:52797)
    at e.exports (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:43706)
    at e.exports (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:42718)
    at e.exports (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:42368)
    at t.<anonymous> (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:9822)
    at t.r (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:21852)
    at t.r.emit (/home/dpac/projects/blessed-binance/node_modules/react-devtools-core/build/backend.js:1:20642)

I'm not sure what's wrong. Here's my package.json:

{
  "name": "binance-cli",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1",
    "build": "tsc -p ./",
    "watch": "tsc -w -p ./"
  },
  "author": "",
  "license": "ISC",
  "dependencies": {
    "@types/blessed": "^0.1.11",
    "@types/react": "^16.8.19",
    "@types/react-blessed": "^0.3.1",
    "@types/ws": "^6.0.1",
    "binance-api-node": "^0.9.2",
    "blessed": "^0.1.81",
    "blessed-contrib": "^4.8.16",
    "mobx-react-lite": "^1.4.0",
    "neo-blessed": "^0.2.0",
    "react": "^16.8.0",
    "react-blessed": "0.6.0",
    "react-blessed-contrib": "^0.2.1",
    "react-devtools-core": "^3.0.0",
    "ts.data.json": "^0.2.0",
    "winston": "^3.2.1"
  },
  "devDependencies": {
    "typescript": "^3.4.4"
  }
}

This only happens when react-devtools is open.

dpacmittal commented 5 years ago

I removed node_modules folder and updated my package.json (removed react-devtools-core and blessed) to:

{
  "name": "binance-cli",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1",
    "build": "tsc -p ./",
    "watch": "tsc -w -p ./"
  },
  "author": "",
  "license": "ISC",
  "dependencies": {
    "@types/blessed": "^0.1.11",
    "@types/react": "^16.8.19",
    "@types/react-blessed": "^0.3.1",
    "@types/ws": "^6.0.1",
    "binance-api-node": "^0.9.2",
    "blessed-contrib": "^4.8.16",
    "neo-blessed": "^0.2.0",
    "react": "^16.8.0",
    "react-blessed": "0.6.0",
    "react-blessed-contrib": "^0.2.1",
    "ts.data.json": "^0.2.0",
    "winston": "^3.2.1"
  },
  "devDependencies": {
    "typescript": "^3.4.4"
  }
}

Now I have started getting: WARNING: the `ws` package must be installed to use `react-devtools`.

Which is why I had installed react-devtools-core and ws in the first place using install-peerdeps.