ipfs-cluster-ctl
should not return error code 0 in case of incorrect usage
#1633
Labels
kind/bug
A bug in existing code (including security flaws)
need/triage
Needs initial labeling and prioritization
Additional information:
Describe the bug:
When calling
ipfs-cluster-ctl
with invalid arguments (e.g. ipfs-cluster-ctl add some-file.txt -rmin NaN), an error message is shown (e.g.Incorrect Usage: invalid value "NaN" for flag -rmin: parse error
) followed by the program's usage string. In that case, the error code is0
and everything is output to stdout.I would expect a return code different from
0
, which is particularly important if you use that command in a script.I see that error codes
1
and2
are already in use but for another purpose (#178), maybe add an error code3
for input related issues?The text was updated successfully, but these errors were encountered: