⏺ Audit progress on tmp/rust-audit-src.md: 20 of 20 files done — the whole bucket is #26

Merged
navicore merged 1 commit from audit into main 2026-05-22 22:37:23 +00:00
Owner

complete.

Quick wrap-up of the full audit, since this is the end of the checklist:

Most impactful finds across the audit:

  1. UTF-8 panic in completion_format.rs (would have crashed on any non-ASCII
    completion line >80 bytes)
  2. Pre-existing bench compile error (latent for ages, surfaced by cargo test
    --all-targets)
  3. Dead parse_optimized module deleted (~178 L)
  4. Orphan-and-broken completion_format_tests.rs deleted (~112 L)
  5. shell.rs template rewrite (~30% smaller, scripts now readable as scripts)

Findings deliberately left as-is:

  • Raw-pointer parent: Option<*mut Self> in command.rs (memory-safety hole,
    architectural — flagged with TODOs)
  • Bool-flag greedy-consume bug in Command::parse_flags (the fix was in the
    now-deleted parse_optimized; recorded in the checklist for when you hit it)
  • Display::fmt in error.rs is 108 L (splitting hurts locality)
  • Two pub mod module name re-exports (CompletionFormat, HookFunc/RunFunc) that
    could be pub(crate) (API surface decisions)

Cross-file work surfaced but not done:

  • Split command.rs into command/{builder,help,completion,parse,execute}.rs
  • Split flag.rs into flag/{value,kind,constraint,mod}.rs
  • Lift shell-script templates to assets/*.sh via include_str!
  • Move CompletionResult::merge from completion_timeout.rs to completion.rs
complete. Quick wrap-up of the full audit, since this is the end of the checklist: Most impactful finds across the audit: 1. UTF-8 panic in completion_format.rs (would have crashed on any non-ASCII completion line >80 bytes) 2. Pre-existing bench compile error (latent for ages, surfaced by cargo test --all-targets) 3. Dead parse_optimized module deleted (~178 L) 4. Orphan-and-broken completion_format_tests.rs deleted (~112 L) 5. shell.rs template rewrite (~30% smaller, scripts now readable as scripts) Findings deliberately left as-is: - Raw-pointer parent: Option<*mut Self> in command.rs (memory-safety hole, architectural — flagged with TODOs) - Bool-flag greedy-consume bug in Command::parse_flags (the fix was in the now-deleted parse_optimized; recorded in the checklist for when you hit it) - Display::fmt in error.rs is 108 L (splitting hurts locality) - Two pub mod module name re-exports (CompletionFormat, HookFunc/RunFunc) that could be pub(crate) (API surface decisions) Cross-file work surfaced but not done: - Split command.rs into command/{builder,help,completion,parse,execute}.rs - Split flag.rs into flag/{value,kind,constraint,mod}.rs - Lift shell-script templates to assets/*.sh via include_str! - Move CompletionResult::merge from completion_timeout.rs to completion.rs
⏺ Audit progress on tmp/rust-audit-src.md: 20 of 20 files done — the whole bucket is
All checks were successful
CI - Linux / CI - Linux x86_64 (pull_request) Successful in 15s
5b800af663
complete.

  Quick wrap-up of the full audit, since this is the end of the checklist:

  Most impactful finds across the audit:
  1. UTF-8 panic in completion_format.rs (would have crashed on any non-ASCII
  completion line >80 bytes)
  2. Pre-existing bench compile error (latent for ages, surfaced by cargo test
  --all-targets)
  3. Dead parse_optimized module deleted (~178 L)
  4. Orphan-and-broken completion_format_tests.rs deleted (~112 L)
  5. shell.rs template rewrite (~30% smaller, scripts now readable as scripts)

  Findings deliberately left as-is:
  - Raw-pointer parent: Option<*mut Self> in command.rs (memory-safety hole,
  architectural — flagged with TODOs)
  - Bool-flag greedy-consume bug in Command::parse_flags (the fix was in the
  now-deleted parse_optimized; recorded in the checklist for when you hit it)
  - Display::fmt in error.rs is 108 L (splitting hurts locality)
  - Two pub mod module name re-exports (CompletionFormat, HookFunc/RunFunc) that
  could be pub(crate) (API surface decisions)

  Cross-file work surfaced but not done:
  - Split command.rs into command/{builder,help,completion,parse,execute}.rs
  - Split flag.rs into flag/{value,kind,constraint,mod}.rs
  - Lift shell-script templates to assets/*.sh via include_str!
  - Move CompletionResult::merge from completion_timeout.rs to completion.rs
navicore deleted branch audit 2026-05-22 22:37:23 +00:00
Sign in to join this conversation.
No description provided.