Skip to content

Fix day-only alarms never firing when night starts at midnight - #845

Merged
marionbarker merged 1 commit into
devfrom
fix/alarm-night-start-midnight
Nov 22, 2026
Merged

marionbarker merged 1 commit into
devfrom
fix/alarm-night-start-midnight

Conversation

@bjorkert

Copy link
Copy Markdown
Member

With Night starts set to 00:00 (or any time before Day starts), the check that decides whether an alarm may fire treated the whole day as night, so alarms set to Day never went off. The sound check already handled this case, so the two disagreed. Both now use a shared isNight helper on AlarmConfiguration. Unit tests cover the schedule itself and shouldFire for day and night alarms with a midnight night start.

Alarm activation used a day/night check that assumed night starts in the evening, so a night start at 00:00 made the whole day count as night and day-only alarms never fired. Both the activation and sound checks now use one shared isNight helper on AlarmConfiguration that handles a night start earlier than the day start.

@marionbarker marionbarker left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approve by successful test build onto iOS 18.7.8 and iOS 27.2.1 test phone; and Claude review.

@marionbarker
marionbarker merged commit 64d2687 into dev Nov 22, 2026
1 check passed
@marionbarker
marionbarker deleted the fix/alarm-night-start-midnight branch November 22, 2026 01:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants