Commit 4e694d6f authored by Brett Cannon's avatar Brett Cannon

tweak exception message (again)

parent ac0ad884
...@@ -668,11 +668,11 @@ def _validate_bytecode_header(data, source_stats=None, name=None, path=None): ...@@ -668,11 +668,11 @@ def _validate_bytecode_header(data, source_stats=None, name=None, path=None):
_verbose_message(message) _verbose_message(message)
raise ImportError(message, **exc_details) raise ImportError(message, **exc_details)
elif len(raw_timestamp) != 4: elif len(raw_timestamp) != 4:
message = 'reached EOF while reading magic number in {!r}'.format(name) message = 'reached EOF while reading timestamp in {!r}'.format(name)
_verbose_message(message) _verbose_message(message)
raise EOFError(message) raise EOFError(message)
elif len(raw_size) != 4: elif len(raw_size) != 4:
message = 'reached EOF while reading size in {!r}'.format(name) message = 'reached EOF while reading size of source in {!r}'.format(name)
_verbose_message(message) _verbose_message(message)
raise EOFError(message) raise EOFError(message)
if source_stats is not None: if source_stats is not None:
......
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment