Izz09/14/2023, 12:26 PM
and I’m doing running this
@flow(name="LO", flow_run_name="test-LO") def live_odds_poc(): logger = get_run_logger() <http://logger.info|logger.info>("Starting LO poc flow") flow = LiveOdds() lo_result = flow.run_flow()
but when I run it I get this Attribute Error ->
if __name__ == "__main__": live_odds_poc.serve( name="LO-test", tags=["LO"], interval=15 )
I have followed the tutorial in Prefect Cloud and I don’t see anything wrong (I also copied the code from the tutorial and got the same error). Can you help me? 🙏
AttributeError: 'Flow' object has no attribute 'serve'
Jeff Hale09/14/2023, 12:41 PM
in the terminal output?
Izz09/14/2023, 12:49 PM
Version: 2.11.5 API version: 0.8.4 Python version: 3.9.13 Git commit: a597971f Built: Thu, Aug 24, 2023 2:14 PM OS/Arch: darwin/x86_64 Profile: default Server type: cloud
Jeff Hale09/14/2023, 12:54 PM
and you’ll get version 2.13.0, which has that method in it. 🙂
pip install -U prefect
Izz09/14/2023, 1:00 PM
Jeff Hale09/14/2023, 1:00 PM