fix(cuprate): catch launch panics and give the thread 8 MiB stack #127

Merged
sirius merged 1 commit from onionwire/cuprate-launch-panic into main 2026-09-19 19:47:41 +00:00
Owner

The error the launch thread died before answering means the Cuprate thread panicked (or was killed) before sending a result. On Android that is usually a ~1 MiB stack overflow in RandomX/consensus.

  • 8 MiB stack on the launch thread and tokio workers
  • catch_unwind so a Rust panic becomes cuprate panicked: … instead of the dead-channel string
The error **the launch thread died before answering** means the Cuprate thread panicked (or was killed) before sending a result. On Android that is usually a ~1 MiB stack overflow in RandomX/consensus. - 8 MiB stack on the launch thread and tokio workers - `catch_unwind` so a Rust panic becomes `cuprate panicked: …` instead of the dead-channel string
fix(cuprate): catch launch panics and give the thread 8 MiB stack
All checks were successful
ci / test (pull_request) Successful in 5m25s
ci / sdk (pull_request) Successful in 1m12s
android-ci / android (pull_request) Successful in 10m50s
ci / fuzz (pull_request) Successful in 4m59s
a7daf2c768
Android's default pthread stack is ~1 MiB. Cuprate+RandomX overflow it,
the launch thread dies before tx.send, and the UI only says "the launch
thread died before answering". Catch unwind so a Rust panic is the error
string, and size the launch thread plus tokio workers at 8 MiB.
sirius merged commit fb87903137 into main 2026-09-19 19:47:41 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
sirius/onionwire!127
No description provided.