After experiencing this brew issue with sqlite3, I did
brew rm sqlite python python3
then
brew install python python3
If you are working on a cluster and cannot (and should not) access the root directory: /usr/local/share/python/pip, you should look in your home directory instead: $HOME/.local/bin/pip. Check that the proper python location is referenced there.
/usr/local/share/python/pip
$HOME/.local/bin/pip