diff options
author | Jason R. Coombs <jaraco@jaraco.com> | 2019-01-27 10:02:52 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-01-27 10:02:52 -0500 |
commit | 0551421f082eea3f633bc6be23c16a04483aca98 (patch) | |
tree | 76c5b37e3a56a232b4b5b66ab7e933edbe64cd25 /setuptools/command/egg_info.py | |
parent | 28872fc9e7d15a1acf3bc557795c76c5e64dbad3 (diff) | |
parent | 78fd73026ad7284819936b651f7cfbe8a1ec98c8 (diff) | |
download | external_python_setuptools-0551421f082eea3f633bc6be23c16a04483aca98.tar.gz external_python_setuptools-0551421f082eea3f633bc6be23c16a04483aca98.tar.bz2 external_python_setuptools-0551421f082eea3f633bc6be23c16a04483aca98.zip |
Merge branch 'master' into license-fix-357
Diffstat (limited to 'setuptools/command/egg_info.py')
-rw-r--r-- | setuptools/command/egg_info.py | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/setuptools/command/egg_info.py b/setuptools/command/egg_info.py index 93100ab9..5d8f451e 100644 --- a/setuptools/command/egg_info.py +++ b/setuptools/command/egg_info.py @@ -31,7 +31,7 @@ import setuptools.unicode_utils as unicode_utils from setuptools.glob import glob from setuptools.extern import packaging - +from setuptools import SetuptoolsDeprecationWarning def translate_pattern(glob): """ @@ -576,6 +576,12 @@ class manifest_maker(sdist): self.filelist.extend(rcfiles) elif os.path.exists(self.manifest): self.read_manifest() + + if os.path.exists("setup.py"): + # setup.py should be included by default, even if it's not + # the script called to create the sdist + self.filelist.append("setup.py") + ei_cmd = self.get_finalized_command('egg_info') self.filelist.graft(ei_cmd.egg_info) @@ -697,7 +703,7 @@ def get_pkg_info_revision(): Get a -r### off of PKG-INFO Version in case this is an sdist of a subversion revision. """ - warnings.warn("get_pkg_info_revision is deprecated.", DeprecationWarning) + warnings.warn("get_pkg_info_revision is deprecated.", EggInfoDeprecationWarning) if os.path.exists('PKG-INFO'): with io.open('PKG-INFO') as f: for line in f: @@ -705,3 +711,7 @@ def get_pkg_info_revision(): if match: return int(match.group(1)) return 0 + + +class EggInfoDeprecationWarning(SetuptoolsDeprecationWarning): + """Class for warning about deprecations in eggInfo in setupTools. Not ignored by default, unlike DeprecationWarning.""" |