fix(responses): redact tracing data - #942
Conversation
Review:
|
🧭 IronLoop Run · ReviewThis comment updates in place as the Run moves through its stages. 🟩 Final result · Completed
Automatic trigger · attempt 1 of 3 · completed in 54s IronLoop completed the review and posted it to GitHub. 🔗 Result |
There was a problem hiding this comment.
🔍 IronLoop review
🟢 No actionable findings
No additional findings beyond the issues already raised in the captured review feedback.
Validation
- ✅ Static review — Inspected every changed area for correctness, privacy, error handling, and observability; no distinct additional defect was found.
- ✅ Patch integrity — The change contains no whitespace or conflict-marker errors.
Review details
- Run:
d4d4f415-000a-4474-b457-d274206765b0 - Workflow: Review
- Attempts: 1
655cc5c to
fbd1060
Compare
|
Addressed the privacy review feedback in fbd1060: Responses tracing coverage now recursively scans the implementation tree and safely handles raw strings/comments; input-file retrieval failures return a stable client-safe error; and attestation/operational failures retain only permitted IDs and stable categories. Validation is included in the latest commit. |
fbd1060 to
60dac34
Compare
|
@ironloopai review |
|
@claude review |
Review · Status🟩 CompletedIronLoop completed the review and posted it to GitHub. ResultRun detailsManual command by think-in-universe · attempt 1 of 3 · completed in 9m 16s |
There was a problem hiding this comment.
Review · Summary
Found two gaps in the new tracing privacy regression guard; the changed production tracing calls otherwise use safe operational metadata.
Findings: 🟠 Medium 2
Code-specific findings are attached to the diff.
Validation
- ✅ Tracing redaction inspection — Changed production tracing calls were statically verified to use IDs, model IDs, status metadata, counts, and stable error categories instead of raw content, digests, tool data, or rendered errors.
Review details
- Run:
c87ceda4-68c9-43be-a289-16ca6233097d - Attempts: 1
|
Review: Re-reviewed at
Also confirmed fixed: Two new findings, then unresolved carry-overs. 🔴 The guard still misses the
tracing::warn!("Failed to store failed response item: {}", create_err); // green
tracing::warn!("Failed to update response status: {update_err}"); // green
tracing::error!("Provider call failed: {cause}"); // greenFor Since the invariant these files now hold is "structured fields only, no rendered error values", inverting the rule is both simpler and closed:
🟠 New in this diff, status = error_cause.http_status_code(), // :807 -> u16 (HTTP status)
status = e.http_status_code(), // :1302 -> u16 (HTTP status)
status = "failed", // :1251, :1418, :1439 -> &str (persisted response status)Meanwhile 🟠 Carry-over: 5xx triage is still mostly a single bucket
.map_err(|_| {
tracing::error!(error_category = "image_edit_provider_failure", "Image edit request failed");
…
})a prod 5xx yields 🟠 Carry-over: MCP logs are now content-free
Notes
|
|
Follow-up on the current review: 3e648b6 tightens the source-level Responses tracing guard so all field forms are fail-closed, all standard span macros and Rust macro delimiters are inspected, and regressions cover the previously unguarded aliases/syntax. It also separates numeric HTTP |
Summary
tracing, including rendered errors, request/response digests, response deltas, tool arguments, tool/MCP names and labels, and available-tool setsAPI impact
input_filefetch failureCompatibility boundary
This is primarily a logging/privacy change. Apart from the intentionally sanitized legacy
input_filefailure message above, it does not alter external API routing, successful response behavior, response persistence/history policy, or attestation/signature retention and access policy.Request and response digests are content-derived sensitive metadata and must not enter
tracing. Existing attestation records remain separate from application logs and contain digest/signature material rather than raw request or response content.Validation
cargo fmt --all -- --checkgit diff --checkcargo test -p api --test response_logging_privacy(2 passed)cargo test -p services citation_tracker --lib(13 passed)Closes #938
Part of #934