Keep release credentials and package contents out of logs
A registry error included an authorization header in a debug dump. Add structured diagnostics with an allowlist of safe release fields and a useful correlation ID.
- Focused work estimate
- 1h 30m + prerequisites
- Priority in the scenario
- High
- Engineering practice
- Structured logging · Secret handling · Error design
Estimated field mix
- Developer tooling50%
- Security50%
Field percentages are editorial estimates of the ticket's engineering focus. They total 100%; they are not measured time, proficiency scores, or ownership evidence.
Review it, then add it to your workspace.
The board opens an editable draft; nothing is saved until you confirm it. Sign-in and workspace permissions apply, and Demo boards remain ephemeral.
Project context
A team maintains six related packages. Release notes, version changes, and tags are copied between a spreadsheet and a terminal; a failed upload recently left two packages ahead of their dependents. The exercise uses temporary repositories and a fake registry.
Setup prerequisites
- Create a temporary Git repository with three related fixture packages.
- Use a local registry double; no publishing credentials are required.
Preceding work
Complete these dependencies, or supply their agreed outputs before taking this ticket.
- CLI-101 · Print package versions without depending on the current directory
- CLI-102 · Give scripts a stable JSON output contract
- CLI-103 · Include dependent packages in the proposed version bump
- CLI-104 · Make a dirty checkout a deliberate release decision
- CLI-105 · Turn change fragments into package-specific release notes
- CLI-106 · Prepare manifests and notes as one recoverable file operation
- CLI-107 · Prevent a second release process from using the same checkout
- CLI-108 · Resume a publish rehearsal after the registry response disappears
Acceptance criteria
- Diagnostics include operation ID, package name, step, duration, and error category.
- Headers, environment variables, artifact contents, and token-like fixture values are absent from all log levels.
- Human and JSON errors reference the same operation ID.
Implementation constraints
- Map provider failures to safe errors at the adapter boundary.
- Do not rely only on replacing known secret strings.
Verification to include
- Cause a fake provider error containing a token and scan stdout, stderr, and persisted diagnostics.
- Confirm a safe package conflict still carries enough information to locate the failed step.
Deliverables
- Safe error mapper and redaction regression cases
Rollout and recovery
Make safe diagnostics the default; temporarily reduce diagnostic detail if an unknown provider error cannot be classified.
Value of the work
For the engineer: Practice CLI contracts, graph reasoning, filesystem safety, and recovery from partial work.
For the team: Review how an engineer makes release changes inspectable and recoverable before they affect consumers.
Evidence boundaries
Outcome Evidence: Tests, patches, and runbooks are requested deliverables. They become Outcome Evidence only through a qualified Mission and immutable Evidence IDs.
Ownership Evidence: Independent adaptation must be observed under a declared verification policy and cite immutable Evidence IDs. Completing a planning ticket establishes no Ownership Evidence.