【发布时间】:2020-08-01 00:54:22
【问题描述】:
所以我正在尝试下载适用于 python 的 Interactive Brokers API。我已经按照网站的说明下载了api,然后我去了source,python客户端,然后当我打开setup python文件时,文件会打开一个小黑屏然后立即关闭。我正在使用python 3.8。任何人对为什么会发生这种情况有任何想法(我在下面添加了我现在收到的错误)?谢谢
编辑: 当我在命令提示符中输入“C:\TWS API\source\pythonclient”,然后 python setup.py install,我得到错误:
running install
error: can't create or remove files in install directory
The following error occurred while trying to add or remove files in the
installation directory:
[Errno 13] Permission denied: 'C:\\Program Files\\WindowsApps\\PythonSoftwareFoundation.Python.3.7_3.7.2288.0_x64__qbz5n2kfra8p0\\Lib\\site-packages\\test-easy-install-13760.write-test'
The installation directory you specified (via --install-dir, --prefix, or
the distutils default setting) was:
C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.7_3.7.2288.0_x64__qbz5n2kfra8p0\Lib\site-packages\
Perhaps your account does not have write access to this directory? If the
installation directory is a system-owned directory, you may need to sign in
as the administrator or "root" account. If you do not have administrative
access to this machine, you may wish to choose a different installation
directory, preferably one that is listed in your PYTHONPATH environment
variable.
For information on other options, you may wish to consult the
documentation at:
https://setuptools.readthedocs.io/en/latest/easy_install.html
Please make the appropriate changes for your system and try again.
【问题讨论】:
-
你是如何运行这个文件的?您是否在 Windows 上并单击它运行?如果您打开命令提示符并在那里运行它,您可能会看到更好的信息。
-
我尝试通过命令提示符运行它并单击它。我试图通过 CMD 运行它,说“python setup.py install”,它说文件
python: can't open file 'setup.py': [Errno 2] No such file or directory -
这对@FishingCode 没有帮助
-
可能会在问题中添加更多详细信息/回溯本身。这个问题很模糊。
标签: python api python-3.8 interactive-brokers