Am Sonntag, 3. Februar 2008 schrieb Edward Loper:
> > If a package is available globally to the system in addition to the
> > version in the local directory epydoc seems to prefer the global file
> > over the local in some occasions when building the package's API.
>
> What command line arguments are you using, and what directory are you
> executing it from? Also, try running epydoc with "--parse-only", and
> running it with "--introspect-only", to see if both parsing &
> introspection are picking up the wrong copy, or just one of them.
Out of convenience I'm setting these in the config file right now. Either way
both parsing & introspection will give me the same reponse as that my latest
changes aren't reflected.
I'm calling "epydoc -v --config epydoc_config" on the project's root source
directory, where file AAA (see previous mail) lies in. File BBB lies beneath
in a subdirectory.
I had to comment out the subdirectory for the "modules" directive, as
strangely enough I received an exception during building the API when either
way one of parsing & intospection is turned off. Though we might want to
handle this seperately I'll append the error and the piece of code that
generates it. The error generating file CCC lies in the subdirectory.
Now thinks get a bit more interesting. When commenting out the variable
definition in File CCC that gives me the error message I receive a different
behaviour: having both p&i turned on, the later changes are not reflected.
Turning introspect off gives me the newest version, turning parsing off gives
me the error on building.
Funnily enough that gives me a different result compared to yesterday. Both
BBB and CCC lie in the same subdirectory. Right now I can't reproduce the
results from yesterday (for BBB). I did some changes to the code yesterday
though.
I'll append my config file too.
HTH, thank you both for your quick reply.
Christoph
[EMAIL PROTECTED]:~/dokumente/CJK/cjklib/src$ epydoc -v --config epydoc_config
Exception in template write_function_details_entry() on line 100: 00:00
var_doc.overrides.value.docstring not in (None, UNKNOWN)):------]
Traceback (most recent call last):': cjklib.build.CEDICTBuilder-class.html
File "/usr/bin/epydoc", line 13, in ?
cli()
File "/var/lib/python-support/python2.4/epydoc/cli.py", line 946, in cli
main(options, names)
File "/var/lib/python-support/python2.4/epydoc/cli.py", line 764, in main
write_html(docindex, options)
File "/var/lib/python-support/python2.4/epydoc/cli.py", line 804, in
write_html
html_writer.write(options.target)
File "/var/lib/python-support/python2.4/epydoc/docwriter/html.py", line 630,
in write
self._write(self.write_class, directory, filename, doc)
File "/var/lib/python-support/python2.4/epydoc/docwriter/html.py", line 700,
in _write
write_func(f.write, *args)
File "/var/lib/python-support/python2.4/epydoc/docwriter/html.py", line 896,
in write_class
self.write_details_list(out, "Method Details", doc, "method")
File "/var/lib/python-support/python2.4/epydoc/docwriter/html.py", line 2152,
in write_details_list
self.write_details_entry(out, var_doc)
File "/var/lib/python-support/python2.4/epydoc/docwriter/html.py", line 2177,
in write_details_entry
div_class)
File "<string>", line 100, in write_function_details_entry
File "/var/lib/python-support/python2.4/epydoc/docwriter/html.py", line 3186,
in href
raise ValueError("href() should not be called with "
ValueError: href() should not be called with GenericValueDoc objects (perhaps
you meant to use the containing variable?)
class CEDICTBuilder(CEDICTFormatBuilder):
"""
Builds the CEDICT dictionary.
"""
def filterUmlaut(self, entry):
"""
Converts the C{'u:'} for C{'ü'}.
@type entry: string tuple
@param entry: a dictionary entry
@rtype: string tuple
@return: the given entry with corrected ü-voul
"""
trad, simp, reading, translation = entry
reading = reading.replace('u:', u'ü'.encode(self.ENCODING))
return [trad, simp, reading, translation]
PROVIDES = 'CEDICT'
FILE_NAMES = ['cedictu8.zip', 'cedict_ts.u8']
ZIP_CONTENT_NAME = 'cedict_ts.u8'
ENCODING = 'utf-8'
FILTER = filterUmlaut # the line generating the exception
[epydoc] # Epydoc section marker (required by ConfigParser)
# The list of objects to document. Objects can be named using
# dotted names, module filenames, or package directory names.
# Alases for this option include "objects" and "values".
modules: cjknife buildcjkdb cjklib
# The type of output that should be generated. Should be one
# of: html, text, latex, dvi, ps, pdf.
output: html
# The path to the output directory. May be relative or absolute.
target: doc/
# An integer indicating how verbose epydoc should be. The default
# value is 0; negative values will supress warnings and errors;
# positive values will give more verbose output.
verbosity: 0
# A boolean value indicating that Epydoc should show a tracaback
# in case of unexpected error. By default don't show tracebacks
debug: 1
# If True, don't try to use colors or cursor control when doing
# textual output. The default False assumes a rich text prompt
simple-term: 0
### Generation options
# The default markup language for docstrings, for modules that do
# not define __docformat__. Defaults to epytext.
docformat: epytext
# Whether or not parsing should be used to examine objects.
parse: yes
# Whether or not introspection should be used to examine objects.
introspect: yes
# Don't examine in any way the modules whose dotted name match this
# regular expression pattern.
#exclude
# Don't perform introspection on the modules whose dotted name match this
# regular expression pattern.
#exclude-introspect
# Don't perform parsing on the modules whose dotted name match this
# regular expression pattern.
#exclude-parse
# The format for showing inheritance objects.
# It should be one of: 'grouped', 'listed', 'included'.
inheritance: listed
# Whether or not to inclue private variables. (Even if included,
# private variables will be hidden by default.)
private: no
# Whether or not to list each module's imports.
imports: no
# Whether or not to include syntax highlighted source code in
# the output (HTML only).
sourcecode: yes
# Whether or not to includea a page with Epydoc log, containing
# effective option at the time of generation and the reported logs.
include-log: no
### Output options
# The documented project's name.
name: cjklib
# The CSS stylesheet for HTML output. Can be the name of a builtin
# stylesheet, or the name of a file.
css: white
# The documented project's URL.
url: http://cjklib.berlios.de/
# HTML code for the project link in the navigation bar. If left
# unspecified, the project link will be generated based on the
# project's name and URL.
#link: <a href="somewhere">My Cool Project</a>
# The "top" page for the documentation. Can be a URL, the name
# of a module or class, or one of the special names "trees.html",
# "indices.html", or "help.html"
top: cjklib
# An alternative help file. The named file should contain the
# body of an HTML file; navigation bars will be added to it.
#help: my_helpfile.html
# Whether or not to include a frames-based table of contents.
frames: yes
# Whether each class should be listed in its own section when
# generating LaTeX or PDF output.
separate-classes: no
### API linking options
# Define a new API document. A new interpreted text role
# will be created
#external-api: epydoc
# Use the records in this file to resolve objects in the API named NAME.
#external-api-file: epydoc:api-objects.txt
# Use this URL prefix to configure the string returned for external API.
#external-api-root: epydoc:http://epydoc.sourceforge.net/api
### Graph options
# The list of graph types that should be automatically included
# in the output. Graphs are generated using the Graphviz "dot"
# executable. Graph types include: "classtree", "callgraph",
# "umlclass". Use "all" to include all graph types
#graph: all
# The path to the Graphviz "dot" executable, used to generate
# graphs.
dotpath: /usr/bin/dot
# The name of one or more pstat files (generated by the profile
# or hotshot module). These are used to generate call graphs.
#pstat: profile.out
# Specify the font used to generate Graphviz graphs.
# (e.g., helvetica or times).
graph-font: Helvetica
# Specify the font size used to generate Graphviz graphs.
graph-font-size: 10
### Return value options
# The condition upon which Epydoc should exit with a non-zero
# exit status. Possible values are error, warning, docstring_warning
#fail-on: error