Uncaught Error: Cannot add node "1" because a node with that id is already in the Store
Asked Answered
N

1

7
I can't debug in react-native using the react-native debugger 

   Uncaught Error: Cannot add node "1" because a node with that id is already in the Store.
    C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:48 Uncaught Error: Cannot add node "1" because a node with that id is already in the Store.
        at C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:48
        at c.emit (C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:48)
        at C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:48
        at C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:48
        at Array.forEach (<anonymous>)
        at S.Gc.e.onmessage (C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:48)
        at S.n (C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:40)
        at S.emit (events.js:315)
        at e.exports.P (C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:8)
        at e.exports.emit (events.js:315)
        at e.exports.dataMessage (C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:8)
        at e.exports.getData (C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:8)
        at e.exports.startLoop (C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:8)
        at e.exports._write (C:\Users\kbelhadjali\AppData\Local\react_native_debugger\app-0.12.1\resources\app.asar\node_modules\react-devtools-core\dist\standalone.js:8)
        at doWrite (_stream_writable.js:403)
        at writeOrBuffer (_stream_writable.js:387)

and when i tried to use the debugger-ui only it doesn't work aswell and showing me this error:

Development Tools failed to load source map: Unable to load content from http: // localhost: 19000 / debugger-ui / debuggerWorker.aca173c4.js.map: Failed to retrieve via target: Target not taken in charge ; Fallback: HTTP error: status code 404, net :: ERR_HTTP_RESPONSE_CODE_FAILURE

i even created a blank project to test if the problem is caused by my project but it didn't work aswell showing me the same errors.

Any help would me much appreciated.

Nessim answered 13/1, 2022 at 15:34 Comment(1)
I ran into a similar problem. I discovered the react-native-debugger was opening an instance in my web-browser and a separate stand alone instance. When I closed the instance in my web browser, the error stopped occurring and I could debug normally.Ozonize
R
4

I also had this problem, my dependencies:

...
"expo": "~43.0.0",
"react": "17.0.2",
"react-native": "0.66.3"

Seems like "react-devtools-core" in react-native dependencies install old package version.

I added

  "resolutions": {
    "react-devtools-core": "4.14.0"
  }

To package.json for solving this problem. I also reinstall last react-native-debugger ( brew reinstall react-native-debugger) Maybe it will help you.

Reenareenforce answered 21/1, 2022 at 19:1 Comment(2)
Thank you for you response, but sadly it didn't work for me and the react-native-debugger still showing the same error.Nessim
you need to add the dependency and install the package again with npm or yarn. Worked for me well!Intangible

© 2022 - 2024 — McMap. All rights reserved.