more rigorous js impl

This commit is contained in:
Ty Dunn 2023-06-15 23:06:56 -07:00
parent 38cf45ed81
commit 0469a72530

View file

@ -343,7 +343,7 @@ def get_python_traceback(output: str) -> str:
return None
def get_javascript_traceback(output: str) -> str:
if "at " in output:
return output
else:
return None
lines = output.splitlines("\n")
first_line = lines[0].split(": ")
if len(lines) > 0 and len(first_line[0]) > 0 and "at" in lines[1].lstrip():
return output