镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

refactor(core): share credential redaction for diagnostics (carries #165) - #195

Merged
pierreraby merged 1 commit into
mainfrom
carry/pr165-shared-redactor
Nov 4, 2026
Merged

pierreraby merged 1 commit into
mainfrom
carry/pr165-shared-redactor

Conversation

@pierreraby

@pierreraby pierreraby commented Nov 4, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Carries #165's shared-redactor fix (8a2dc73) by @patlux / Patrick Wozniak, credited as co-author. Runtime source changes match the original commit; recalibrated on main after the other eight carries and the separate deterministic-abort test (#196).

  • Remove the narrower duplicate credential patterns in runtime diagnostics in favor of redactCommandCodeErrorText.
  • Preserve the prior URL query/fragment/userinfo removal before applying the shared redactor.
  • Add a preservation assertion for unknown query parameters and URL userinfo, in addition to the original synthetic secret regression.

This is defensive hardening, not a confirmed production leak. It does not import or depend on open diagnostics PR #180. That carry adds content-free diagnostics, not raw error text storage; retain both additions when integrating runtime/test changes.

Validation

  • Original synthetic-secret regression fails against main (standalone sk-shaped token is not removed).
  • Final head e7cd59e329df867f7ff19e6d713d052d60e503eb on main 590ef638c119539bc72718998d501a6872b608cf: full PI_LOCAL_REQUIRED=1 OMP_COMPAT_REQUIRED=1 npm test PASS, including the deterministic abort test and real Pi/OMP mock integration.
  • Final source range-diff against the original carry is identical (only changelog context adapted); all other integrated source and both RPC sequences are preserved.
  • Format and diff checks PASS.
  • Final active LSP probe of runtime and its test: no errors; two auxiliary hints on unchanged runtime code (unknown boundary parameter / large class).
  • The project typecheck excludes the full host entrypoint; the known 17 inherited expanded-probe diagnostics are not fixed here.

The original nine-carry independent review covered this unchanged source patch. The separate abort stabilization received a focused DeepSeek V4.1 Flash review and re-review (OK). No real secrets, live login, billed requests, packed-artifact smoke or release. #165 is currently closed non-merged; the maintainer has chosen to retain that status after integration and add the final carry summary there.

@github-actions

github-actions Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@github-actions

github-actions Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Memory benchmark

Compared base 590ef63 with PR head e7cd59e on the same GitHub-hosted darwin runner. Lower values are better.

Metric Base PR PR − Base Change
Stable RSS 107.9 MiB ± 0.2 MiB 107.0 MiB ± 0.4 MiB -0.6 MiB ± 0.6 MiB -0.5%
Physical footprint 61.2 MiB ± 0.8 MiB 61.1 MiB ± 0.2 MiB -0.3 MiB ± 0.6 MiB -0.4%
Physical peak 72.9 MiB ± 0.8 MiB 72.9 MiB ± 0.9 MiB -0.3 MiB ± 0.8 MiB -0.4%

Interpretation: Differences larger than their measured MAD: Stable RSS -0.6 MiB ± 0.6 MiB.

Extension overhead above pi baseline

Metric Base overhead PR overhead Difference
Stable RSS +7.0 MiB ± 0.1 MiB +6.2 MiB ± 1.0 MiB -0.6 MiB ± 0.6 MiB
Physical footprint +3.8 MiB ± 1.0 MiB +3.5 MiB ± 0.5 MiB -0.3 MiB ± 0.6 MiB
Physical peak +5.1 MiB ± 0.7 MiB +4.4 MiB ± 1.2 MiB -0.3 MiB ± 0.8 MiB

Values are medians of 6 alternating, paired runs. The value after ± is the median absolute deviation (MAD). Each process was sampled 12 times after a 2500 ms warm-up.

Environment: pi 0.84.4, Bun 1.4.4, darwin arm64. RSS comes from ps; physical footprint and peak come from macOS footprint.

This is a comparative signal, not a pass/fail threshold. GitHub-hosted runner noise can affect absolute values.

Carries #165 by patlux. Preserve URL query, fragment and userinfo stripping; add a preservation guard independent of the open diagnostics carry.

Co-authored-by: Patrick Wozniak <email@patwoz.de>
@pierreraby
pierreraby force-pushed the carry/pr165-shared-redactor branch from ffc4f9c to e7cd59e Compare November 4, 2026 14:03
@pierreraby
pierreraby merged commit 4a64c88 into main Nov 4, 2026
13 checks passed
@pierreraby
pierreraby deleted the carry/pr165-shared-redactor branch November 4, 2026 14:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant