Skip to content

Commit

Permalink
IPython console: Catch an error that appears only on testing
Browse files Browse the repository at this point in the history
  • Loading branch information
ccordoba12 committed Aug 28, 2022
1 parent 4543f5a commit 4ed1cbe
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion spyder/plugins/ipythonconsole/widgets/namespacebrowser.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,11 @@ def _handle_execute_reply(self, msg):
self.handle_exec_method(msg)
self._request_info['execute'].pop(msg_id)
else:
super(NamepaceBrowserWidget, self)._handle_execute_reply(msg)
# This catches an error when doing the teardown of a test.
try:
super(NamepaceBrowserWidget, self)._handle_execute_reply(msg)
except RuntimeError:
pass

def _handle_status(self, msg):
"""
Expand Down

0 comments on commit 4ed1cbe

Please sign in to comment.