YSF
03/09/2023, 7:46 PMfrom prefect import flow
@flow
def my_favorite_function():
print("What is your favorite number?")
return 42
print(my_favorite_function())
And when I run python dev.py
it gives me an error RuntimeError: Cannot create flow run. Failed to reach API at <http://127.0.0.1:4200/api/>
I tried changing the code to:
from prefect import flow
@flow
def my_favorite_function():
print("What is your favorite number?")
return 42
if __name__ == "__main__":
print(my_favorite_function())
And it still gives me the same error.
Am I missing something? I'm sure I've run this code before when trying to learn (edited)