@groeponline/pi-wishcraft 0.22.1 → 0.22.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,11 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.22.2] - 2026-08-20
6
+
7
+ ### Fixed
8
+ - Queue archive cutoff uses a frozen clock in tests, and the TPS "starts at 0" case resets the shared ring so file order cannot leak a fake rate.
9
+
5
10
  ## [0.22.1] - 2026-08-20
6
11
 
7
12
  ### Changed
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@groeponline/pi-wishcraft",
3
- "version": "0.22.1",
3
+ "version": "0.22.2",
4
4
  "description": "Wishcraft cockpit for the pi coding agent — powerline status, vibes, idea inbox, bash mode, and full customization.",
5
5
  "type": "module",
6
6
  "files": [
package/queue/store.ts CHANGED
@@ -364,12 +364,14 @@ export class PowerlineQueueStore {
364
364
  * `archiveSentItems` and `writeItems` share one `now` snapshot so a sent
365
365
  * item counted as remaining cannot be pruned on the same write.
366
366
  */
367
- archiveSentItems(olderThanMs: number = this.sentRetentionMs): {
367
+ archiveSentItems(
368
+ olderThanMs: number = this.sentRetentionMs,
369
+ now: number = Date.now(),
370
+ ): {
368
371
  archived: number;
369
372
  remainingSent: number;
370
373
  } {
371
374
  return this.withStoreLock(() => {
372
- const now = Date.now();
373
375
  const items = this.list();
374
376
  // writeItems prunes sent items older than sentRetentionMs on every write.
375
377
  // If the requested archive window were wider than that, items in the gap