fix(android): handle rejected foreground service starts - #257
Conversation
Git-Session-Id: 56a0524d-5875-5322-964b-a4d6e1967011
🤖 AI code reviewSafe to merge — no P0/P1 findingsConfidence 5/5 ✅ No findings. The diff looks correct to me on this pass. Reviewed Maintainer commands
|
|
|
All 5 required checks now pass, and Greptile reviewed the current head at 5/5 with no findings. This account has pull-only access, so I cannot merge or formally request a reviewer. Ready for maintainer review/merge; physical API 34/36 boot and background-recreation verification remains the release-device gate. |
|
CI-green and mergeable (Greptile 5/5) — waiting only on a maintainer click. This PR is ready to merge, but the bot has pull-only access to this repo and can't self-merge — surfacing it here so it isn't lost. The monitoring loop will stop re-flagging it now that this note is posted. |
What changed
ForegroundServiceStartNotAllowedExceptionat both Android rejection boundaries: boot-timestartForegroundService()and in-servicestartForeground()BackgroundServicebefore Rust/server/scheduler initialization when foreground promotion is deniedSTART_STICKYtoSTART_NOT_STICKY, avoiding illegal background recreation loopsactivity,boot,settings, orsystem-restartin lifecycle logsVerification
Local AI review: 5/5, no open findings.
Physical API 34/36 boot and background-recreation verification remains a release/device gate; no Android device is attached to this build host. The code now fails closed instead of crashing on either platform rejection path.
Fixes #255.