debug-wise args are not honored
See original GitHub issuenodemon -v: 1.14.12node -v: 8.9.4ts-node -v: 4.1.0- Operating system/terminal environment: Windows 10 x64
- Command you ran:
nodemon with the following nodemon.json:
{
"verbose": true,
"watch": [
"src"
],
"ext": "ts",
"exec": "{{pwd}}/node_modules/.bin/ts-node ./src/index.ts --project ./tsconfig.development.json --inspect=5858 --inspect-brk"
}
Expected behaviour
--inspect=5858 --inspect-brk are passed to node and one can connect with debugger
Actual behaviour
--inspect=5858 --inspect-brk are not passed to node and one can’t connect with debugger
terminal output:
[nodemon] 1.14.12
[nodemon] reading config .\nodemon.json
[nodemon] to restart at any time, enter `rs`
[nodemon] or send SIGHUP to 22156 to restart
[nodemon] watching: C:\Dev\node-typescript-vscode\src/**/*
[nodemon] watching extensions: ts
[nodemon] starting `C:\Dev\node-typescript-vscode/node_modules/.bin/ts-node ./src/index.ts --project ./tsconfig.development.json --inspect=5858 --inspect-brk`
[nodemon] spawning
[nodemon] child pid: 11272
[nodemon] watching 2 files
Steps to reproduce
- clone https://github.com/deilan-issues-samples/ts-node-issue-531
yarn installornpm installyarn run serve:debugornpm run serve:debug- launch
Attach to nodemonVS Code debug configuration
Issue Analytics
- State:
- Created 6 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
Devise ignoring custom strategy - ruby on rails - Stack Overflow
I get no errors in my log. Everything seems to work ok. If I add "cheap debugging" aka a bunch of puts statements,...
Read more >2019 R1 (SPx) issues - PC-DMIS User Forum
Starting a new thread listing issues found in PC-DMIS 2019 R1 (SPx). Each issue will be listed per post, not several in one...
Read more >Macos Podman Minikube setup, Ended with errors connecting ...
I'm hoping someone can point me in the right direction debug wise? podman machine init (vars are derived from the system info calculated...
Read more >How to use CD4052B analog mux to read from UART ports?
I'm using ESP32 with the ESP-IDF framework. I want to read power data from 3 HLW8032 IC. Modbus and GPS already use my...
Read more >the end of LCD-hacks? | Details | Hackaday.io
Debug-wise, whenever new EPG info is downloaded, it shows an update, but does *not* show the info. It's taken a bit of experimenting...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Closing with https://github.com/TypeStrong/ts-node/pull/536. I recommend
node -r ts-node/registerfor all advanced node.js use-cases and flags.Ok, I think i have a workaround
You can execute it like this
node --inspect-brk=5858 --require ts-node/register ./src/index.tsso you can create your nodemon.json file and do this, (create multiple nodemon.json files if you like - I have 1 for inspect and 1 for inspect-brk)
Hope that helps.
So this trick here is not to run ts-node direct but to load via node.