1 2 3 4 5 6 7 8 9 10
from functools import partial tasks = {} def task(name: str): return partial(tasks.__setitem__, name) __all__ = ['task']