Skip to content

Commit 2579651

Browse files
committed
Remove "built with" comment in setup.py upload
platform.dist() is deprecated and slated for removal in Python 3.8. The upload command itself should also not be used to upload to PyPI, but while it continues to exist it should not use deprecated functions. Fixes bpo-35186
1 parent fd512d7 commit 2579651

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

Lib/distutils/command/upload.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -121,14 +121,8 @@ def upload_file(self, command, pyversion, filename):
121121
'requires': meta.get_requires(),
122122
'obsoletes': meta.get_obsoletes(),
123123
}
124-
comment = ''
125-
if command == 'bdist_rpm':
126-
dist, version, id = platform.dist()
127-
if dist:
128-
comment = 'built for %s %s' % (dist, version)
129-
elif command == 'bdist_dumb':
130-
comment = 'built for %s' % platform.platform(terse=1)
131-
data['comment'] = comment
124+
125+
data['comment'] = ''
132126

133127
if self.sign:
134128
data['gpg_signature'] = (os.path.basename(filename) + ".asc",

0 commit comments

Comments
 (0)