Skip to content

fix(capacity,governor,tool_parsing,bin): no unjustified unwraps (91 -> 0) - #5171

Closed
joelteply wants to merge 6 commits into
canaryfrom
sonnet/no-unwraps-rest
Closed

joelteply wants to merge 6 commits into
canaryfrom
sonnet/no-unwraps-rest

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

One build cycle for the remaining directories, one commit per directory (capacity 16, governor 15, tool_parsing 36, bin 24 = 91 unwrap/expect before, 0 unjustified after). Ratchet: 2257 -> 2045 (includes the shared scanner commit).

  • capacity: expert-container header via first_chunk (typed RecordIdentity error if short), bank slot via Option::insert, total_cmp instead of partial_cmp.expect, poison recovery; test-fixture module justified in place
  • governor: 15 poisoned-mutex expects -> PoisonError::into_inner with reason
  • tool_parsing: one static_regex() helper owns the constant-pattern compile (one stated reason instead of ~25); capture groups via let-else continue; param correction no longer remove().unwrap()
  • bin: expert_observe/vrm_* tools return Result from main; continuum plan_launch and forge_custodian pipes use let-else/typed errors
    Tests: lib capacity::+governor::+tool_parsing:: = 545 passed. bin continuum tests: 3 fail (prebuilt_reboot_options_are_explicit_and_strict says "scheduled task deployment is Windows-only"; the other two are launch-env tests) - platform/environment, not in the touched code paths; not run against canary to confirm. source-hygiene = pass, 2045.

Behavior change: panics become typed, handled outcomes. Needs a real review, not only CI.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo

joelteply and others added 6 commits October 18, 2026 15:09
…duction

The unwrap scanner split only on the outer #[cfg(test)], so files whose first
code line is #![cfg(test)] (orm/derive_test.rs, contracts/chain_tests.rs) were
counted as production unwraps. Match the inner attribute too.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
@joelteply

Copy link
Copy Markdown
Contributor Author

Folded into #5172 (one branch, one CI run). The review and test receipts are there.

@joelteply joelteply closed this Oct 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant