我按照以下说明安装了 electrumhttps://electrum.org/#download
安装依赖项: sudo apt-get install python3-setuptools python3-pyqt5 python3-pip
安装 Electrum: sudo pip3 installhttps://download.electrum.org/3.1.1/Electrum-3.1.1.tar.gz
操作系统是linux mint 17
当我通过应用程序菜单单击金币图标时,没有任何反应。我已经安装了 electrum-ltc 并且它正在工作。由于安装了 electrum,它将无法运行。
如果我尝试通过命令行启动它,我会收到以下错误:
$ ./金币
/usr/local/lib/python3.4/dist-packages/requests/__init__.py:80: RequestsDependencyWarning: urllib3 (1.7.1) or chardet (2.2.1) doesn't match a supported version!
RequestsDependencyWarning)
Error: cannot import name 'DependencyWarning'. Try 'sudo pip install <module-name>'
尝试更新 urllib3 和 chardet 我收到以下错误:
$ sudo pip 安装 urllib3
Requirement already satisfied (use --upgrade to upgrade): urllib3 in /usr/lib/python2.7/dist-packages Cleaning up...
$ pip install --升级 urllib3
Downloading/unpacking urllib3 from https://pypi.python.org/packages/63/cb/6965947c13a94236f6d4b8223e21beb4d576dc72e8130bd7880f600839b8/urllib3-1.22-py2.py3-none-any.whl#md5=1c11e1c80371cc4e89911071010a98d1
Downloading urllib3-1.22-py2.py3-none-any.whl (132kB): 132kB downloaded
Installing collected packages: urllib3
Found existing installation: urllib3 1.7.1
Not uninstalling urllib3 at /usr/lib/python2.7/dist-packages, owned by OS
Can't roll back urllib3; was not uninstalled
Cleaning up...
Exception:
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 122, in main
status = self.run(options, args)
File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line 283, in run
requirement_set.install(install_options, global_options, root=options.root_path)
File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1436, in install
requirement.install(install_options, global_options, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/pip/req.py", line 672, in install
self.move_wheel_files(self.source_dir, root=root)
File "/usr/lib/python2.7/dist-packages/pip/req.py", line 902, in move_wheel_files
pycompile=self.pycompile,
File "/usr/lib/python2.7/dist-packages/pip/wheel.py", line 206, in move_wheel_files
clobber(source, lib_dir, True)
File "/usr/lib/python2.7/dist-packages/pip/wheel.py", line 193, in clobber
os.makedirs(destsubdir)
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/urllib3'
如何更新 urllib3?
或者问题与我安装的依赖项有关?
“安装依赖项:sudo apt-get install python3-setuptools python3-pyqt5 python3-pip”
在我安装上面的 Electrum (btc) 依赖项之前,Electrum-ltc 工作正常。
答案1
你的问题是你的系统中有两个 python 安装,python2.7
并且python3.4
.该pip
命令引用 的包管理器python2.7
,因此当您发出 时pip install urllib3
,您正在尝试安装/更新urllib3
错误版本的 Python 的包 - 用于pip3
安装/更新 Python 3 的包:
$ pip3 install chardet urllib3 --upgrade --user
顺便说一句,我不想调用sudo pip
/sudo pip3
因为一些 python 包是由apt
(如pip
它本身setuptools
或requests
)管理的,所以如果你首先安装了
$ apt install python3-setuptools
然后开始sudo pip3 install
打包,迟早你会破坏东西,因为setuptools
它被许多 python 包声明为依赖项,并且你会意外地覆盖python3-setuptools
安装。sudo apt install
如果apt
没有提供您需要的软件包或提供旧版本,那么它会更安全pip install --user
。