Skip to content

feat(native): push notifications on iOS - #483

Merged
Makisuo merged 9 commits into
push/1-backendfrom
push/2-ios
Nov 14, 2026
Merged

Makisuo merged 9 commits into
push/1-backendfrom
push/2-ios

Merge remote-tracking branch 'origin/push/1-backend' into push/2-ios

a321904
Select commit
Loading
Failed to load commit list.
Maple Review Bot / Maple / review succeeded Nov 14, 2026 in 4m 2s

Confidence 8/10 · No issues found

🟢 Confidence 8/10 · likely safe to merge. Token lifecycle and path guard are tested, but the objective-C host wiring (push.rs, the openedPath handshake) has no test and only ran on a simulator.
no findings · tests partial −1 · risk high −1

The iOS host now hands the runtime an APNs token, which registers it for the signed-in user and forgets it on sign-out, and a notification tap opens its hazel.path. Contained and careful; safe to merge.

  • HazelAppDelegate and a notification-center delegate collect the token and taps (push.rs)
  • push.ts registers the token once per activation and unregisters on sign-out
  • The host holds a tap's path until the runtime follows it
  • signOut forgets the device first, capped at three seconds

Before merge

  • Manual · Exercise a production-APNs register and unregister on a TestFlight build; only sandbox was verified
What was checked
  • Both path guards refuse //host, \, control characters; app_path (shell.rs:42) is the stricter one
  • unregister aborts the in-flight registration before the session goes (push.ts:131), and signOut runs it first (auth.ts:64)
  • Repeat activations do not re-register: registered/inFlight dedupe per token, and UnauthorizedError is not retried

a321904 · Reply "won't fix" to dismiss a finding, or mention @maple-review-bot to ask about one.