Skip to content

fix(live): no unjustified unwraps (57 -> 0) - #5166

Closed
joelteply wants to merge 2 commits into
canaryfrom
sonnet/no-unwraps-live
Closed

joelteply wants to merge 2 commits into
canaryfrom
sonnet/no-unwraps-live

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

live/: 57 unwrap/expect before, 0 unjustified after (baseline 2257 -> 2076, includes the shared scanner fix commit for file-level #![cfg(test)]).

  • 43 poisoned std Mutex/RwLock unwraps -> PoisonError::into_inner with same-line reason (bridge client, slot pool, avatar selection, bevy api, wgpu bridge)
  • 14 structural / typed: STT/TTS/avatar registries now return the OnceCell value from init_registry (no get-after-init expect); Silero from_shape_fn (no shape error possible); avatar selection if let Some(picked) = min_by_key (no is_empty+unwrap); render-loop and Bevy thread spawn failures are logged, release the slot / mark not-ready and return None; bridge envelope let-else Err; GLB frame_len from a 4-byte array; call_server test-pattern source returns Option when the call lock is busy; capture.rs returns .next(); Metal missing class returns the existing null-texture path; wgpu missing pipeline logs and skips the dispatch
    Tests: cargo test -p continuum-core --lib live:: = 398 passed, 9 ignored; source-hygiene unwrap_justification = pass, count 2076.

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 2 commits October 18, 2026 13:55
…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
live/: 57 unwrap/expect before, 0 unjustified after (baseline 2257 -> 2076, includes the shared scanner fix commit for file-level #![cfg(test)]).
- 43 poisoned std Mutex/RwLock unwraps -> PoisonError::into_inner with same-line reason (bridge client, slot pool, avatar selection, bevy api, wgpu bridge)
- 14 structural / typed: STT/TTS/avatar registries now return the OnceCell value from init_registry (no get-after-init expect); Silero from_shape_fn (no shape error possible); avatar selection `if let Some(picked) = min_by_key` (no is_empty+unwrap); render-loop and Bevy thread spawn failures are logged, release the slot / mark not-ready and return None; bridge envelope let-else Err; GLB frame_len from a 4-byte array; call_server test-pattern source returns Option when the call lock is busy; capture.rs returns .next(); Metal missing class returns the existing null-texture path; wgpu missing pipeline logs and skips the dispatch
Tests: cargo test -p continuum-core --lib live:: = 398 passed, 9 ignored; source-hygiene unwrap_justification = pass, count 2076.

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