worried-lighter-79998
09/19/2022, 7:10 AMwf
and launch plan like
launch_plan.LaunchPlan.get_or_create(
workflow=wf,
name="my_lp",
schedule=CronSchedule("0 0 ? * * *"),
default_inputs={...},
fixed_inputs={...},
)
how do I schedule this after registering it alongside my workflows with pyflyte serialize
and flytectl register
? I think the relevant docs are supposed to be https://docs.flyte.org/projects/flytectl/en/latest/gen/flytectl_update_launchplan.html but running the specified commands fails with launch plan prod failed to update due to rpc error: code = NotFound desc
. This command requires a version which I have none so it might be because of this. How should I proceed?
Some side note feedback: It feels to me like activating launch plans is more naturally done in the web UI. However, trying to open my launch plan errors with
Error: Minified React error #31; visit <https://reactjs.org/docs/error-decoder.html?invariant=31&args[]=object%20with%20keys%20%7Brole_session_name%2C%20region_name%2C%20role_arn%7D&args[]=> for the full message or use the non-minified dev environment for full errors and additional helpful warnings.
Which probably comes from me using using struct arguments (role_session_name, region_name, role_arn are in a dataclass) but it nevertheless seems like there is a bug in the launch plan rendering.worried-lighter-79998
09/19/2022, 9:00 AMflytectl get launchplans
that the version is the git sha used to register it. Now sure how that's wired but that works.
However, trying to register errors since no cron format is valid. In https://docs.flyte.org/en/latest/concepts/schedules.html#short-hand-cron-formats-predefined-schedules @midnight
or "0 0 * * *"
are suggested. Both fail during serialize
.
As do ` "0 0 * * * *"
and ` "0 0 ? * * *"
. Is cron scheduling just broken or can it be achieved any other way?worried-lighter-79998
09/19/2022, 9:12 AMCronSchedule(schedule="@midnight")
works (this is in fact in the docs) but CronSchedule(expr)
fails for expr
like all the above listed examplesworried-lighter-79998
09/19/2022, 9:15 AMError: Expression has only 1 part. At least 5 parts are required.
Where the 'schedule' menu used to be. Another react rendering error by the looks of ittall-lock-23197
"0 0 * * *"
works for me. I ran the pyflyte run --remote <python-file> <wf-name>
command.tall-lock-23197
tall-lock-23197
worried-lighter-79998
09/19/2022, 11:54 AMpyflyte serialize
for CronSchedule("0 0 * * *")
for me.
Flyte console is
UI Version1.1.6
Admin Version0.4.7-223-g0266a06tall-lock-23197
pyflyte serialize
isn’t the right command anymore. Can you try running pyflyte --pkgs <parent-package>.<child-package-that-has-the-workflow> package --image <image>
? Where have you come across the pyflyte serialize
command?
You can also try the pyflyte run command I shared with you earlier. It’s far more easy than packaging and registering the workflow separately.worried-lighter-79998
09/19/2022, 12:55 PMtall-lock-23197
tall-lock-23197
freezing-airport-6809
freezing-airport-6809
helpful-crowd-74546
09/19/2022, 1:47 PMhelpful-crowd-74546
09/19/2022, 1:48 PMicy-agent-73298
09/19/2022, 1:51 PMhelpful-crowd-74546
09/19/2022, 1:51 PMfreezing-airport-6809
icy-agent-73298
09/19/2022, 1:55 PMfreezing-airport-6809
helpful-crowd-74546
09/19/2022, 1:57 PMhelpful-crowd-74546
09/19/2022, 1:59 PMUI Version
1.1.6
Admin Version
1.1.43
icy-agent-73298
09/19/2022, 3:42 PMtall-lock-23197
icy-agent-73298
09/20/2022, 5:22 AM