Releases: Vic-41148/somn
Release list
Somn v0.1.2 — smarter scoring, reliable alerts
A quality release: smoother and more accurate sleep staging, the habit-tap crash fixed, the chronotype quiz corrected to the real rMEQ scale, and a batch of reliability hardening — including a race that could silently drop the morning deep-sleep alert.
What's new
- Smoother, more accurate sleep staging. Stage classification now runs through a rolling 3-epoch window in the live tracking path, so a stray misread epoch no longer flickers the whole night between Wake/Light/Deep/REM — and the final moments of a session are always counted (the held-back final epoch is recovered even if a session ends mid-stop).
- Chronotype quiz corrected. The morning/evening quiz now uses the real rMEQ scale (4-25). Previous releases used the 19-item Horne-Ostberg bands (16-86) on rMEQ scores, which made every morning band structurally unreachable and mislabeled genuine morning types as evening. Stored results are rescaled automatically on load.
- Habit insights with confidence. Correlation cards now show how confident a finding is (Low/Medium/High based on the number of nights) alongside the sample size — a strong-looking r computed from 7 nights is no longer presented as a settled result.
- Seasonal analysis respects where you live. A new hemisphere override for the circadian/seasonal insights, for users whose schedule deliberately breaks from their geographic latitude.
What's fixed
- Habit-tap crash (caffeine / alcohol / stress). Tapping a habit row in Daily Log could crash the app — a Compose
FlowRowruntime-signature mismatch between the app's runtime and what modules compiled against. The whole compose stack is now aligned on one BOM, with a CI guardrail that fails the build if the resolved foundation version ever drifts from what modules compile against again. - Alarm firing screen is reachable again. The in-app full-screen firing experience only existed as a registered-but-never-navigated route. The app now navigates to it whenever the alarm service reports firing, including after snooze.
- Per-alarm wake windows honored. Each alarm's wake-confirmation window (10-45 minutes via the edit screen slider, 30 by default) now flows through the entire firing chain instead of falling back to the global default; the smart-fire and snooze re-arm paths respect it too. An NFC captcha option was added to the firing screen.
- Onboarding refinements. Life-stage options were pruned to the ones that actually affect your scoring, with an explicit "prefer not to say" choice; the recommended sleep-hours display is fixed.
- Deep-sleep alert race. The morning deep-sleep alert ("Brain Detox Interrupted") shared its notification id with the tracking service's foreground notification, so ending a session could delete the alert about half the time. It now uses its own id — the device test suite caught this one and now guards it (the same audit also moved the PPD and weekly-report notifications off ids owned by foreground services).
- Back button no longer strands a live session. Pressing back during tracking used to pop you back to Home with the recording still running and no way to stop it (the Home moon only starts sessions). Back is now locked while a session is active — the stop goes through Wake Up — and the Home moon returns you to the tracking screen if you ever land there mid-session.
- Morning review shows the right night. The review screen now renders the session it was opened for; a relaunch mid-flow could previously show a stale session from a previous night.
- Tracking notification tap-through. Tapping the ongoing "Sleep Tracking Active" notification now opens the tracking screen directly (previously it did nothing), so the Wake Up button is reachable from anywhere — even if you left the app mid-session.
What else changed
- Onboarding, alarm, and notification paths hardened; a crash-path fix ensures an interrupted stop can't lose the newest epoch.
- 15-step release preflight, now scripted and versioned (
scripts/run-release-preflight.sh): boots the emulator, seeds demo data, and runs the full device test suite end-to-end (FGS smoke, session e2e with morning alerts, wake-window e2e, habits forms, trends, vitals, alarms) — all 15 passed on this release. - Docs refreshed (README, PRIVACY, CONTRIBUTING, Play description) to match the code; CI now fails if the advertised unit-test count drifts from the real suite total.
- Still privacy-first: on-device sleep tracking, no account, no cloud, no analytics, no ads, no Google Play Services in the release build.
Verified
- Full 15/15 device preflight on the emulator (fresh seed -> UI verifies -> session e2e -> release build), including the morning-alert e2e that regresses the deep-sleep race.
assembleReleaseclean (R8 minification, zero missing-member warnings); compose-foundation alignment guardrail green.- 193 unit tests, lint gate green.
Install
Download app-release-signed.apk and open it on your device (Android 8.0 / API 26+). Allow "install unknown apps" when prompted.
Checksum
The release pipeline computes the signed APK's SHA-256 automatically; it is attached to this release as SHA256SUMS.txt in the assets below.
Links
License: GPL-3.0
v0.1.1
Somn v0.1.1 — stability hotfix
Fixes the crashes in v0.1.0 where tapping Sleep (and in some cases Settings) could close the app.
The v0.1.0 release shipped with a foreground-service bug: on Android 14+ devices the platform enforces foreground-service types at start time — claiming the "health" type requires the Body Sensors runtime permission and "microphone" requires Record Audio, or the system throws and the app process dies. v0.1.0 declared both types but never asked for Body Sensors, so tapping Sleep could crash on exactly the devices where people most want a sleep tracker.
What's fixed
- Sleep button crash (the big one).
SleepTrackingServicenow:- claims only the foreground-service types whose runtime permissions are actually granted,
- falls back to the permission-free "special use" type when microphone/body sensors are denied, so sleep tracking still starts,
- and any failed foreground promotion degrades to a logged, clean stop instead of taking the whole app down.
- Settings button crash. Opening Settings could crash if any preference flow failed to load. Every Settings data flow is now guarded — it keeps the last known value, logs, and never crashes.
- Alarm reliability. Alarm foreground promotion is guarded the same way and uses the correct media-playback service type on Android 11+, so alarms start and ring reliably.
- Onboarding now requests Body Sensors (optional) so sleep tracking can run as a health service on Android 14+.
What else changed
- Same privacy-first feature set as v0.1.0: on-device sleep tracking, no account, no cloud, no analytics, no ads, no Google Play Services in the release build.
- New unit tests lock in the foreground-service type logic (143 tests total, lint gate green).
Verified
- Crash-repro tested end-to-end on Android 15 (tap Sleep, tap Settings, fire an alarm — no crash), Android 13, and install-verified on Android 16.
./gradlew testDebugUnitTest assembleDebug lintDebugall green.
Install
Download app-release-signed.apk and open it on your device (Android 8.0 / API 26+). Allow "install unknown apps" when prompted.
Checksum
SHA-256 (app-release-signed.apk): 1081c954bf6d6a5c06776d324815b51a14d2f00dbf4b323c0aacefc61b7f7f41
Links
License: GPL-3.0