We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a66f248 + 86a8b62 commit fb7c0ebCopy full SHA for fb7c0eb
1 file changed
teaagent/cli/_handlers/_mcp_trust.py
@@ -56,9 +56,16 @@ def _is_sensitive_key(key: Any) -> bool:
56
57
58
def _print_json(value: Any) -> None:
59
+ def _mask_leaf_values(obj: Any) -> Any:
60
+ if isinstance(obj, dict):
61
+ return {key: _mask_leaf_values(item) for key, item in obj.items()}
62
+ if isinstance(obj, list):
63
+ return [_mask_leaf_values(item) for item in obj]
64
+ return '[REDACTED]'
65
+
66
print(
67
json.dumps(
- _redact_sensitive(_strip_sensitive_fields(value)),
68
+ _mask_leaf_values(_redact_sensitive(_strip_sensitive_fields(value))),
69
ensure_ascii=False,
70
indent=2,
71
sort_keys=True,
0 commit comments