Reminders: rewording one that was put off with Later clears its sent stamp, so it is announced again #445
Labels
No labels
accessibility
authentication
breaking change
bug
documentation
enhancement
interface
internationalisation
observability
performance
security
tier
1
tier
2
tier
3
tier/4
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Postulo/postulo#445
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Found on 2026-09-29 in a read-only review of postulo at
95348908d, reading the reminder edit view and checking the result with a unit test against the snapshot.Related to #238.
Checked again on 2026-10-01 against
mainat0a5cad587: still present. The code is now atapplications/views.py:767-773(ReminderUpdateView.form_valid);applications/forms.py,applications/services.pyandapplications/quiet.pyhave not moved, and the same unit test gives the same result.The reminder edit page decides the reminder was moved when
due_atis inform.changed_data. The field is shown and read back to the minute, but reminders made or moved by Later and by Snooze are stored with seconds, so every save of such a reminder counts as a move even when only the wording changed. The move clearsnotified_at, and a reminder already due and announced is announced a second time.applications/views.py:721-727(ReminderUpdateView.form_valid,moved = "due_at" in form.changed_data),applications/forms.py:509-515(ReminderForm, widget format%Y-%m-%dT%H:%M),applications/services.py:555-564(later_time),applications/quiet.py:158-159(snooze_until),applications/services.py:567-587(postpone_reminder).later_timeandsnooze_untilreturntimezone.now()plus whole days, seconds included. The edit form's initial value keeps the seconds (the date-time widget drops only microseconds), while the posted value has none, sohas_changedis true for an untouched time.form_validthen callspostpone_reminder, which setsnotified_at = None, and the save truncatesdue_atto the minute. Checked: a reminder with seconds indue_at, already due and stamped as sent, edited with the same minute and new wording; after the savenotified_atwasNone.due_atbefore the form binds (asApplicationUpdateViewkeeps the status before the edit) and treat the reminder as moved only when the two differ once both are truncated to the minute. Separately, havelater_timeandsnooze_untilreturn times truncated to the minute, so stored and displayed precision agree.Done when
tests/test_deadlines.pyhas a test that makes a reminder withlater_time("tomorrow"), marks it as sent, posts the edit form with the same minute and new wording, and assertsnotified_atis unchanged; the existing test that moves the time still sees the stamp cleared.