Closed
Description
Description
A clear description of the bug
I would like to create a flow on a schedule, passing in default parameters. Currently this fails unless all parameters have default values.
Expected Behavior
What did you expect to happen instead?
Passing parameters should be allowed even if they do not have defaults - we should be able to resolve the following example
Reproduction
A minimal example that exhibits the behavior.
from prefect.schedules import Schedule
from prefect.schedules.clocks import CronClock
@task
def add(a, b):
return a + b
schedule = Schedule(clocks=[
CronClock(
cron=f"* * * * *",
parameter_defaults={
'a': 1,
}
)
])
with Flow('flow', schedule=schedule) as flow:
a = Parameter('a')
b = Parameter('b', default=1)
result = add(a, b)
flow.register()
Environment
Any additional information about your environment
Optionally run prefect diagnostics
from the command line and paste the information here
Activity