fromdistutilsimportlogfromdistutils.commandimportuploadasorigfromsetuptools.errorsimportRemovedCommandErrorclassupload(orig.upload):"""Formerly used to upload packages to PyPI."""defrun(self):msg=("The upload command has been removed, use twine to upload "+"instead (https://pypi.org/p/twine)")self.announce("ERROR: "+msg,log.ERROR)raiseRemovedCommandError(msg)