Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[3.7] bpo-21060: Improve error message for "setup.py upload" without dist files (GH-5726) #5746

Merged
merged 1 commit into from
Feb 19, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion Lib/distutils/command/upload.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ def finalize_options(self):

def run(self):
if not self.distribution.dist_files:
msg = "No dist file created in earlier command"
msg = ("Must create and upload files in one command "
"(e.g. setup.py sdist upload)")
raise DistutilsOptionError(msg)
for command, pyversion, filename in self.distribution.dist_files:
self.upload_file(command, pyversion, filename)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Rewrite confusing message from setup.py upload from
"No dist file created in earlier command" to the more helpful
"Must create and upload files in one command".