吾情亦堪自难断 2021-05-14 19:19 采纳率: 50%
浏览 764
已结题

在PyCharm中安装不了BeautifulSoup包

提出的解决方案: 尝试从系统终端运行此命令。确保使用为位于 'C:\Users\DELL\PycharmProjects\pythonProject\venv\Scripts\python.exe' 处的 Python 解释器安装的正确 'pip' 版本。 命令输出: Collecting BeautifulSoup Using cached BeautifulSoup-3.2.2.tar.gz (32 kB) Using cached BeautifulSoup-3.2.1.tar.gz (31 kB) Using cached BeautifulSoup-3.2.0.tar.gz (31 kB) ERROR: Command errored out with exit status 1: command: 'C:\Users\DELL\PycharmProjects\pythonProject\venv\Scripts\python.exe' -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Windows\\TEMP\\pip-install-f7z6ravn\\beautifulsoup_ecb865e39a574b1d83e590c8eaed4efe\\setup.py'"'"'; __file__='"'"'C:\\Windows\\TEMP\\pip-install-f7z6ravn\\beautifulsoup_ecb865e39a574b1d83e590c8eaed4efe\\setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base 'C:\Windows\TEMP\pip-pip-egg-info-udzr4vxu' cwd: C:\Windows\TEMP\pip-install-f7z6ravn\beautifulsoup_ecb865e39a574b1d83e590c8eaed4efe\ Complete output (6 lines): Traceback (most recent call last): File "", line 1, in File "C:\Windows\TEMP\pip-install-f7z6ravn\beautifulsoup_ecb865e39a574b1d83e590c8eaed4efe\setup.py", line 3 "You're trying to run a very old release of Beautiful Soup under Python 3. This will not work."<>"Please use Beautiful Soup 4, available through the pip package 'beautifulsoup4'." ^ SyntaxError: invalid syntax ---------------------------------------- WARNING: Discarding https://files.pythonhosted.org/packages/40/f2/6c9f2f3e696ee6a1fb0e4d7850617e224ed2b0b1e872110abffeca2a09d4/BeautifulSoup-3.2.2.tar.gz#sha256=a04169602bff6e3138b1259dbbf491f5a27f9499dea9a8fbafd48843f9d89970 (from https://pypi.org/simple/beautifulsoup/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output. ERROR: Command errored out with exit status 1:

  • 写回答

4条回答 默认 最新

  • 关注

    你可以在cmd中运行pip show beautifulsoup4,找到所在位置删掉它再重新安装

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(3条)

报告相同问题?

问题事件

  • 系统已结题 3月3日
  • 已采纳回答 2月23日

悬赏问题

  • ¥15 在若依框架下实现人脸识别
  • ¥15 网络科学导论,网络控制
  • ¥100 安卓tv程序连接SQLSERVER2008问题
  • ¥15 利用Sentinel-2和Landsat8做一个水库的长时序NDVI的对比,为什么Snetinel-2计算的结果最小值特别小,而Lansat8就很平均
  • ¥15 metadata提取的PDF元数据,如何转换为一个Excel
  • ¥15 关于arduino编程toCharArray()函数的使用
  • ¥100 vc++混合CEF采用CLR方式编译报错
  • ¥15 coze 的插件输入飞书多维表格 app_token 后一直显示错误,如何解决?
  • ¥15 vite+vue3+plyr播放本地public文件夹下视频无法加载
  • ¥15 c#逐行读取txt文本,但是每一行里面数据之间空格数量不同