Commit 80c6b750 authored by Jason R. Coombs's avatar Jason R. Coombs

Prefer new string formatting. Re-use variable names.

parent acd20ca3
......@@ -2521,14 +2521,15 @@ class Distribution(object):
return
tmpl = textwrap.dedent("""
'%s (%s)' is being parsed as a legacy, non PEP 440,
'{project_name} ({version})' is being parsed as a legacy,
non PEP 440,
version. You may find odd behavior and sort order.
In particular it will be sorted as less than 0.0. It
is recommend to migrate to PEP 440 compatible
versions.
""").strip().replace('\n', ' ')
warnings.warn(tmpl % (self.project_name, self.version), PEP440Warning)
warnings.warn(tmpl.format(**vars(self)), PEP440Warning)
@property
def version(self):
......
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