YouTube Viewer程序导入undetected_chromedriver._compat模块失败求助
解决 undetected_chromedriver._compat 模块缺失问题
卸载现有版本:先彻底移除当前安装的3.4版本,执行命令:
python3 -m pip uninstall -y undetected_chromedriver安装兼容指定版本:
_compat模块在新版本的undetected_chromedriver中可能被重构或移除了,你的YouTube Viewer程序大概率依赖旧版本的结构,试试安装3.1.6这个稳定版:python3 -m pip install undetected_chromedriver==3.1.6验证模块可用性:安装完成后,在终端运行以下命令测试模块是否能正常导入:
python3 -c "import undetected_chromedriver; print(undetected_chromedriver.__version__)"没报错的话,再启动你的YouTube Viewer程序。
环境一致性检查:如果还是不行,确认你的Python环境是否存在多版本冲突。用
which python3和which pip3查看路径,确保两者指向同一个环境。如果路径不一样,改用pip3 install命令来安装模块。
内容的提问来源于stack exchange,提问作者Noobie
相关产品推荐
相关产品推荐

