Re: [Epydoc-devel] Package document problem?
Brought to you by:
edloper
From: Daniele V. <pi...@de...> - 2007-12-04 22:10:23
|
Ted Drain ha scritto: > I'm trying to create documentation for a package in a way that shows > the programmatic layout of the objects. For example: > > pkg/__init__.py: > from foo import bar > > pkg/foo.py: > class bar: ... > > I'm using the v3 beta release. Parsing is turned off, introspection > is turned on. I'd like the docs to show something like this: > > pkg/bar > > instead I get: > > pkg/foo > foo/bar > > The problem is that foo is just a file - it's not a module and is not > used by anyone who is trying to reference the package. I'd like the > docs to reflect how you need to write your code - i.e.: > > import pkg > x = pkg.bar() > > Am I missing something fundamental here? I've tried every > combination of introspect and parse but the docs always look the same. You can try adding __all__ = ['bar'] in pkg.__init__: it should enforce to epydoc that pkg is bar's parent in the public interface, and that foo.py is just an implementative detail. The feature should be independent from the analysis (parsing vs. introspection) technique. Bye! -- Daniele Varrazzo - Develer S.r.l. http://www.develer.com |