mirror of https://github.com/pypa/pip
parent
21d6327afb
commit
5d9bbcd5fd
|
@ -108,8 +108,6 @@ class UninstallCommand(Command, SessionCommandMixin):
|
|||
)
|
||||
if uninstall_pathset:
|
||||
uninstall_pathset.commit()
|
||||
if req.files_skipped:
|
||||
return ERROR
|
||||
if options.root_user_action == "warn":
|
||||
warn_if_run_as_root()
|
||||
return SUCCESS
|
||||
|
|
|
@ -678,7 +678,6 @@ class InstallRequirement:
|
|||
|
||||
uninstalled_pathset = UninstallPathSet.from_dist(dist)
|
||||
uninstalled_pathset.remove(auto_confirm, verbose)
|
||||
self.files_skipped = uninstalled_pathset.files_skipped
|
||||
return uninstalled_pathset
|
||||
|
||||
def _get_archive_name(self, path: str, parentdir: str, rootdir: str) -> str:
|
||||
|
|
|
@ -360,14 +360,12 @@ class UninstallPathSet:
|
|||
def remove(self, auto_confirm: bool = False, verbose: bool = False) -> None:
|
||||
"""Remove paths in ``self._paths`` with confirmation (unless
|
||||
``auto_confirm`` is True)."""
|
||||
self.files_skipped = False
|
||||
|
||||
if not self._paths:
|
||||
logger.info(
|
||||
"Can't uninstall '%s'. No files were found to uninstall.",
|
||||
self._dist.raw_name,
|
||||
)
|
||||
self.files_skipped = True
|
||||
return
|
||||
|
||||
dist_name_version = f"{self._dist.raw_name}-{self._dist.version}"
|
||||
|
|
Loading…
Reference in New Issue