Don't update currentFrame when in a breakpoint or exception. Otherwise unpredictable frames could be shown. maintenance

Sun, 05 Mar 2017 16:16:46 +0100

author
T.Rzepka <Tobias.Rzepka@gmail.com>
date
Sun, 05 Mar 2017 16:16:46 +0100
branch
maintenance
changeset 5591
ac539bb30eb1
parent 5578
3f0234901b2f
child 5592
1b635de76083

Don't update currentFrame when in a breakpoint or exception. Otherwise unpredictable frames could be shown.
(grafted from f8abf5f741efd7e7ee364fa6ea7b2df27ded8d9e)

DebugClients/Python/ThreadExtension.py file | annotate | diff | comparison | revisions
--- a/DebugClients/Python/ThreadExtension.py	Fri Mar 03 18:43:06 2017 +0100
+++ b/DebugClients/Python/ThreadExtension.py	Sun Mar 05 16:16:46 2017 +0100
@@ -203,8 +203,8 @@
         while frame is not None:
             baseName = os.path.basename(frame.f_code.co_filename)
             if not baseName.startswith(
-                    ('DebugClientBase.py', 'DebugBase.py', 'AsyncIO.py',
-                     'ThreadExtension.py', 'threading.py')):
+                    ('DebugClientBase.py', 'DebugBase.py', 'AsyncFile.py',
+                     'ThreadExtension.py')):
                 break
             frame = frame.f_back
         
@@ -234,7 +234,8 @@
             if "__pypy__" not in sys.builtin_module_names:
                 # Don't update with None
                 currentFrame = self.getExecutedFrame(frame)
-                if currentFrame is not None:
+                if (currentFrame is not None and
+                        self.threads[id].isBroken is False):
                     self.threads[id].currentFrame = currentFrame
         
         # Clean up obsolet because terminated threads

eric ide

mercurial