Hello,
I'm working on the Graphite project and I can't seem to get automodule
to work. I'm sure it's something I'm doing wrong, but for the life of
me I can't figure out what.
I've put docstrings in a file called functions.py.
the relative path is ./webapp/render/functions.py.
Here's the error I get:
/opt/graphite/bzr/graphite/docs/functions.rst:4: (WARNING/2) autodoc
can't import/find module 'graphite.render.functions', it reported
error: "No module named graphite.render.functions", please check your
spelling and sys.path
Here's line 4 of functions.rst:
.. automodule:: graphite.render.functions
The next thing I tried is adding all directories with an __init__.py
to the sys.path in conf.py.
Here's all the non-comment lines from conf.py:
import sys, os
sys.path.append(os.path.abspath('../carbon/lib/carbon/tests'))
sys.path.append(os.path.abspath('../carbon/lib/carbon/aggregator'))
sys.path.append(os.path.abspath('../carbon/lib/carbon'))
sys.path.append(os.path.abspath('../webapp/graphite/cli'))
sys.path.append(os.path.abspath('../webapp/graphite/dashboard'))
sys.path.append(os.path.abspath('../webapp/graphite/render'))
sys.path.append(os.path.abspath('../webapp/graphite/metrics'))
sys.path.append(os.path.abspath('../webapp/graphite/composer'))
sys.path.append(os.path.abspath('../webapp/graphite/whitelist'))
sys.path.append(os.path.abspath('../webapp/graphite/account'))
sys.path.append(os.path.abspath('../webapp/graphite/browser'))
sys.path.append(os.path.abspath('../webapp/graphite'))
sys.path.append(os.path.abspath('../webapp/graphite/thirdparty/pytz'))
sys.path.append(os.path.abspath('../webapp/graphite/thirdparty'))
sys.path.append(os.path.abspath('../webapp/graphite/graphlot'))
extensions = ['sphinx.ext.autodoc']
templates_path = ['_templates']
source_suffix = '.rst'
master_doc = 'index'
project = u'Graphite'
copyright = u'2011, Chris Davis'
version = '0.9.8'
release = '0.9.8'
exclude_trees = ['_build']
pygments_style = 'sphinx'
html_theme = 'default'
html_static_path = ['_static']
htmlhelp_basename = 'Graphitedoc'
latex_documents = [
('index', 'Graphite.tex', u'Graphite Documentation',
u'Chris Davis', 'manual'),
]
It still didn't work. I changed the line to
.. automodule:: functions
and got a different error message:
(WARNING/2) autodoc can't import/find module 'functions', it reported
error: "No module named graphite.render.datalib", please check your
spelling and sys.path
(which is imported at the top of functions.py.
At this point, I'm lost. Can anyone help?
--
You received this message because you are subscribed to the Google Groups
"sphinx-dev" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sphinx-dev?hl=en.