Running MacOS. I was running python 3.9, and upgraded to the latest Python distro (3.12.3).
When I went to install the spellchecker package, pip installed it in /Applications/anaconda3/lib/python3.9/site-packages
.
But when I try to import the package, I get ModuleNotFound
. When I check sys.path
, I get
[
'',
'/Library/Frameworks/Python.framework/Versions/3.12/lib/python312.zip', '/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12', '/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/lib-dynload', '/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages'
].
How can I get pip to install packages in the right directory?