Hello. While I try to build up my project I want to use autodoc so that I don't have to document everything twice. And I don't know why but it causes some trouble when i have something like this.
System: Fedora 15 64Bit Python: 3.2.0 (as server by the fedora-rpm) Sphinx: 1.1hg-20110621 (Revision: 3294:ad11ffd6e333) Jinja: 2.5.5 (as served by the fedora-rpm) Docutils: 0.80. (as served by the fedora-rpm) index:rst: > .. files documentation master file, created by > sphinx-quickstart on Tue Jun 21 10:31:49 2011. > You can adapt this file completely to your liking, but it should at least > contain the root `toctree` directive. > > Welcome to files's documentation! > ================================= > > .. automodule:: files.filetypes > > > Indices and tables > ================== > > * :ref:`genindex` > * :ref:`modindex` > * :ref:`search` The layout is simple. The main package is files and there's a subpackage filetypes. > PROJECTROOT > - doc > - files > - __init__.py > - filetypes > - __init__py # <- Want to access this! Content of files/__init__.py: > """ Main package """ (to keep it simple) Content of files/filetypes/__init__.py > """ filetypes """ When I call make html, the following comes up: > Running Sphinx v1.1pre > loading translations [en]... locale not available > loading pickled environment... done > loading intersphinx inventory from objects.inv... > building [html]: all source files > updating environment: 0 added, 1 changed, 0 removed > reading sources... [100%] filetypes/index > looking for now-outdated files... none found > pickling environment... done > checking consistency... done > preparing documents... done > writing output... [100%] index > writing additional files... (8 module code pages) _modules/index > genindex py-modindex > Exception occurred: > File "/usr/lib/python3.2/site-packages/jinja2/sandbox.py", line 204, in > is_safe_callable > return not (getattr(obj, 'unsafe_callable', False) or \ > jinja2.exceptions.UndefinedError: b"'sphinx.jinja2glue.idgen object' has no > attribute 'next'" > The full traceback has been saved in /tmp/sphinx-err-3xcaja.log, if you want > to report the issue to the developers. > Please also report this if it was a user error, so that a better error > message can be provided next time. > Either send bugs to the mailing list at > <http://groups.google.com/group/sphinx-dev/>, > or report them in the tracker at > <http://bitbucket.org/birkenfeld/sphinx/issues/>. Thanks! > make: *** [html] Fehler 1 The error-log says: > # Sphinx version: 1.1pre > # Python version: 3.2.0 > # Docutils version: 0.8 repository > # Jinja2 version: 2.5.5 > Traceback (most recent call last): > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/cmdline.py", > line 188, in main > app.build(force_all, filenames) > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/application.py", > line 200, in build > self.builder.build_all() > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/builders/__init__.py", > line 159, in build_all > self.build(None, summary='all source files', method='all') > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/builders/__init__.py", > line 255, in build > self.finish() > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/builders/html.py", > line 439, in finish > self.write_domain_indices() > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/builders/html.py", > line 503, in write_domain_indices > self.handle_page(indexname, indexcontext, 'domainindex.html') > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/builders/html.py", > line 723, in handle_page > output = self.templates.render(templatename, ctx) > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/jinja2glue.py", > line 127, in render > return self.environment.get_template(template).render(context) > File "/usr/lib/python3.2/site-packages/jinja2/environment.py", line 892, in > render > return self.environment.handle_exception(exc_info, True) > File "/usr/lib/python3.2/site-packages/jinja2/environment.py", line 668, in > handle_exception > raise exc_value.with_traceback(tb) > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/themes/basic/domainindex.html", > line 11, in <module> > {% set title = indextitle %} > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/themes/default/layout.html", > line 13, in <module> > {% set script_files = script_files + ['_static/sidebar.js'] %} > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/themes/basic/layout.html", > line 160, in <module> > {%- block content %} > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/themes/basic/layout.html", > line 164, in <module> > {%- block document %} > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/themes/basic/layout.html", > line 170, in <module> > {% block body %} {% endblock %} > File > "/usr/lib/python3.2/site-packages/Sphinx-1.1predev_20110621-py3.2.egg/sphinx/themes/basic/domainindex.html", > line 43, in <module> > id="toggle-{{ groupid.next() }}" style="display: none" alt="-" /> > File "/usr/lib/python3.2/site-packages/jinja2/sandbox.py", line 257, in call > if not __self.is_safe_callable(__obj): > File "/usr/lib/python3.2/site-packages/jinja2/sandbox.py", line 204, in > is_safe_callable > return not (getattr(obj, 'unsafe_callable', False) or \ > jinja2.exceptions.UndefinedError: b"'sphinx.jinja2glue.idgen object' has no > attribute 'next'" What can I do? The interesting fact is that it doesn't complain about the source while generating the single pages, neither for the index, only for py- modindex. Any suggestions? Kind regards, Chris -- You received this message because you are subscribed to the Google Groups "sphinx-dev" group. To post to this group, send email to sphinx-dev@googlegroups.com. To unsubscribe from this group, send email to sphinx-dev+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/sphinx-dev?hl=en.