Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
@click.command() @click.option('--shout/--no-shout', default=False) def info(shout): pass info()
is ok, but
@click.command() @click.option('--shout/--no-shout', default=False, type=bool) def info(shout): pass info()
will raise a TypeError: Got secondary option for non boolean flag.
I've tracked this down to
in this case
I can't immediately see why this is there (it just looks wrong at first glance). But blame says that line of code is 5 years old, which suggests there's more to it...