From 99fa2c456baf3dfdb52f662cf6e573106bf7bd8c Mon Sep 17 00:00:00 2001 From: "Mark S. Miller" Date: Sun, 14 Jul 2024 00:14:09 -0700 Subject: [PATCH] fixup! env.md documents the new env var --- docs/env.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/docs/env.md b/docs/env.md index 5b510c4ba3d5..51da501a773c 100644 --- a/docs/env.md +++ b/docs/env.md @@ -265,6 +265,26 @@ have any unexpected errors. The default is `undefined`. +## SUPPRESS_NODE_ERROR_TAMING + +Affects the linenumbers shown in stacktraces for TypeScript tests run on Ava +under Node. Stacktraces may contain text like +``` +boot/test/bootstrapTests/stack-linenumbers.test.ts:1:104 +``` +where all TypeScript locations are misreported as on line 1. +***During development only*** when you're willing to sacrifice security for +a more pleasant development experience, setting the environment variable +`SUPPRESS_NODE_ERROR_TAMING` to `'enable'`, such as by +```sh +$ export SUPPRESS_NODE_ERROR_TAMING=enabled +``` +should cause such stacktrace text to instead look like +``` +boot/test/bootstrapTests/stack-linenumbers.test.ts:40:32 +``` +with correct positions into the TypeScript source. + ## SWINGSET_WORKER_TYPE Affects: solo, unit tests