Armin Ronacher: abolish Rust lock poisoning — nobody in the wild handles it correctly
Armin Ronacher · rss · 2026-11-25
Armin Ronacher argues Rust's mutex poisoning should be removed or made opt-in, as the libs team discusses defaulting to non-poisoning locks. Key points: PoisonError holds the guard, so error-wrapping patterns cause deadlocks (real bugs in cc-switch, ox-embed-server); one panic turns into permanent failure as thread pools and tokio tasks survive and every later lock().unwrap() panics (RLS, Mozilla services where PoisonError hit #5 in crash stats, Neon safekeeper, cargo/deno/polars/rustc test suites); intoinner() recovery re-triggers side effects since clearpoison only landed in 1.77; std itself ignores poisoning internally, as do tokio, wasmtime, and rust-analyzer. He also questions why RefCell doesn't poison while async code catches panics just as often, and proposes std::sync::nonpoison as default with an explicit Poison<T> opt-in wrapper.
More from coding & agent
- RL on workflows: probe first, 300 demos + RL lifted pass@1 from 0.17 to 0.40 — krishnan · 2026-11-25
- Two concrete cases of SFT'd LMs cheating on KernelBench — jiaxinwen22 · 2026-11-25
- Agent builds a 'Settings' app on Linux, fueling '2026: year of the Linux desktop' joke — GoddenThomas · 2026-11-25
- Wish-Based Development: Pipe User Feedback Straight Into an Engineering Agent Loop — yangyi · 2026-11-25
- Dreamfield world rendered as ASCII: one of 10 experimental styles built with Opus — mhmazur · 2026-11-25
- Three years in: chasing frontier model UIs isn't worth it — own your deployment — natesiggard · 2026-11-25