zl程序教程

您现在的位置是:首页 >  Python

当前栏目

怎么看python包的版本

2023-03-20 15:28:51 时间

怎么看python包的版本

查看模块的版本有两种方法,具体如下
1.模块名.version:

>>> import requests
>>> requests.__version__
'2.18.4'

2.help(模块名) 看大概倒数的 VERSION 即版本号

>>>help(requests)
...
VERSION
    2.18.4

AUTHOR
    Kenneth Reitz

FILE
    d:pythonpython35libsite-packages
equests\__init__.py

更多学习内容,请点击Python学习网。