pydoc - how to generate documentation for an entire package?

J

Jens

I have a project/package for which I want to generate documentation
using pydoc.

My problem is that when I type "pydoc.py -w MyPackage" it only
generates documentation for the package - no modules, classes or
methods or sub-packages. Just a single HTML file called
"MyPackage.html"

That's strange - is there something here I'm missing. How do you
generate documentation for a whole package?
 
J

Jens

I have a project/package for which I want to generate documentation
usingpydoc.

My problem is that when I type "pydoc.py -w MyPackage" it only
generates documentation for the package - no modules, classes or
methods or sub-packages. Just a single HTML file called
"MyPackage.html"

That's strange - is there something here I'm missing. How do you
generate documentation for a whole package?

No suggestions? All I can think of is to make a *.bat file on Windows
to call pydoc.py for each of my modules. Seems like a silly solution.

Also, when I have a module that imports from math (for example),
pydoc.py generates a broken link to the math module. This just seems
very silly.

Generating documentation form code is a nice thing, but this pydoc.py
is driving me insane - isn't there are better way?
 
M

Marc 'BlackJack' Rintsch

Generating documentation form code is a nice thing, but this pydoc.py
is driving me insane - isn't there are better way?

Epydoc!?

Ciao,
Marc 'BlackJack' Rintsch
 
D

davisn90210

No suggestions? All I can think of is to make a *.bat file on Windows
to call pydoc.py for each of my modules. Seems like a silly solution.

Also, when I have a module that imports from math (for example),
pydoc.py generates a broken link to the math module. This just seems
very silly.

Generating documentation form code is a nice thing, but this pydoc.py
is driving me insane - isn't there are better way?

pydoc -h

[...]

pydoc -w <name> ...
Write out the HTML documentation for a module to a file in the
current
directory. If <name> contains a '/', it is treated as a filename;
if
it names a directory, documentation is written for all the
contents.

Have you tried pydoc -w <directory-containing-package>?

--Nathan Davis
 
J

Jens

No suggestions? All I can think of is to make a *.bat file on Windows
to call pydoc.py for each of my modules. Seems like a silly solution.
Also, when I have a module that imports from math (for example),
pydoc.py generates a broken link to the math module. This just seems
very silly.
Generating documentation form code is a nice thing, but this pydoc.py
is driving me insane - isn't there are better way?

pydoc -h

[...]

pydoc -w <name> ...
Write out the HTML documentation for a module to a file in the
current
directory. If <name> contains a '/', it is treated as a filename;
if
it names a directory, documentation is written for all the
contents.

Have you tried pydoc -w <directory-containing-package>?

--Nathan Davis

Yes, I have! It just generates a single html file. It just contains a
lot of broken links to non-existing module files. Strange!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top