I would like to suppress the output when using python-fire, for a given command line option.
The fire trace and everything apart from the docstring and usage is essentially useless to me and clutters up the terminal. Any way I can get rid of it ?
I'm creating the cli using python-fire like this, where "command" is a function defined earlier :
if __name__ == "__main__":
fire.Fire(
{
"command": command
}
)
$ python cli.py command
Fire trace:
1. Initial component
2. Accessed property "command"
3. ('The function received no value for the required argument:)
Type: function
String form: <function list_property_versions at 0x10de5d840>
File: ./cli.py
Line: 171
Docstring: Does something
Usage: cli.py command arg1
cli.py command --first-arg arg1
Expected Output:
$ python cli.py command1
Docstring: Does something
Usage: cli.py command1 arg1
cli.py command1 --first-arg arg1