Skip to content

fix: match Anthropic tokens before generic sk pattern#64

Merged
CoderDeltaLAN merged 1 commit into
mainfrom
fix/redaction-pattern-order
Jun 16, 2026
Merged

fix: match Anthropic tokens before generic sk pattern#64
CoderDeltaLAN merged 1 commit into
mainfrom
fix/redaction-pattern-order

Conversation

@CoderDeltaLAN

Copy link
Copy Markdown
Owner

Summary

Fixes secret redaction pattern ordering so Anthropic-style sk-ant- keys match the specific anthropic_api_key pattern before the generic sk- pattern.

Also adds sk-ant- to diagnostic fixture secret marker guards and records the fix in the changelog.

Verification

  • Reproduced previous first match as openai_api_key.
  • Verified fixed first match as anthropic_api_key.
  • Ran targeted redaction and diagnostic fixture tests.
  • Ran full local check suite in a temporary dev environment.

Scope

Expected files only:

  • CHANGELOG.md
  • src/agent_rules_kit/redaction.py
  • tests/test_redaction.py
  • tests/test_diagnostic_fixtures.py

@CoderDeltaLAN CoderDeltaLAN merged commit d56b4ff into main Jun 16, 2026
1 check passed
@CoderDeltaLAN CoderDeltaLAN deleted the fix/redaction-pattern-order branch June 16, 2026 23:56
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