Correct me if I'm wrong, but it seem that click decorators obscure the function default and construction. Call the wrapped from from the REPL does not immediately work in the same way as the REPL. For example see this from dask distributed:
@click.option('--bokeh-prefix', type=str, default=None,
help="Prefix for the bokeh app")
@click.option('--preload', type=str, multiple=True, is_eager=True,
help='Module that should be loaded by each worker process '
'like "foo.bar" or "/path/to/foo.py"')
@click.argument('preload_argv', nargs=-1,
type=click.UNPROCESSED, callback=validate_preload_argv)
def main(scheduler, host, worker_port, listen_address, contact_address,
nanny_port, nthreads, nprocs, nanny, name,
memory_limit, pid_file, reconnect, resources, bokeh,
bokeh_port, local_directory, scheduler_file, interface,
death_timeout, preload, preload_argv, bokeh_prefix, tls_ca_file,
tls_cert, tls_key):
Is there some simple pattern to get at the function and all its defaults?