Skip to content

Commit 9fffde9

Browse files
committed
Drop Python 2.7 support
Upstream IPython dropped it in version 6.0.0, in April 2017. I think it's fine to drop it here now. Would also be good to use this opportunity to mark the release as 1.0.0.
1 parent fc83b4f commit 9fffde9

File tree

3 files changed

+3
-12
lines changed

3 files changed

+3
-12
lines changed

HISTORY.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Changelog
44
0.13.10 (unreleased)
55
--------------------
66

7-
- Nothing changed yet.
7+
- Drop Python 2.7 compatibility.
88

99

1010
0.13.9 (2021-06-02)

ipdb/__main__.py

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,7 @@
1616
from IPython.core.debugger import BdbQuit_excepthook
1717
from IPython.terminal.ipapp import TerminalIPythonApp
1818
from IPython.terminal.embed import InteractiveShellEmbed
19-
try:
20-
import configparser
21-
except:
22-
import ConfigParser as configparser
19+
import configparser
2320

2421

2522
def _get_debugger_cls():
@@ -255,11 +252,7 @@ def main():
255252
import sys
256253
import getopt
257254

258-
try:
259-
from pdb import Restart
260-
except ImportError:
261-
class Restart(Exception):
262-
pass
255+
from pdb import Restart
263256

264257
if sys.version_info >= (3, 7):
265258
opts, args = getopt.getopt(sys.argv[1:], 'mhc:', ['help', 'command='])

setup.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
description="IPython-enabled pdb",
3131
long_description=long_description,
3232
classifiers=[
33-
'Programming Language :: Python :: 2.7',
3433
'Programming Language :: Python :: 3',
3534
'Programming Language :: Python :: 3.4',
3635
'Programming Language :: Python :: 3.5',
@@ -58,7 +57,6 @@
5857
'setuptools',
5958
],
6059
extras_require={
61-
':python_version == "2.7"': ['ipython >= 5.1.0, < 6.0.0', 'toml >= 0.10.2', 'decorator < 5.0.0'],
6260
# No support for python 3.0, 3.1, 3.2.
6361
# FTR, `decorator` is also a dependency of Ipython.
6462
':python_version == "3.4"': ['ipython >= 6.0.0, < 7.0.0', 'toml >= 0.10.2', 'decorator < 5.0.0'],

0 commit comments

Comments
 (0)