https://prefect.io logo
o

Oscar Montanes

08/30/2023, 10:51 PM
Hi i am receiving this error when i am running prefect on my mac, any ideas?
Copy code
Traceback (most recent call last):
 File "/Library/Frameworks/Python.framework/Versions/3.10/bin/prefect", line 5, in <module>
  from prefect.cli import app
 File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/prefect/_init_.py", line 45, in <module>
  from prefect.engine import pause_flow_run, resume_flow_run
 File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/prefect/engine.py", line 98, in <module>
  from anyio import start_blocking_portal
ImportError: cannot import name 'start_blocking_portal' from 'anyio' (/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/anyio/_init_.py)
n

Nate

08/30/2023, 11:12 PM
hi @Oscar Montanes - what are you running when you get this? i am also on a mac 🙂
o

Oscar Montanes

08/30/2023, 11:13 PM
Hi just trying to login
prefect cloud login
I tried
pip install --upgrade --force-reinstall prefect
n

Nate

08/30/2023, 11:16 PM
would you be able to do this and share the output
Copy code
pip list | grep 'prefect\|anyio'
n

Nico Neumann

08/30/2023, 11:19 PM
I also get the same error. I think because of the new anyio update which was released an hour ago: https://pypi.org/project/anyio/#history
thank you 1
n

Nate

08/30/2023, 11:20 PM
hmm lemme try and reproduce
🙏 1
sheesh - yep
pip install 'anyio<4'
and things work fine
n

Nico Neumann

08/30/2023, 11:22 PM
It might make sense to define an upper limit in the requirements.txt?
anyio >= 3.4.0, < 4.0.0
n

Nate

08/30/2023, 11:22 PM
will raise this - thank you both!
🙌 2
n

Nico Neumann

08/30/2023, 11:22 PM
Thanks 🚀
n

Nate

08/30/2023, 11:26 PM
issue for tracking
🙏 1