File tree Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -273,8 +273,7 @@ function use_library_from_git {
273273function lib_installed_from_git {
274274 local name=$1
275275 local safe_name
276- safe_name=$( python -c " from pkg_resources import safe_name; \
277- print(safe_name('${name} '))" )
276+ safe_name=$( python -c " from packaging import canonicalize_name; print(canonicalize_name('${name} '))" )
278277 # Note "pip freeze" doesn't always work here, because it tries to
279278 # be smart about finding the remote of the git repo the package
280279 # was installed from. This doesn't work with zuul which clones
Original file line number Diff line number Diff line change 8484 # python3-setuptools RPM are deleted, it breaks some tools such as semanage
8585 # (used in diskimage-builder) that use the -s flag of the python
8686 # interpreter, enforcing the use of the packages from /usr/lib.
87- # Importing setuptools/pkg_resources in a such environment fails.
87+ # Importing setuptools in a such environment fails.
8888 # Enforce the package re-installation to fix those applications.
8989 if is_package_installed python3-setuptools; then
9090 sudo dnf reinstall -y python3-setuptools
You can’t perform that action at this time.
0 commit comments