错误:ModuleNotFoundError:没有名为'requests'的模块

问题描述 投票:0回答:1

我尝试从Django中的请求导入响应:

from requests import Response

错误:

  from requests import Response
  ModuleNotFoundError: No module named 'requests'
python django
1个回答
0
投票

通过从cli运行pip install requests安装请求。该库不是默认python设置的一部分。

© www.soinside.com 2019 - 2024. All rights reserved.