David
03/05/2023, 4:44 PMregister_prefect_flow.py
script given by Kedro documentation. Unfortunately, I don't seem to succeed because Prefect 1.0 API is different from Prefect 2.0.
Thanks in advance !Deepyaman Datta
03/06/2023, 5:52 AMFlow
still exists in Prefect 2, but I don't think it's a context manager (at least, looking at https://github.com/PrefectHQ/prefect/blob/main/src/prefect/flows.py, I didn't see any __enter__
or __exit__
). So either you construct a Flow
object yourself or use the @flow
decorator programmatically.
• Task API is different. Also, maybe you can just use Prefect 2 native orchestration of Python functions?
Would recommend starting with a super simple pipeline (e.g. Iris and working out what needs to be changed). I'm also not 100% sure, but I think it may make sense to look at Prefect Blocks for storage.