1

I am trying to run pip3 from Terminal and the following error shows up:

xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun.

I have just upgraded my os to Catalina and have already tried:

xcode-select --install

which shows me:

Can't download the software because of a network problem

And:

sudo xcode-select --reset

which outputs nothing and when I run pip3 again, I get the same error. Is there anything else that could be done? Am I missing something here?

1

You are perfect in your thinking. The true error is your machine needs a valid, secured web connection back to Apple’s content delivery network and servers. See if you can download any app from the Mac App Store and then when that’s working, retry the install.

xcode-select --install

Apple generally requires you to allow outbound traffic to the 17.0.0.0 network range, so if you’re on a filtered network, consider using a VPN to get outside the restrictions or have networking open outbound ports for your device to rule that out as an error.

Once you’ve gotten a good install, the select command above will report that the developer tools are installed and to use Software Update to update them. Since you tagged your question Xcode you could install that as well and then run it - it will install the tools as well (including the xcrun tool which is the first item needed by pip3)

|improve this answer|||||
  • 10-4, had to ask our IT guy to make this work. Switched to a less restricted network and fixed the issue. Thanks – ahajib Feb 17 at 18:46
  • 1
    bmike, you made my day!!! helped me with getting git installed on my mac!! thank you. after running the command, xcode-select --install, and aftewr installation completed, I was able to see that git is installed!!! :) I was getting error: xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcru . whern was running git --version Now I see it!!! – Chandra Shekkharan Feb 27 at 4:08

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .