sphinx-automodapi icon indicating copy to clipboard operation
sphinx-automodapi copied to clipboard

automodapi fails on certain modules only

Open tbhkuiper opened this issue 5 years ago • 1 comments

I have a package with Sphinx documentation at https://sdrast.github.io/Data_Reduction/. automodapi fails on certain modules in the package with the error:

Exception occurred:
  File "/usr/local/anaconda3/lib/python3.7/site-packages/sphinx_automodapi/utils.py", line 99, in find_mod_objs
    fqnames.append(obj.__module__ + '.' + obj.__name__)
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'
The full traceback has been saved in /tmp/sphinx-err-7q488zfz.log, if you want to report the issue to the developers.

This happens after compiling the module because if there is an error in the module it reports that first. For now I comment out those modules in index.rst (as you'll see if you look at the web page linked above). sphinx-err-7q488zfz.log

tbhkuiper avatar Jun 13 '20 01:06 tbhkuiper

The problem was caused by having from pylab import * in those modules. I don't know why that should have been a problem but now I know how to avoid it.

tbhkuiper avatar Jul 01 '20 22:07 tbhkuiper