pythonpydoc

'pydoc -w EXPRESSIONS' does not work but 'pydoc EXPRESSIONS' does. Why? (all capitalized help topics)


pydoc EXPRESSIONS work perfectly fine but pydoc -w EXPRESSIONS does not. Why is that? (the w option write the output to a html file) The same is true for other capitalized help topics such as FORMATTING or TUPLELITERALS.

Thanks!


Solution

  • If you look at the source you can see that when using the switch '-w' pydoc uses the function writedoc, otherwise to the class Helper. In the Helper-class EXPRESSIONS is defined under line 1666 . The function writedoc does not utilize this nor does it use the Helper class.

    Same for FORMATTING and TUPLELITERALS

    Might qualify for a bug report, in my opinion.