【发布时间】:2017-12-29 00:18:05
【问题描述】:
我正在尝试在 Windows 上安装 os python 模块。
在cmd 控制台中,我输入了:
C:\Users\username> pip install os
Collecting os
Could not find a version that satisfies the requirement os (from versions: )
No matching distribution found for os
所以我猜测由于某些原因该模块在 Windows 上不可用,但我在一些 SO 问题中找到了它的引用。
显然,在 Google 中输入 Windows 和 os 只会给我关于 Windows 本身的答案。
那么,如何在 Windows 上安装 os 模块?
【问题讨论】:
-
你为什么要安装它?
os是标准库的一部分,所以如果你有 Python,你已经有os。 docs.python.org/2/library/os.html -
os是标准的 Python 模块,无需安装。 -
@MattBall emacs jedi 需要它,但没有找到它在控制台中时,os 函数返回
no module named os -
这听起来像是the XY problem 的一个例子。我建议您在 emacs jedi 的上下文中发布另一个问题,其中包含您所看到的特定错误的详细信息。
标签: python