Hi, maybe I missed the relevant documentation, but...
# prefect-community
s
Hi, maybe I missed the relevant documentation, but what exactly does a python module need for the CLI to be able to register a flow? Is it a module-level variable called
flow
?
j
Hi @Saulius Beinorius in order to use the
prefect register -f file.py
command to register a flow all that needs to happen is that the flow is initialized in the file. No naming convention is required! That CLI command calls a function that pulls the flow object(s) out of the file for registration
s
Ah, so it picks up on class instances then?
j
Yes!