mirror of
https://github.com/pypa/pip
synced 2023-12-13 21:30:23 +01:00
Prettify messages for discarding candidates due to issues
These are more pleasing colours and, more importantly, a clearer presentation style of the package vs the error.
This commit is contained in:
parent
1a0193f9e4
commit
a835e0a277
|
@ -191,7 +191,12 @@ class Factory:
|
|||
version=version,
|
||||
)
|
||||
except (InstallationSubprocessError, MetadataInconsistent) as e:
|
||||
logger.warning("Discarding %s. %s", link, e)
|
||||
logger.info(
|
||||
"Discarding [blue underline]%s[/]: [yellow]%s[reset]",
|
||||
link,
|
||||
e,
|
||||
extra={"markup": True},
|
||||
)
|
||||
self._build_failures[link] = e
|
||||
return None
|
||||
base: BaseCandidate = self._editable_candidate_cache[link]
|
||||
|
@ -206,7 +211,12 @@ class Factory:
|
|||
version=version,
|
||||
)
|
||||
except (InstallationSubprocessError, MetadataInconsistent) as e:
|
||||
logger.warning("Discarding %s. %s", link, e)
|
||||
logger.info(
|
||||
"Discarding [blue underline]%s[/]: [yellow]%s[reset]",
|
||||
link,
|
||||
e,
|
||||
extra={"markup": True},
|
||||
)
|
||||
self._build_failures[link] = e
|
||||
return None
|
||||
base = self._link_candidate_cache[link]
|
||||
|
|
|
@ -1362,7 +1362,7 @@ def test_new_resolver_skip_inconsistent_metadata(script: PipTestEnvironment) ->
|
|||
|
||||
assert (
|
||||
" inconsistent version: filename has '3', but metadata has '2'"
|
||||
) in result.stderr, str(result)
|
||||
) in result.stdout, str(result)
|
||||
script.assert_installed(a="1")
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue