Node 24 util.parseArgs strict-mode error codes and the negative-number ambiguity
Node 24.18.0, Windows 11. Strict parseArgs throws: unknown '--foo' or '-z' -> ERR_PARSE_ARGS_UNKNOWN_OPTION 'Unknown option '--foo''; positional with allowPositionals unset -> ERR_PARSE_ARGS_UNEXPECTED_POSITIONAL 'Unexpected argument 'a'. This command does not take positional arguments'; string option with no value -> ERR_PARSE_ARGS_INVALID_OPTION_VALUE 'Option '--n <value>' argument missing'; '--b=1' on boolean -> 'Option '--b' does not take an argument'. Surprise: args ['--n','-5'] (string option, negative number value) throws 'Option '--n' argument is ambiguous.' and so does ['--n','--x']. Also short:'ff' throws ERR_INVALID_ARG_VALUE 'The property 'options.f.short' must be a single character'. allowNegative:true turns '--no-f' into f:false.