diff options
| author | Jason R. Coombs <jaraco@jaraco.com> | 2020-10-17 16:34:23 -0400 |
|---|---|---|
| committer | Jason R. Coombs <jaraco@jaraco.com> | 2020-10-17 16:34:23 -0400 |
| commit | 419087c45b105579f69d8bc729c1aa09eb493c17 (patch) | |
| tree | 88b2c194a60164aa460b378323b450423a7e88ee /setuptools/command/rotate.py | |
| parent | 38de858e37f9c7a90498ea78c78ed76aca835ad2 (diff) | |
| parent | 898ae04656066d88add9c0a8750f32f938d99716 (diff) | |
| download | python-setuptools-git-419087c45b105579f69d8bc729c1aa09eb493c17.tar.gz | |
Merge branch 'master' into debt/drop-py35
Diffstat (limited to 'setuptools/command/rotate.py')
| -rw-r--r-- | setuptools/command/rotate.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/setuptools/command/rotate.py b/setuptools/command/rotate.py index b89353f5..74795ba9 100644 --- a/setuptools/command/rotate.py +++ b/setuptools/command/rotate.py @@ -4,8 +4,6 @@ from distutils.errors import DistutilsOptionError import os import shutil -from setuptools.extern import six - from setuptools import Command @@ -36,9 +34,9 @@ class rotate(Command): raise DistutilsOptionError("Must specify number of files to keep") try: self.keep = int(self.keep) - except ValueError: - raise DistutilsOptionError("--keep must be an integer") - if isinstance(self.match, six.string_types): + except ValueError as e: + raise DistutilsOptionError("--keep must be an integer") from e + if isinstance(self.match, str): self.match = [ convert_path(p.strip()) for p in self.match.split(',') ] |
