diff options
author | Hugo <hugovk@users.noreply.github.com> | 2018-06-19 07:27:00 -0400 |
---|---|---|
committer | Hugo <hugovk@users.noreply.github.com> | 2018-06-19 07:27:00 -0400 |
commit | a355099628a28b21f2e61600a84011cb1be32756 (patch) | |
tree | a403aebe9ebbc167189303b6a1b0e2edc826156d /__main__.py | |
parent | 1bbfe7e938d0250a1bb777492f617e95349abc5d (diff) | |
download | python-coveragepy-git-a355099628a28b21f2e61600a84011cb1be32756.tar.gz |
Drop support for EOL 2.5, 2.6 and 3.3
Diffstat (limited to '__main__.py')
-rw-r--r-- | __main__.py | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/__main__.py b/__main__.py index c998e1da..f1f2b4f6 100644 --- a/__main__.py +++ b/__main__.py @@ -8,12 +8,5 @@ import os PKG = 'coverage' -try: - run_globals = runpy.run_module(PKG, run_name='__main__', alter_sys=True) - executed = os.path.splitext(os.path.basename(run_globals['__file__']))[0] - if executed != '__main__': # For Python 2.5 compatibility - raise ImportError( - 'Incorrectly executed %s instead of __main__' % executed - ) -except ImportError: # For Python 2.6 compatibility - runpy.run_module('%s.__main__' % PKG, run_name='__main__', alter_sys=True) +run_globals = runpy.run_module(PKG, run_name='__main__', alter_sys=True) +executed = os.path.splitext(os.path.basename(run_globals['__file__']))[0] |