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 }}
Repository navigation
Review Exit codes before v5 release (if possible) #1661
Some questions about exit codes were raised while I was reviewing our document.
The current description of NotAllowed is
`--incremental` cannot be combined with a rev_range
But now we use NotAllowed for other scenarios as well. It's a bit outdated.
What is the difference among InvalidCommandArgumentError, InvalidConfigurationError, NotAllowed? I guess we need to clarify the usages.
One of possible solutions may like giving them better, for example UnknownCommandArgument, UnknownConfigurationFileFormat. The word "invalid" has a lot of possible interpretations and it is very likely to be misused.
InvalidManualVersion sounds like a kind of InvalidCommandArgumentError
We have to add docstrings to those exceptions to reduce the possibility of misuse or abuse of exceptions. It would be even better if there is a tool to update the content of docs/exit_code.md whenever there is an update in exceptions.py
What is the difference among InvalidCommandArgumentError, InvalidConfigurationError, NotAllowed? I guess we need to clarify the usages.
I think NotAllowed is a bit too broad...
InvalidManualVersion sounds like a kind of InvalidCommandArgumentError
kinda. Not a bad idea to derive from it. Explicitly is better. If InvalidManualVersion is a frequently encountered situation
We have to add docstrings to those exceptions to reduce the possibility of misuse or abuse of exceptions. It would be even better if there is a tool to update the content of docs/exit_code.md whenever there is an update in exceptions.py
Activity
Lee-W commentedon Nov 21, 2025
I think
NotAllowedis a bit too broad...kinda. Not a bad idea to derive from it. Explicitly is better. If
InvalidManualVersionis a frequently encountered situationyep, indeed a good idea