From 155721d33b3e003e30f2b650c8635e2ae43d3e76 Mon Sep 17 00:00:00 2001 From: Tim Savage Date: Wed, 27 Nov 2024 12:31:12 +1100 Subject: [PATCH] Apply sensitive filter when dumping flow trace --- src/pyapp_flow/datastructures.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/pyapp_flow/datastructures.py b/src/pyapp_flow/datastructures.py index 997ef2d..ee324b6 100644 --- a/src/pyapp_flow/datastructures.py +++ b/src/pyapp_flow/datastructures.py @@ -16,6 +16,8 @@ Iterable, ) +from .helpers import mask_keys + Branches = Dict[str, Sequence["Navigable"]] TRACE_STATE_KEY: Final[str] = "__trace" @@ -59,7 +61,7 @@ def __rich__(self): """Rich repr of state.""" from rich.scope import render_scope - return render_scope(self, title="State Variables", sort_keys=True) + return render_scope(mask_keys(self), title="State Variables", sort_keys=True) def copy(self) -> "State": """Copy and return a state instance."""