Skip to content

Commit 4aec8ac

Browse files
authored
[refactor] Turn off stack traceback info by default (#5347)
When Taichi program crashes we used to show a `Taichi Compiler Stack Traceback` (a.k.a purple stack) but this stack doesn't have enough symbol for developers, nor it's readable to normal Taichi python users. So let's turn it off by default to avoid confusing users. Just in case someone still needs it, it can be brought back if you do `ti.init(debug=True)`.
1 parent 1540329 commit 4aec8ac

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

python/taichi/lang/misc.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -454,7 +454,7 @@ def init(arch=None,
454454

455455
impl._root_fb = _snode.FieldsBuilder()
456456

457-
if not os.environ.get("TI_DISABLE_SIGNAL_HANDLERS", False):
457+
if cfg.debug:
458458
impl.get_runtime()._register_signal_handlers()
459459

460460
# Recover the current working directory (https://github.com/taichi-dev/taichi/issues/4811)

0 commit comments

Comments
 (0)