pip3 crashes on macOS Catalina

In cases where pip3 has a bad environment on macOS Catalina, it may crash with this message:

% pip3 
Traceback (most recent call last):
  File "/Library/Developer/CommandLineTools/usr/bin/pip3", line 10, in <module>
TypeError: 'module' object is not callable

To fix this, clear the user pip library by running:

rm -rf ~/Library/Python

You can also reinstall Xcode tools with:

sudo rm -rf /Library/Developer/CommandLineTools
xcode-select --install