8000 tests/misc/sys_settrace_features.py: Ignore CPython zipimport traces. · mbtronics/micropython@e0bb7a5 · GitHub
[go: up one dir, main page]

Skip to content

Commit e0bb7a5

Browse files
committed
tests/misc/sys_settrace_features.py: Ignore CPython zipimport traces.
Signed-off-by: Damien George <damien@micropython.org>
1 parent f305c62 commit e0bb7a5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/misc/sys_settrace_features.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,8 @@ def trace_tick_handler_bob(frame, event, arg):
6060

6161
def trace_tick_handler(frame, event, arg):
6262
# Ignore CPython specific helpers.
63-
if frame.f_globals["__name__"].find("importlib") != -1:
63+
frame_name = frame.f_globals["__name__"]
64+
if frame_name.find("importlib") != -1 or frame_name.find("zipimport") != -1:
6465
return
6566

6667
print("### trace_handler::main event:", event)

0 commit comments

Comments
 (0)
0