Python3报错:from urllib import unquote ImportError: cannot import name 'unquote' from 'urllib' (/usr/lib/python3.11/urllib/__init__.py)

发布时间 2024年11月04日 22:33
阅读次数 628
分类 Python
0

在 Python 3 中,unquote 函数已被移至 urllib.parse模块。需要将.py文件中的from urllib import unquote改成from urllib.parse import unquote
Python3报错:from urllib import unquote ImportError: cannot import name 'unquote' from 'urllib' (/usr/lib/python3.11/urllib/__init__.py)

评论