No se pueden cargar los módulos Python instalados a través de pip desde el directorio de paquetes del sitio
Estoy tratando de instalar y usar el módulo Evernote (https://github.com/evernote/evernote-sdk-python) corrípip install evernote
y dice que la instalación funcionó.
Puedo confirmar que el módulo evernote existe en/usr/local/lib/python2.7/site-packages
. Sin embargo, cuando trato de correrpython -c "import evernote"
Obtuve el siguiente error:
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: No module named evernote
Este es el contenido de mi.bash-profile
:
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
# Setting PATH for Python 3.3
# The orginal version is saved in .bash_profile.pysave
PATH="/Library/Frameworks/Python.framework/Versions/3.3/bin:${PATH}"
export PATH
export PATH=$PATH:/usr/local/bin/
Tengo el mismo problema con otros módulos instalados conpip
. ¿Ayuda?
EDITAR: Soy un super novato y no he editado eso.bash-profile
archivo.
EDITAR:python -c 'import sys; print "\n".join(sys.path)'
Produce lo siguiente:
/Library/Python/2.7/site-packages/setuptools-1.3.2-py2.7.egg
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python27.zip
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plat-darwin
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plat-mac
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plat-mac/lib-scriptpackages
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-tk
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-old
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/PyObjC
/Library/Python/2.7/site-packages
EDITAR: Parecía haber progresado hacia una solución agregandoexport PYTHONPATH=“/usr/local/lib/python2.7/site-packages”
para mi.bash_profile
archivo. Sin embargo, ahora cuando corropython -c 'from evernote.api.client import EvernoteClient'
intenta importar oauth2, que falla con el mismo error. El módulo ouath2 está presente en el directorio del módulo.