Skip to content

v0.2.2 - stuck timer ring fixed, countdown input hardened, timer flow tests

Pre-release
Pre-release

Choose a tag to compare

@sultanmaliki sultanmaliki released this 21 Sep 06:51
· 8 commits to main since this release

v0.2.2 fixes the timer ring that got stuck on screen, hardens the countdown input, and adds on-device tests for the whole timer and stopwatch flow. Everything below is a change since v0.2.1. It installs as an upgrade over v0.2.x (same package and signature; your playlists and timer are kept). It is a non-debuggable build (developer test hooks off); sideload it as before.

Fixed

  • The half or full ring stuck on screen when pausing, starting or resuming. The ring is the hold-to-reset indicator and should only appear while you hold the timer to reset it. The gesture engine reported the ring's progress while the finger was held but never reported it back to zero on release, so an early release left a partial ring and a completed reset left a full circle on the screen. Now every gesture ends by clearing the ring, and a completed reset keeps the full ring visible until you lift your finger (a clear "it fired"), then clears it.
  • Countdown length dialog. Invalid input used to do nothing without any message, and a huge number of minutes could overflow into a garbage target. It now accepts mm:ss and h:mm:ss (digits only, seconds and minutes below 60, up to 99:59:59), and shows an error message for anything else.

Kept as it is

  • Local playback (video and audio files, playlists, the media notification) stays alongside companion mode.

Cleanup (nothing you can see changes)

  • Removed code that nothing used: an old colour helper replaced by the newer one, an unused pointer counter, a never-wired per-app session override (in the repository and the selector), three capability flags only their own tests read, and unused imports. Deleted an 850 MB stale heap dump and the intermediate test logs from the repo (kept the device probe, alarm, stress and gesture logs).
  • Docs brought up to date (README, PLAN, STRUCTURE, DECISIONS): status, decisions, the new tests, and a note on the name (see below).

How it was tested

  • 123 JVM unit tests (was 120), lint clean, clean debug and release builds. New: countdown input parsing (valid forms, whitespace, signs, non-digits, seconds/minutes limits, overflow, the 99:59:59 cap).
  • 30 on-device tests (was 18), all passing in 2 of 2 full runs on the final code and in 3 of 3 earlier runs. They run the real gesture engine and the real MainScreen on the phone using Compose's test framework (which works even though the phone blocks adb shell input):
    • Ring: cleared after an early release, kept full then cleared after a completed reset, cleared after an ordinary tap while paused, cleared when a finger drags away from a hold.
    • Timer/stopwatch flow: start, pause and resume totals; hold-to-reset works only while paused (and does not reset a running timer); a countdown runs to zero and stops; a finished countdown restarts only after a reset; 21 rapid taps end in the right state; switching mode while running stops and zeroes it; state is saved on every transition.
    • Earlier gesture tests (two-finger tap and swipe in both lift orders, jitter, three fingers, every tap zone, double-tap seek, drag-scrub, quick flick, hold and cancel).
  • The first version of the timer tests was flaky because it slept in real time and then jumped the test clock; real and virtual time now pass together, and the stable version passed every run afterwards.
  • Lifecycle stress run (Home/return cycles, notification-access revoke/grant, dark/light rebuilds while playing, memory trim, skip flood) repeated on the final code.

Name note

"Cadence" is also the name of an unrelated company: Cadence Design Systems holds a registered CADENCE trademark for integrated-circuit design software. A free gym timer is a very different product, so the practical risk for GitHub/sideload use looks low, but it is not zero and rises with a store listing, money or popularity. Before any store listing, search USPTO/EUIPO and the store for the exact name, or pick a more distinctive one (renaming is cheap). This is general information, not legal advice; details are in DECISIONS.md.

Not verified / known limitations

  • Not verified by me: the countdown-finished notification and its sound (the phone blocks granting that permission from the shell; it needs a tap on the dialog), rescheduling after a reboot, other music apps (only Mi Music has been observed), other phones (the audio visualizer varies by device), the real Settings toggle for notification access, and launcher-specific icon shapes.
  • The ring fix is proven by the automated on-device tests; the final check is your hands, so please try pausing, resuming and resetting the timer a few times.
  • Still debug-signed (not for Play Store); Google Play would also review USE_EXACT_ALARM and Record audio use. Alarms are cancelled by Android on force-stop.

Full diff: v0.2.1...v0.2.2