×ばつ This environment is externally ..." /> ×ばつ This environment is externally ..." />×ばつ This environment is externally ..." />
Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

externally-managed-environment #789

Answered by rasbt
brucetrask2 asked this question in Q&A
Discussion options

Hello,

I am following along with the YouTube video on setting up the python environment.
When I run pip3.13 install uv I get:
error: externally-managed-environment

×ばつ This environment is externally managed
╰─> To install Python packages system-wide, try brew install
xyz, where xyz is the package you are trying to
install.
...

I am running on MacOS Sequoia 15.3.2

Do I need to run in a venv? I see I do once I get uv installed but how to get it installed so that I can then setup the venv if I don't already have the venv? Has something changed on MacOS since the video was made?

You must be logged in to vote

Hm, I haven't seen this before. But it sounds like you can install uv by doing the following instead:

brew install uv

Edit: I should note that uv is not required to install the packages in the book, and pip installing is equally fine (although slower). But if pip install uv causes problems, you'll have the same issue with pip install torch etc. So, I would suggest using uv.

Replies: 1 comment 5 replies

Comment options

Hm, I haven't seen this before. But it sounds like you can install uv by doing the following instead:

brew install uv

Edit: I should note that uv is not required to install the packages in the book, and pip installing is equally fine (although slower). But if pip install uv causes problems, you'll have the same issue with pip install torch etc. So, I would suggest using uv.

You must be logged in to vote
5 replies
Comment options

@brucetrask2 I believe the error comes from the pip3.13 - might it be that you confused pip with Python 3.13?

For installing uv, you can install uv in your (virtual) env with pip install uv. For reference, this part in covered in the video starting at 10:12min.

Does this work for you?

Comment options

@d-kleine, I figured I could do the same that Sebastian did at 9:57 in the video. That is, pipX.XX install uv in a non virtual env. He used pip3.11 and I used pip3.13. Sebastian's line seem to work (pip3.11 install uv) but mine (pip3.13 install uv) gives the error I mentioned. Using the virtual environment worked fine of course but I was just wondering since the video did the install of uv before the venv step. In any case, the brew install uv also worked as @rasbt mentioned. Thanks for your reply.

Comment options

Hm, I haven't seen this before. But it sounds like you can install uv by doing the following instead:

brew install uv

Edit: I should note that uv is not required to install the packages in the book, and pip installing is equally fine (although slower). But if pip install uv causes problems, you'll have the same issue with pip install torch etc. So, I would suggest using uv.

@rasbt Thanks. brew install uv worked.

Comment options

@d-kleine, I figured I could do the same that Sebastian did at 9:57 in the video. That is, pipX.XX install uv in a non virtual env. He used pip3.11 and I used pip3.13. Sebastian's line seem to work (pip3.11 install uv) but mine (pip3.13 install uv) gives the error I mentioned. Using the virtual environment worked fine of course but I was just wondering since the video did the install of uv before the venv step. In any case, the brew install uv also worked as @rasbt mentioned. Thanks for your reply.

Ok, great! 🙂

Comment options

Glad that this way worked at least :)!

Answer selected by rasbt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet

AltStyle によって変換されたページ (->オリジナル) /