Hey all! Does anyone know how you can pass kwargs to a task function?
Right now I have a task that does a very similar thing with some tweaks depending on keywords a few times.
@task(timeout=60, nout=2)
def get_date(
dt,
ensure_explicit=False,
max_late=timedelta(hours=12),
):
# some code
return None, None
However, when I try and add to my flow a
get_date(dt, max_late=timedelta(minutes=1))
I get
TypeError: got an unexpected keyword argument
. I assume the task decorator is wrapping the original function and doesnt pass through any kwargs it doesnt recognise.
Is there a subtle keywork Im missing to pass kwargs through, or should I rewrite these functions of mine to utilise class based Tasks?