rokucommunity / roku-debug

A compatibility wrapper around the BrightScript debug protocol https://developer.roku.com/en-ca/docs/developer-program/debugging/socket-based-debugger.md
MIT License
13 stars 8 forks source link

Type error when running npx roku-debug --dap #195

Open ajdelcimmuto opened 2 months ago

ajdelcimmuto commented 2 months ago

I noticed after installing roku-debug, I was getting a TypeError when attempting to run npx roku-debug --dap.

    .parseSync();
     ^

TypeError: yargs.usage(...).help(...).option(...).parseSync is not a function
    at Object.<anonymous> (/home/ajdel/.npm-global/lib/node_modules/roku-debug/dist/cli.js:10:6)
    at Module._compile (node:internal/modules/cjs/loader:1546:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1691:10)
    at Module.load (node:internal/modules/cjs/loader:1317:32)
    at Module._load (node:internal/modules/cjs/loader:1127:12)
    at TracingChannel.traceSync (node:diagnostics_channel:315:14)
    at wrapModuleLoad (node:internal/modules/cjs/loader:217:24)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:166:5)
    at node:internal/main/run_main_module:30:49

Node.js v22.6.0

Versions:

├─┬ roku-debug@0.21.10
│ ├─┬ brighterscript@0.67.5
│ │ └── yargs@16.2.0
│ └─┬ replace-in-file@6.3.5
│   └── yargs@17.7.2
└── yargs@17.7.2

What I am doing to get it to work is manually changing cli.js ParseSync -> Parse. This seems to work for me, but was wondering if something should be changed here?