meljunky
unread,Jul 1, 2011, 7:33:24 PM7/1/11Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to python_inside_maya
I am looking to install pyMel 1.03 in a different directory than:
C:\Program Files (x86)\Autodesk\Maya2009\Python\lib\site-packages
However, I want to use the functionality on using .egg and .pth files
for easy installation of modules so I used (Not just for pyMel) the
following code for the pth files to be read (runs before maya opens I
believe):
python ("import site;site.addsitedir( 'S:\\G..s\\Maya\\Python25\\Lib\
\site-packages' )");
I left the maya folder in: C:\Program Files (x86)\Autodesk
\Maya2009\Python\lib\site-packages. The one that was installed along
with Maya
I drop the pymel, etc: .egg files in S:\\G..s\\Maya\\Python25\\Lib\
\site-packages. (It was installed locally at first)
If I print the sys.path I get the following results:
S:\G...Maya\Python25\Lib\site-packages\setuptools-0.6c9-py2.5.egg
S:\G...Maya\Python25\Lib\site-packages\pymel-1.0.0-py2.5.egg
S:\G...Maya\Python25\Lib\site-packages\ipython-0.10.2-py2.5.egg
S:\G...Maya\Python25\Lib\site-packages\ply-3.3-py2.5.egg
C:\Program Files (x86)\Autodesk\Maya2009\bin
C:\Program Files (x86)\Autodesk\Maya2009\bin
C:\Program Files (x86)\Autodesk\Maya2009\bin\python25.zip
C:\Program Files (x86)\Autodesk\Maya2009\Python\DLLs
C:\Program Files (x86)\Autodesk\Maya2009\Python\lib
C:\Program Files (x86)\Autodesk\Maya2009\Python\lib\plat-win
C:\Program Files (x86)\Autodesk\Maya2009\Python\lib\lib-tk
C:\Program Files (x86)\Autodesk\Maya2009\Python
C:\Program Files (x86)\Autodesk\Maya2009\Python\lib\site-packages
C:/Users/be/Documents/maya/2009/prefs/scripts
C:/Users/be/Documents/maya/2009/scripts
C:/Users/be/Documents/maya/scripts
S:\G...Maya\Python25\Lib\site-packages
S:\G...Maya\Python25
S:\G...Maya\Python25\Lib
S:\G...Maya\Python
If I run the following code, the error references the C drive:
import pymel.core as pm
# Error: If you manually installed pymel, ensure that pymel comes
before Maya's site-packages directory on PYTHONPATH / sys.path. See
pymel docs for more info.
# Traceback (most recent call last):
# File "<maya console>", line 1, in <module>
# File "c:\program files (x86)\autodesk\maya2009\python\lib\site-
packages\pymel-1.0.0-py2.5.egg\pymel\core\__init__.py", line 7, in
<module>
# File "c:\program files (x86)\autodesk\maya2009\python\lib\site-
packages\pymel-1.0.0-py2.5.egg\pymel\internal\__init__.py", line 4, in
<module>
# File "c:\program files (x86)\autodesk\maya2009\python\lib\site-
packages\pymel-1.0.0-py2.5.egg\pymel\internal\plogging.py", line 64,
in <module>
# AssertionError: If you manually installed pymel, ensure that pymel
comes before Maya's site-packages directory on PYTHONPATH / sys.path.
See pymel docs for more info. #
Thanks,
-brian