MCPcopy
hub / github.com/pyodide/pyodide / normalize_tb

Function normalize_tb

src/tests/test_pyodide.py:1167–1180  ·  view source on GitHub ↗
(t)

Source from the content-addressed store, hash-verified

1165 )
1166
1167 def normalize_tb(t):
1168 res = []
1169 for [file, name] in t:
1170 if file.endswith((".js", ".html", ".mjs")):
1171 file = file.rpartition("/")[-1]
1172 if file.endswith(".py"):
1173 file = "/".join(file.split("/")[-2:])
1174 if re.fullmatch(r"\:[0-9]*", file) or file in {
1175 "debugger eval code",
1176 "evalmachine.<anonymous>",
1177 }:
1178 file = "module_test.html"
1179 res.append([file, name])
1180 return res
1181
1182 frames = [
1183 ["<exec>", "e"],

Callers 1

test_js_stackframesFunction · 0.85

Calls 2

joinMethod · 0.80
appendMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…