import requests
url = 'https://api.pwnedpasswords.com/range/' + 'passwords123'
res = requests.get()
print(res)
运行:
Traceback (most recent call last):
File "C:.py", line 1, in <module>
import requests
File "C:\Users\akhter\PycharmProjects\helloworld\venv\lib\site-packages\requests\__init__.py", line 116, in <module>
from .sessions import session, Session
ImportError: cannot import name 'session' from 'requests.sessions' (C:\Users\akhter\PycharmProjects\helloworld\venv\lib\site-packages\requests\sessions.py)
任何人都可以解释一下,为什么会出现此错误?