mirror of
https://github.com/3b1b/manim.git
synced 2025-09-01 00:48:45 +00:00
Use shell.showtraceback function
This commit is contained in:
parent
c1b52bf572
commit
8ff8f984d9
1 changed files with 1 additions and 1 deletions
|
@ -102,7 +102,7 @@ class InteractiveSceneEmbed:
|
|||
"""Flash border, and potentially play sound, on exceptions"""
|
||||
def custom_exc(shell, etype, evalue, tb, tb_offset=None):
|
||||
# Show the error don't just swallow it
|
||||
print(''.join(traceback.format_exception(etype, evalue, tb)))
|
||||
shell.showtraceback((etype, evalue, tb), tb_offset=tb_offset)
|
||||
rect = FullScreenRectangle().set_stroke(RED, 30).set_fill(opacity=0)
|
||||
rect.fix_in_frame()
|
||||
self.scene.play(VFadeInThenOut(rect, run_time=0.5))
|
||||
|
|
Loading…
Add table
Reference in a new issue