我最近下载IMDbpy模块.. 当我做,

import imdb
help(imdb)

我不得到完整的文件。我必须做的。

im = imdb.IMDb()
help(im)

以查看可用的方法。我不喜欢这个控制台界面。是否有读取DOC什么更好的办法。我的意思是在同一个页面相关的模块IMDB的文档。

有帮助吗?

解决方案

使用是pydoc

pydoc -w imdb

这将在相同的目录生成imdb.html。


pydoc -p 9090将开始在端口9090 HTTP服务器,你就可以浏览所有文件在的http://本地主机:9090 /

其他提示

IPython的你可以做

[1]: import os
[2]: os?

< get the full documentation here >

# or you could do it on specific functions 
[3]: os.uname
<built-in function>



[4]: os.uname?

< get the full documentation here >


# Incase of modules written in python, you could inspect source code by doing
[5]: import string
[6]: string??

< hows the source code of the module >

[7]: string.upper??

< shows the source code of the function >
许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top