You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 8, 2024. It is now read-only.
When I pass --server without further arguments to Dredd while having dredd.yml, Dredd throws a JavaScript error instead of user friendly message.
To Reproduce
Copy dredd.yml from below, install Dredd and then run dredd --server.
$ npx dredd --server
error: args.replace is not a function TypeError: args.replace is not a function
at module.exports (/Users/kyle/Projects/apiaryio/helium/functions/transform/node_modules/spawn-args/index.js:19:14)
at CLI.runServerAndThenDredd (/Users/kyle/Projects/apiaryio/helium/functions/transform/node_modules/dredd/lib/CLI.js:202:26)
at CLI.run (/Users/kyle/Projects/apiaryio/helium/functions/transform/node_modules/dredd/lib/CLI.js:299:12)
at Object.<anonymous> (/Users/kyle/Projects/apiaryio/helium/functions/transform/node_modules/dredd/bin/dredd:56:10)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
Expected behavior
Not entirely sure what the behaviour should be, perhaps an error that --server requires an argument?
I'd blame the optimist library in this case as well, perhaps including subsequent handling of the CLI args. Since the library is long overdue and outdated, the best fix would be IMHO to revamp the CLI & configuration altogether - #845
Describe the bug
When I pass
--server
without further arguments to Dredd while having dredd.yml, Dredd throws a JavaScript error instead of user friendly message.To Reproduce
Copy dredd.yml from below, install Dredd and then run
dredd --server
.Expected behavior
Not entirely sure what the behaviour should be, perhaps an error that
--server
requires an argument?What is in your
dredd.yml
?What's your
dredd --version
output?$ npx dredd --version dredd v11.2.17 (Darwin 18.7.0; x64)
The text was updated successfully, but these errors were encountered: