mirror of
https://github.com/pypa/pip
synced 2023-12-13 21:30:23 +01:00
69143848b0
* Raise exception on exception in finding wheel dist We plan to replace this code with direct extraction from a zip, so no point catching anything more precise. * Raise exception if no dist is found in wheel_version * Catch file read errors when reading WHEEL get_metadata delegates to the underlying implementation which tries to locate and read the file, throwing an IOError (Python 2) or OSError subclass on any errors. Since the new explicit test checks the same case as brokenwheel in test_wheel_version we remove the redundant test. * Check for WHEEL decoding errors explicitly This was the last error that could be thrown by get_metadata, so we can also remove the catch-all except block. * Move WHEEL parsing outside try...except This API does not raise an exception, but returns any errors on the message object itself. We are preserving the original behavior, and can decide later whether to start warning or raising our own exception. * Raise explicit error if Wheel-Version is missing `email.message.Message.__getitem__` returns None on missing values, so we have to check for ourselves explicitly. * Raise explicit exception on failure to parse Wheel-Version This is also the last exception that can be raised, so we remove `except Exception`. * Remove dead code Since wheel_version never returns None, this exception will never be raised. |
||
---|---|---|
.. | ||
__init__.py | ||
certs.py | ||
configuration_helpers.py | ||
filesystem.py | ||
git_submodule_helpers.py | ||
local_repos.py | ||
options_helpers.py | ||
path.py | ||
requests_mocks.py | ||
scripttest.py | ||
server.py | ||
test_lib.py | ||
venv.py | ||
yaml_helpers.py |