YSF
03/09/2023, 6:25 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 learnkasteph
03/09/2023, 10:14 PMJanet Carson
03/10/2023, 4:11 AMYSF
03/14/2023, 3:58 PM