From cffa10bca8ed37ec96edbb43420ea86920165928 Mon Sep 17 00:00:00 2001 From: Claudio Usai Date: Wed, 29 Apr 2026 15:02:11 +0200 Subject: [PATCH 1/2] update changelog --- CHANGELOG.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8076d58..4008975 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,22 @@ # Changelog +## [0.2.2] - 2026-04-29 + +### Fixed + +- `CalendarQueue.delete_items()` did not decrement `_unfinished_tasks` for removed items, causing `queue.join()` to block indefinitely after any deletion. +- `CalendarQueue._update_timer()` unconditionally cancelled and recreated the timer when the queue had exactly one item, even when the timer was already set for the correct time. +- `Calendar.stop()` permanently prevented further iteration with no way to recover; behavior is now documented and `reset()` is provided as the recovery path. +- Removed leftover `executor` attribute from `Calendar` (orphaned from the 0.2.0 executor-pattern removal). +- Corrected docstring for `CalendarQueue.delete_items()`: selector tuple shape was documented as `(scheduled_ts, key, item)` but is `(scheduled_ts, item)`. +- Corrected docstring for `Calendar.cancel_event()`: return type was documented as `int` but is `list[tuple[float, CalendarEvent]]`. +- Corrected docstring for `Calendar.clear()`: description incorrectly said "The number of cancelled events" instead of "List of cancelled events". + +### Added + +- `Calendar.reset()` — clears the internal stop flag set by `stop()`, re-enabling `async for` iteration over remaining scheduled events. +- `CalendarQueue.get_nowait()` override with explicit documentation that it bypasses scheduled timestamps and returns the earliest-due item immediately, regardless of when it is due. + ## [0.2.1] - 2026-04-18 ### Fixed From ed0f67e2ed287f313f8da40462449cf4b7c43b5c Mon Sep 17 00:00:00 2001 From: Claudio Usai Date: Wed, 29 Apr 2026 15:02:44 +0200 Subject: [PATCH 2/2] bump version to 0.2.2 --- src/calendar_queue/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/calendar_queue/__init__.py b/src/calendar_queue/__init__.py index 89feee1..20f5892 100644 --- a/src/calendar_queue/__init__.py +++ b/src/calendar_queue/__init__.py @@ -3,4 +3,4 @@ from .calendar_queue import CalendarEvent, CalendarQueue from .calendar import Calendar -__version__ = "0.2.1" +__version__ = "0.2.2"