I find IPython indispensable for this kind of task. The magic commands ?(show docstring) and ??(show source) in combination with the excellent IPython completion system and self-analysis of living objects really change.
Session Example:
In [1]: import sphinx.writers <TAB>
In [1]: import shpinx.writers.manpage as manpage
In [2]: manpage.<TAB>
In [3]: manpage.Writer?
In [4]: manpage.Writer??
In [5]: %edit manpage
In [6]: %edit manpage.Writer
Unfortunately, not all codes can be verified in this way. Think of projects that do things in modules without wrapping them in if __name__ == '__main__'or projects that are highly dependent on magic ( sh comes to mind).
source
share