cx_Oracle installation fails with FileNotFoundError: [WinError 3]

cx_Oracle installation fails with FileNotFoundError: [WinError 3]

我的组织不允许我使用 pip 安装 Python 库,因此我下载了 cx_Oracle 的 zip (python-cx_Oracle-master.zip) 从 GIT 然后尝试使用安装命令安装它,如下所示:

python.exe ./setup.py install

但是,它立即失败并出现以下错误:

  File ".\setup.py", line 91, in <module>
    for n in sorted(os.listdir(dpiSourceDir)) if n.endswith(".c")]
FileNotFoundError: [WinError 3] The system cannot find the path specified: 'odpi\src' 

我想了很多头脑风暴都没有得出结论。虽然 cx_Oracle 对我继续我的项目很重要,但我找不到前进的方向。请求你们的帮助。

我在 Windows10 x64 机器上,Python 3.6

您缺少 ODPI-C 源代码。您需要按照文档 here.

中的说明进行操作