升级pip后无法用pip安装dns

qua*_*ato 2 python macos pip

日志不言自明。我运行了 pip,它说我需要升级它,所以我做到了。现在我仍然无法安装dns。

~/electrum/python electrum
Error: No module named 'dns'. Try 'sudo pip install <module-name>'
~/electrum/pip install dns
Collecting dns
  Could not find a version that satisfies the requirement dns (from versions: )
No matching distribution found for dns
~/electrum/git log
commit c8e67e2bd07efe042703bc1368d499c5e555f854 (HEAD -> master, origin/master, origin/HEAD)
Author: ThomasV <thomasv@electrum.org>
Run Code Online (Sandbox Code Playgroud)

Dim*_*man 7

似乎您需要“dnspython”包,该包由“dns”名称导入,这就是为什么您收到No module named 'dns'消息:) 试试这个

pip install dnspython
Run Code Online (Sandbox Code Playgroud)