Skip to content

Instantly share code, notes, and snippets.

@samz5320
Last active August 17, 2022 15:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save samz5320/5bf4a4d353af6b6e5d5e4eded975fba3 to your computer and use it in GitHub Desktop.
Save samz5320/5bf4a4d353af6b6e5d5e4eded975fba3 to your computer and use it in GitHub Desktop.
Simple_task_registration_prefect
#imports
import prefect
from prefect import task, Flow
#deinfe tasks
@task
def hello():
print("Hello World!")
#initialize tasks
with Flow("hello") as flow:
hello()
#register flow
flow.register(project_name="test")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment