From 7628e5add6ead8ef3dcbfa3e5794363962ebc968 Mon Sep 17 00:00:00 2001 From: Carlos Cordoba Date: Wed, 11 Oct 2023 08:29:48 -0500 Subject: [PATCH 1/2] CI: Remove pin on IPython 8.14 --- .github/scripts/install.sh | 8 -------- 1 file changed, 8 deletions(-) diff --git a/.github/scripts/install.sh b/.github/scripts/install.sh index b75e8f98482..d6418bc970c 100755 --- a/.github/scripts/install.sh +++ b/.github/scripts/install.sh @@ -26,10 +26,6 @@ if [ "$USE_CONDA" = "true" ]; then # Remove pylsp before installing its subrepo below micromamba remove --force python-lsp-server python-lsp-server-base -y - # IPython 8.15 broke the %debug magic, which is used in some of our tests. - # So, pinning it to 8.14 for now. - micromamba install ipython=8.14 - else # Update pip and setuptools python -m pip install -U pip setuptools wheel build @@ -52,10 +48,6 @@ else pip install pyqt5==5.12.* pyqtwebengine==5.12.* fi - # IPython 8.15 broke the %debug magic, which is used in some of our tests. - # So, pinning it to 8.14 for now. - pip install ipython==8.14.0 - fi # Install subrepos from source From 5dab5ae8b81420b89e419427ab190aeb10f58c11 Mon Sep 17 00:00:00 2001 From: Carlos Cordoba Date: Wed, 11 Oct 2023 09:34:31 -0500 Subject: [PATCH 2/2] git subrepo pull (merge) external-deps/spyder-kernels subrepo: subdir: "external-deps/spyder-kernels" merged: "072c6cf31a" upstream: origin: "https://github.com/spyder-ide/spyder-kernels.git" branch: "2.x" commit: "072c6cf31a" git-subrepo: version: "0.4.3" origin: "https://github.com/ingydotnet/git-subrepo" commit: "2f68596" --- external-deps/spyder-kernels/.gitrepo | 4 ++-- .../spyder_kernels/customize/spyderpdb.py | 14 +++++++++++++- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/external-deps/spyder-kernels/.gitrepo b/external-deps/spyder-kernels/.gitrepo index 1ca8263dc35..12bdc618184 100644 --- a/external-deps/spyder-kernels/.gitrepo +++ b/external-deps/spyder-kernels/.gitrepo @@ -6,7 +6,7 @@ [subrepo] remote = https://github.com/spyder-ide/spyder-kernels.git branch = 2.x - commit = 3d3791284093015f1ad09dd8f959f67bd11a356b - parent = 324cf7eab940e8681bcf4deb250772fc35ae192e + commit = 072c6cf31a0f438ee4122bfdd14a9cfcec37b69c + parent = 7628e5add6ead8ef3dcbfa3e5794363962ebc968 method = merge cmdver = 0.4.3 diff --git a/external-deps/spyder-kernels/spyder_kernels/customize/spyderpdb.py b/external-deps/spyder-kernels/spyder_kernels/customize/spyderpdb.py index f988f25269b..7f687e5c2bb 100755 --- a/external-deps/spyder-kernels/spyder_kernels/customize/spyderpdb.py +++ b/external-deps/spyder-kernels/spyder_kernels/customize/spyderpdb.py @@ -320,20 +320,32 @@ def interaction(self, frame, traceback): If this is from sigint, break on the upper frame. If the frame is in spydercustomize.py, quit. Notifies spyder and print current code. - """ if self._pdb_breaking: self._pdb_breaking = False if frame and frame.f_back: return self.interaction(frame.f_back, traceback) + # This is necessary to handle chained exceptions in Pdb, support for + # which was added in IPython 8.15 and will be the default in Python + # 3.13 (see ipython/ipython#14146). + if isinstance(traceback, BaseException): + _chained_exceptions, tb = self._get_tb_and_exceptions(traceback) + + with self._hold_exceptions(_chained_exceptions): + self.interaction(frame, tb) + + return + self.setup(frame, traceback) self.print_stack_entry(self.stack[self.curindex]) + if self._frontend_notified: self._cmdloop() else: with DebugWrapper(self): self._cmdloop() + self.forget() def print_stack_entry(self, frame_lineno, prompt_prefix='\n-> ',