Skip to content

Gravity Well v3.1.1 — Android Keepalive Service Stability Fix

Choose a tag to compare

@jcrabapple jcrabapple released this 02 Dec 10:37
· 10 commits to main since this release

Gravity Well v3.1.1

A patch release fixing an Android foreground-service race condition that could crash the app when resuming an archived session from 0 active sessions.

Bug Fixes

  • Android Keepalive Foreground Service (GravityWellKeepaliveService):
    • Added a synchronized lifecycle state machine preventing Context.stopService() from being invoked while a startForegroundService() call is still in flight (which previously caused RemoteServiceException$ForegroundServiceDidNotStartInTimeException).
    • Deferred stops requested during startup until onStartCommand() satisfies Android's foreground promotion contract (ServiceCompat.startForeground()), then cleanly calls stopSelf(startId).
    • Coalesced rapid startOrUpdate() bursts and eliminated redundant stopService() calls when already stopped.
  • Session Resume Cache & Watch Sync (ShellViewModel):
    • Cleared isArchived when a session_started WebSocket event arrives for a resumed session.
    • Scoped browserWatchJob keepalive syncing to (sessionId, isLive, status) transitions (distinctUntilChanged) so UI-only state changes don't spam service updates.

Assets

  • gravity-well-v3.1.1.apk — Release Android APK (us.snakepit.gravitywell, versionCode = 9, Android 8.0 / API 26+, R8 minified).
  • gravity-well-v3.1.1.apk.sha256 — SHA-256 checksum.