如何安装upstox
? pip install upstox
未在bash控制台上安装模块。
11:54 ~ $ pip install upstox
Collecting upstox
Using cached upstox-1.5.5-py2.py3-none-any.whl
Requirement already satisfied (use --upgrade to upgrade): requests in /usr/local/lib/python2.7/dist-packages (from upstox)
Requirement already satisfied (use --upgrade to upgrade): future in /usr/local/lib/python2.7/dist-packages (from upstox)
Collecting websocket-client (from upstox)
Using cached websocket_client-0.46.0-py2.py3-none-any.whl
Requirement already satisfied (use --upgrade to upgrade): argparse in /usr/lib/python2.7 (from future->upstox)
Requirement already satisfied (use --upgrade to upgrade): importlib in /usr/local/lib/python2.7/dist-packages (from future->upstox)
Requirement already satisfied (use --upgrade to upgrade): six in /usr/local/lib/python2.7/dist-packages (from websocket-client->upstox)
Installing collected packages: websocket-client, upstox
Exception:
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/pip/basecommand.py", line 215, in main
status = self.run(options, args)
File "/usr/local/lib/python2.7/dist-packages/pip/commands/install.py", line 317, in run
prefix=options.prefix_path,
File "/usr/local/lib/python2.7/dist-packages/pip/req/req_set.py", line 742, in install
**kwargs
File "/usr/local/lib/python2.7/dist-packages/pip/req/req_install.py", line 831, in install
self.move_wheel_files(self.source_dir, root=root, prefix=prefix)
File "/usr/local/lib/python2.7/dist-packages/pip/req/req_install.py", line 1032, in move_wheel_files
isolated=self.isolated,
File "/usr/local/lib/python2.7/dist-packages/pip/wheel.py", line 346, in move_wheel_files
clobber(source, lib_dir, True)
File "/usr/local/lib/python2.7/dist-packages/pip/wheel.py", line 317, in clobber
ensure_dir(destdir)
File "/usr/local/lib/python2.7/dist-packages/pip/utils/__init__.py", line 83, in ensure_dir
os.makedirs(path)
File "/usr/lib/python2.7/os.py", line 157, in makedirs
mkdir(name, mode)
OSError: [Errno 13] Permission denied: '/usr/local/lib/python2.7/dist-packages/websocket_client-0.46.0.dist-info'
11:54 ~ $
答案 0 :(得分:2)
This help page on the PythonAnywhere site有关于使用pip在那里安装内容时需要做的一些额外事情的说明。基本上,您需要使用--user
标志或使用virtualenv。
答案 1 :(得分:0)
只使用--user标志示例:
pip3 install --user django-js-reverse