Skip to content

android: make HealthNotifier init-order test catch the NPE - #889

Draft
kradalby wants to merge 1 commit into
mainfrom
kradalby/healthnotifier-npe
Draft

kradalby wants to merge 1 commit into
mainfrom
kradalby/healthnotifier-npe

Conversation

@kradalby

@kradalby kradalby commented Sep 30, 2026 •

Copy link
Copy Markdown
Member

headscale's Android emulator integration tests (juanfont/headscale#3488)
hit this NPE on 1.102.4, which predates the #835 fix. Reproducing it
here showed constructionWithNonRunningStateDoesNotCrash (#835) still
passes with currentWarnings declared after init again. The NPE is
thrown in a launched coroutine with no handler, so it goes to the
thread's uncaught handler, which only prints on the JVM (on Android it
kills the process). Capture it via CoroutineExceptionHandler and
rethrow.

Updates tailscale/corp#46191

headscale's Android emulator integration tests (juanfont/headscale#3488)
hit this NPE on 1.102.4, which predates the #835 fix. Reproducing it
here showed constructionWithNonRunningStateDoesNotCrash (#835) still
passes with currentWarnings declared after init again. The NPE is
thrown in a launched coroutine with no handler, so it goes to the
thread's uncaught handler, which only prints on the JVM (on Android it
kills the process). Capture it via CoroutineExceptionHandler and
rethrow.

Updates tailscale/corp#46191

Signed-off-by: Kristoffer Dalby <kristoffer@dalby.cc>
@kradalby
kradalby force-pushed the kradalby/healthnotifier-npe branch from 7d76096 to da5669e Compare September 30, 2026 14:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants