Hi Tomek,

I am currently facing this same issue. Could you let me know if you found a 
solution to this, and if yes, what was it?

Best Regards,


On Monday, 18 April 2016 13:24:25 UTC+5:30, Tomek P wrote:
>
> Hi,
>
> I'm a fresh Sphinx user and I came across this problem. In my python 
> package I have a bunch of imports from Autodesk Maya package. To generate 
> docs I placed following section in my conf.py:
> autodoc_mock_imports = [
>     'maya',
>     'maya.cmds',
>     'maya.mel',
>     'maya.OpenMaya',
>     'pymel.core'
> ]
>
> Everything is fine until pymel.core comes in. I get this:
>
> c:\__docs\fcgmaya.rst:587: WARNING: autodoc: failed to import module 
> u'fcgmaya'; the following exception was raised:
> Traceback (most recent call last):
>   File "c:\python27\lib\site-packages\sphinx\ext\autodoc.py", line 385, in 
> import_object
>     __import__(self.modname)
>   File "c:/__fcg/lib/maya/modules/fcg/scripts\fcgmaya\__init__.py", line 
> 3, in <module>
>     from interface import *
>   File "c:/__fcg/lib/maya/modules/fcg/scripts\fcgmaya\interface.py", line 
> 5, in <module>
>     from pymel.core import *
> TypeError: 'type' object does not support indexing
>
> As you can see, I import pymel by:
> from pymel.core import *
>
> I know I should not import this way, but fixing these old modules would 
> take too much time.
>
> How can I get around this? I don't want to document pymel, I just have no 
> idea how to ignore it.
>
> Regards,
> Tomek
>

-- 
You received this message because you are subscribed to the Google Groups 
"sphinx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sphinx-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to