Closed DetachHead closed 2 months ago
this example from the docs doesn't seem to work
import mainpy import click @mainpy.main @click.command() def click_command(): click.echo('Hello from click_command') # never runs
python foo.py
mainpy v1.3.2 click v8.1.7 python v3.12
This was caused by a bug in click.core.Command that doesn't call functools.update_wrapper (unlike click.core.Group), so that the wrapped function's __module__ is "overwritten" with "click.core".
click.core.Command
functools.update_wrapper
click.core.Group
__module__
"click.core"
this example from the docs doesn't seem to work
mainpy v1.3.2 click v8.1.7 python v3.12