diff --git a/lib/python/pyflyby/_dbg.py b/lib/python/pyflyby/_dbg.py index 1fe36ee0..96a6a0a3 100644 --- a/lib/python/pyflyby/_dbg.py +++ b/lib/python/pyflyby/_dbg.py @@ -335,7 +335,7 @@ def _debug_exception(*exc_info, **kwargs): # Check if the instance is of IPython's Pdb and its version. try: import IPython - if IPython.__version__ >= '8.16': + if IPython.version_info >= (8, 16): from IPython.core.debugger import Pdb as IPdb # This is expected to be True, hence just a safe check. if isinstance(pdb, IPdb):