traceredact 0.2.0__tar.gz → 0.2.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {traceredact-0.2.0 → traceredact-0.2.2}/CHANGELOG.md +15 -1
- {traceredact-0.2.0 → traceredact-0.2.2}/PKG-INFO +18 -8
- {traceredact-0.2.0 → traceredact-0.2.2}/README.md +13 -6
- {traceredact-0.2.0 → traceredact-0.2.2}/pyproject.toml +5 -2
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/test_extras.py +5 -5
- {traceredact-0.2.0 → traceredact-0.2.2}/.github/ISSUE_TEMPLATE/bug_report.yml +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/.github/ISSUE_TEMPLATE/config.yml +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/.github/ISSUE_TEMPLATE/feature_request.yml +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/.github/pull_request_template.md +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/.github/workflows/ci.yml +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/.github/workflows/release.yml +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/.gitignore +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/CONTRIBUTING.md +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/LICENSE +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/SECURITY.md +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/assets/icon.png +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/assets/icon.svg +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/assets/logo.png +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/assets/logo.svg +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/assets/social-preview.png +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/assets/social-preview.svg +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/__init__.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/cli.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/detectors/__init__.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/detectors/base.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/detectors/pii.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/detectors/secrets.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/engine.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/integrations/__init__.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/integrations/anthropic.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/integrations/langchain.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/integrations/openai.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/policy.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/py.typed +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/rules.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/src/traceredact/streaming.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/fixtures/agent_trace.json +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/fixtures/evasion_trace.json +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/fixtures/prompt.txt +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/test_cli.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/test_detectors.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/test_engine.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/test_evasion.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/test_fixtures.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/test_integrations.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/test_policy.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/tests/test_streaming.py +0 -0
- {traceredact-0.2.0 → traceredact-0.2.2}/traceredact.yml +0 -0
|
@@ -6,6 +6,18 @@ All notable changes to this project are documented here. The format is based on
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.2.2] — 2026-06-07
|
|
10
|
+
|
|
11
|
+
### Changed
|
|
12
|
+
- Project homepage is now https://traceredact.com; README shows the project
|
|
13
|
+
banner and a website link. Docs/metadata only — no code changes.
|
|
14
|
+
|
|
15
|
+
## [0.2.1] — 2026-06-07
|
|
16
|
+
|
|
17
|
+
### Changed
|
|
18
|
+
- Internal: tidied test-comment wording and commit history. No functional or
|
|
19
|
+
API changes — behaviourally identical to 0.2.0 (which is superseded).
|
|
20
|
+
|
|
9
21
|
## [0.2.0] — 2026-06-07
|
|
10
22
|
|
|
11
23
|
### Added
|
|
@@ -68,7 +80,9 @@ Initial release.
|
|
|
68
80
|
- Policy file (`traceredact.yml`): detector toggles, entropy thresholds,
|
|
69
81
|
allowlist, custom patterns, placeholder template, optional HMAC correlation.
|
|
70
82
|
|
|
71
|
-
[Unreleased]: https://github.com/traceredact/traceredact/compare/v0.2.
|
|
83
|
+
[Unreleased]: https://github.com/traceredact/traceredact/compare/v0.2.2...HEAD
|
|
84
|
+
[0.2.2]: https://github.com/traceredact/traceredact/compare/v0.2.1...v0.2.2
|
|
85
|
+
[0.2.1]: https://github.com/traceredact/traceredact/compare/v0.2.0...v0.2.1
|
|
72
86
|
[0.2.0]: https://github.com/traceredact/traceredact/compare/v0.1.3...v0.2.0
|
|
73
87
|
[0.1.3]: https://github.com/traceredact/traceredact/compare/v0.1.2...v0.1.3
|
|
74
88
|
[0.1.2]: https://github.com/traceredact/traceredact/compare/v0.1.1...v0.1.2
|
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: traceredact
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.2
|
|
4
4
|
Summary: Redact PII and secrets from AI prompts, traces and tool-call arguments before they reach your loggers.
|
|
5
|
-
Project-URL: Homepage, https://
|
|
5
|
+
Project-URL: Homepage, https://traceredact.com
|
|
6
|
+
Project-URL: Documentation, https://traceredact.com
|
|
7
|
+
Project-URL: Repository, https://github.com/traceredact/traceredact
|
|
6
8
|
Project-URL: Issues, https://github.com/traceredact/traceredact/issues
|
|
9
|
+
Project-URL: Changelog, https://github.com/traceredact/traceredact/blob/main/CHANGELOG.md
|
|
7
10
|
Author: traceredact contributors
|
|
8
11
|
License: Apache-2.0
|
|
9
12
|
License-File: LICENSE
|
|
@@ -32,15 +35,22 @@ Provides-Extra: openai
|
|
|
32
35
|
Requires-Dist: openai>=1.0; extra == 'openai'
|
|
33
36
|
Description-Content-Type: text/markdown
|
|
34
37
|
|
|
35
|
-
|
|
38
|
+
<p align="center">
|
|
39
|
+
<a href="https://traceredact.com"><img src="https://traceredact.com/social-preview.png" alt="traceredact" width="640"></a>
|
|
40
|
+
</p>
|
|
41
|
+
|
|
42
|
+
<p align="center">
|
|
43
|
+
<a href="https://pypi.org/project/traceredact/"><img src="https://img.shields.io/pypi/v/traceredact.svg?cache=3" alt="PyPI"></a>
|
|
44
|
+
<a href="https://pypi.org/project/traceredact/"><img src="https://img.shields.io/pypi/pyversions/traceredact.svg?cache=3" alt="Python"></a>
|
|
45
|
+
<a href="https://github.com/traceredact/traceredact/actions/workflows/ci.yml"><img src="https://github.com/traceredact/traceredact/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
|
|
46
|
+
<a href="./LICENSE"><img src="https://img.shields.io/badge/License-Apache_2.0-blue.svg" alt="License: Apache-2.0"></a>
|
|
47
|
+
<a href="https://traceredact.com"><img src="https://img.shields.io/badge/website-traceredact.com-7c83ff" alt="Website"></a>
|
|
48
|
+
</p>
|
|
36
49
|
|
|
37
|
-
|
|
38
|
-
[](https://pypi.org/project/traceredact/)
|
|
39
|
-
[](https://github.com/traceredact/traceredact/actions/workflows/ci.yml)
|
|
40
|
-
[](./LICENSE)
|
|
50
|
+
# traceredact
|
|
41
51
|
|
|
42
52
|
**Redact PII and secrets from AI prompts, agent traces and tool-call arguments
|
|
43
|
-
*before* they reach your loggers / observability backend.**
|
|
53
|
+
*before* they reach your loggers / observability backend.** — [traceredact.com](https://traceredact.com)
|
|
44
54
|
|
|
45
55
|
LLM apps log everything — prompts, agent traces, tool-call arguments — into
|
|
46
56
|
Langfuse / Helicone / Datadog / your own DB. Customer PII and API keys leak into
|
|
@@ -1,12 +1,19 @@
|
|
|
1
|
-
|
|
1
|
+
<p align="center">
|
|
2
|
+
<a href="https://traceredact.com"><img src="https://traceredact.com/social-preview.png" alt="traceredact" width="640"></a>
|
|
3
|
+
</p>
|
|
4
|
+
|
|
5
|
+
<p align="center">
|
|
6
|
+
<a href="https://pypi.org/project/traceredact/"><img src="https://img.shields.io/pypi/v/traceredact.svg?cache=3" alt="PyPI"></a>
|
|
7
|
+
<a href="https://pypi.org/project/traceredact/"><img src="https://img.shields.io/pypi/pyversions/traceredact.svg?cache=3" alt="Python"></a>
|
|
8
|
+
<a href="https://github.com/traceredact/traceredact/actions/workflows/ci.yml"><img src="https://github.com/traceredact/traceredact/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
|
|
9
|
+
<a href="./LICENSE"><img src="https://img.shields.io/badge/License-Apache_2.0-blue.svg" alt="License: Apache-2.0"></a>
|
|
10
|
+
<a href="https://traceredact.com"><img src="https://img.shields.io/badge/website-traceredact.com-7c83ff" alt="Website"></a>
|
|
11
|
+
</p>
|
|
2
12
|
|
|
3
|
-
|
|
4
|
-
[](https://pypi.org/project/traceredact/)
|
|
5
|
-
[](https://github.com/traceredact/traceredact/actions/workflows/ci.yml)
|
|
6
|
-
[](./LICENSE)
|
|
13
|
+
# traceredact
|
|
7
14
|
|
|
8
15
|
**Redact PII and secrets from AI prompts, agent traces and tool-call arguments
|
|
9
|
-
*before* they reach your loggers / observability backend.**
|
|
16
|
+
*before* they reach your loggers / observability backend.** — [traceredact.com](https://traceredact.com)
|
|
10
17
|
|
|
11
18
|
LLM apps log everything — prompts, agent traces, tool-call arguments — into
|
|
12
19
|
Langfuse / Helicone / Datadog / your own DB. Customer PII and API keys leak into
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "traceredact"
|
|
3
|
-
version = "0.2.
|
|
3
|
+
version = "0.2.2"
|
|
4
4
|
description = "Redact PII and secrets from AI prompts, traces and tool-call arguments before they reach your loggers."
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
requires-python = ">=3.11"
|
|
@@ -36,8 +36,11 @@ langchain = ["langchain-core>=0.2"]
|
|
|
36
36
|
traceredact = "traceredact.cli:app"
|
|
37
37
|
|
|
38
38
|
[project.urls]
|
|
39
|
-
Homepage = "https://
|
|
39
|
+
Homepage = "https://traceredact.com"
|
|
40
|
+
Documentation = "https://traceredact.com"
|
|
41
|
+
Repository = "https://github.com/traceredact/traceredact"
|
|
40
42
|
Issues = "https://github.com/traceredact/traceredact/issues"
|
|
43
|
+
Changelog = "https://github.com/traceredact/traceredact/blob/main/CHANGELOG.md"
|
|
41
44
|
|
|
42
45
|
[build-system]
|
|
43
46
|
requires = ["hatchling"]
|
|
@@ -86,21 +86,21 @@ def _decode_policy() -> Policy:
|
|
|
86
86
|
|
|
87
87
|
|
|
88
88
|
def test_decode_pass_short_encoded_assignment() -> None:
|
|
89
|
-
#
|
|
89
|
+
# Regression: base64("api_key=abcdef") is short (<24 chars) but real.
|
|
90
90
|
blob = base64.b64encode(b"api_key=abcdef").decode()
|
|
91
91
|
assert blob not in redact(f"x {blob} y", _decode_policy()).value
|
|
92
92
|
|
|
93
93
|
|
|
94
94
|
def test_decode_pass_leading_junk_char() -> None:
|
|
95
|
-
#
|
|
95
|
+
# Regression: "A" + base64(secret) must still be caught at the right offset.
|
|
96
96
|
blob = base64.b64encode(b"OPENAI_API_KEY=sk-1234567890abcdefABCDEFGH").decode()
|
|
97
97
|
out = redact("A" + blob, _decode_policy()).value
|
|
98
98
|
assert blob not in out
|
|
99
99
|
|
|
100
100
|
|
|
101
101
|
def test_decode_pass_survives_decoy_blobs() -> None:
|
|
102
|
-
#
|
|
103
|
-
# the budget
|
|
102
|
+
# Regression: many benign decodable blobs before the secret must not exhaust
|
|
103
|
+
# the candidate budget.
|
|
104
104
|
decoys = " ".join(
|
|
105
105
|
base64.b64encode(f"benign text {i:02d} nothing here".encode()).decode()
|
|
106
106
|
for i in range(20)
|
|
@@ -111,7 +111,7 @@ def test_decode_pass_survives_decoy_blobs() -> None:
|
|
|
111
111
|
|
|
112
112
|
|
|
113
113
|
def test_streaming_honours_decode_payloads() -> None:
|
|
114
|
-
#
|
|
114
|
+
# Regression: decode pass must run in streaming, not only at flush.
|
|
115
115
|
from traceredact import redact_stream
|
|
116
116
|
|
|
117
117
|
blob = base64.b64encode(
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|