diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2016-05-28 14:48:19 +0300 |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2016-05-28 14:48:19 +0300 |
commit | f5a86603829104d675112c1aa35f4a7bdd32110e (patch) | |
tree | f3427e72d0382510cc719e3817782ae290ab91ad /Lib/importlib/util.py | |
parent | 95de54494fb75a30f417c5bba1d0db4d54f57d29 (diff) | |
parent | c7aaeb9022c01fbc190a6c6eb9df9cf7b0c14347 (diff) | |
download | cpython-f5a86603829104d675112c1aa35f4a7bdd32110e.tar.gz |
Issue #27138: Regenerate Python/importlib_external.h.
Diffstat (limited to 'Lib/importlib/util.py')
-rw-r--r-- | Lib/importlib/util.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/importlib/util.py b/Lib/importlib/util.py index 4525b3f78e..af781fd4cd 100644 --- a/Lib/importlib/util.py +++ b/Lib/importlib/util.py @@ -22,8 +22,8 @@ def resolve_name(name, package): if not name.startswith('.'): return name elif not package: - raise ValueError('{!r} is not a relative name ' - '(no leading dot)'.format(name)) + raise ValueError(f'no package specified for {repr(name)} ' + '(required for relative module names)') level = 0 for character in name: if character != '.': |