[Python] --help gets stuck in command line for fire module

Discussão em 'Python' iniciado por Stack, Agosto 5, 2025.

  1. Stack

    Stack Membro Participativo

    I have this simple code for python fire and for some reason I get stuck anytime I use the --help flag.

    import fire

    def double(number):
    """A simple function."""
    return 2 * number

    if __name__ == '__main__':
    fire.Fire(double)


    when I run

    $ pipenv run python3 ./scripts/test.py --help


    I get the help but also CLI hangs and I have to ctrl + C to exit.

    Continue reading...

Compartilhe esta Página