From 3345b6453e8b8588988ff11e09b268d2b7d76a7e Mon Sep 17 00:00:00 2001 From: Karim Jerbi Date: Tue, 29 Sep 2026 05:24:13 +0100 Subject: [PATCH] fix(background): keep the app alive when a background worker panics Bug: background_task joined the worker thread with .expect(...). Any panic inside a background closure (decoding a malformed file, an unexpected None) was re-raised on the main thread and took the whole application down, even though the worker's failure was already contained. Reproduce: 1. Run an operation that executes in a background worker, e.g. loading or converting a deliberately corrupted file whose decoder panics. 2. Before: the process dies with the worker's panic message. 3. After: the command line shows "background task failed: