screen-locker/early-bird-workout-check.timer
Krzysztof kuhy Rudnicki 9ab7c09c79
Some checks are pending
dependency freshness / dependencies on newest stable (push) Waiting to run
md-naming / markdown naming convention (push) Waiting to run
pre-commit / pre-commit (push) Waiting to run
Tests / test (push) Waiting to run
Tests / lock-popup-safety (push) Waiting to run
release-apk / release (APK) (push) Waiting to run
The early-bird window is the wake-alarm carrot, not a clock
05:00-08:30 (09:00 with the extended reward) locked nobody but did hold the
workout lock off on a clock that knew nothing about whether the user was
up, next to the morning-session rung that did. EarlyBirdMixin._is_early_bird_time
is now that rung's verdict: open before the alarm, during the session, and
until 11:00 once it completed in time -- exactly what wake-alarm signs. The
wake_alarm_skip rung banks the pending marker so the carrot's end still tries
a phone/RunnerUp workout before locking; early-bird-workout-check.timer moves
to 09:30:30 and 11:00:30, the two possible ends. The consumer's boot-retry
window starts at 05:00 with the refresher.

Also: the sick screen lists four past justifications, one line each -- six
full-length ones pushed it 7 px past 1366x768, which the screens-fit gate
only sees with a real history on disk. Takes @types/node 26.6.2, eslint 10.11.0.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XTdfXjbGYYrY7Quxcfz6mg
2026-09-20 08:39:44 +02:00

31 lines
1.5 KiB
SYSTEMD

[Unit]
Description=Re-check workout after early bird grace period expires (08:30 normal, 09:05 extended)
# NO After=graphical-session.target here. This timer is WantedBy=timers.target,
# and timers.target is ordered before basic.target before
# graphical-session.target -- so that After= closes a dependency cycle.
# systemd resolves such a cycle by DELETING this timer's job, which is exactly
# what happened on 2026-08-04 ("Job early-bird-workout-check.timer/start deleted
# to break ordering cycle"). The timer went disabled and the locker silently
# stopped enforcing for days. The service it triggers keeps its own
# After=graphical-session.target, which is where that ordering belongs.
[Timer]
# The early-bird window is the wake-alarm morning-session carrot since
# 2026-09-20 (screen_locker/_early_bird.py): it ends at the signed
# exempt_until -- 11:00 after a completed morning, min(start+90 min, 09:30)
# after an aborted one, alarm+15 min when no session started. These runs land
# just after the two boundaries the 5-minute tick could miss by up to five
# minutes; every run is idempotent ("already logged", "carrot still in force").
OnCalendar=*-*-* 09:30:30
OnCalendar=*-*-* 11:00:30
Unit=workout-locker.service
# Persistent=true: a machine asleep or off at a boundary would otherwise skip
# the re-check entirely, leaving the early-bird marker banked and the day
# unenforced. Both runs are idempotent (see above), so a catch-up run is safe.
Persistent=true
AccuracySec=1s
RandomizedDelaySec=0
[Install]
WantedBy=timers.target