我這裏試了幾種辦法,希望對你有幫助我的原因是pip沒有更新,開始以爲是網絡問題.
1.在這裏面用阿里的鏡像,把這個複製進pip裏,在cmd在下載.自己看路徑哦.
[global]
index-url = http://mirrors.aliyun.com/pypi/simple/
[install]
trusted-host = mirrors.aliyun.com
2.更新pip,在cmd裏面輸入python -m pip install --upgrade pip就可以更新了
3.https://www.zhihu.com/question/30047496這是第三方法,進入它裏面的那個網址按cntl+f 可以快速查找lxml.感覺很卡就重啓一下,下載你所需要的lxml.