question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

node --inspect appears to be broken or unsupported

See original GitHub issue

See https://github.com/facebook/jest/issues/1652. As of this issue being fixed in Jest and Node 8.4, this should be fixed in create-react-app but I can’t get it to work.

Is this a bug report?

Yes

Can you also reproduce the problem with npm 4.x?

Yes

Which terms did you search for in User Guide?

inspect

Environment

  1. node -v: v8.4.0
  2. npm -v: 4.6.1 and 5.3.0 (confirmed on both versions)
  3. npm ls react-scripts: 1.0.11
  4. Operating system: macOS
  5. Browser and version: Google Chrome Version 60.0.3112.101 (Official Build) (64-bit)

Steps to Reproduce

  1. Open chrome://inspect/#devices in Chromium.
  2. Enable networking and forward localhost:9229.
  3. Set a debugger breakpoint in a test file.
  4. node --inspect-brk node_modules/.bin/react-scripts test
  5. Inspect the target in Chromium.
  6. Resume script execution.
  7. Wait for tests to complete/break.

Expected Behavior

Chromium debugger stops on debugger breakpoint.

Actual Behavior

Chromium debugger doesn’t stop on breakpoint and remains at the beginning of the script.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:12 (10 by maintainers)

github_iconTop GitHub Comments

5reactions
Timercommented, Aug 17, 2017

Sorry @nickmccurdy, this should do it:

./node_modules/.bin/react-scripts --inspect-brk test --env=jsdom --runInBand
2reactions
gaearoncommented, Aug 18, 2017

We need to add a more ergonomic way of running it that doesn’t require specifying --runInBand manually and then document it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

debug-brk` are invalid. Please use `node --inspect` or `node
seems the Node.js version babel-node is using doesn't accept `--debug-brk` option, and Webstorm can't detect what Node.js version is being ...
Read more >
The engine "node" is incompatible with this module
yes , you are getting this error because of incompatibility between the package version and node engine. – Shubham Sharma. Jun 16, 2019...
Read more >
Debug Node.js Apps using Visual Studio Code
The Visual Studio Code editor includes Node.js debugging support. Set breakpoints, step-in, inspect variables and more.
Read more >
How to perform an unsupported conversion from a RHEL ...
This document provides instructions on how to perform an unsupported conversion of your operating system from a different Linux distribution ...
Read more >
Node.js v19.3.0 Documentation
If the browser displays the string Hello, World! , that indicates the server is working. Assert#. Stability: 2 - Stable. Source Code: lib/assert.js....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found