fix(7735): a rule the session already read counts as opened when it arrives again
CI & Build / Python lint (push) Successful in 2s
CI & Build / Plugin hooks (push) Successful in 12s
CI & Build / TypeScript typecheck (push) Successful in 32s
CI & Build / Python tests (push) Successful in 2m2s
CI & Build / integration (push) Successful in 2m10s
CI & Build / Build & push image (push) Successful in 34s

A delivery to a session that opened the rule within the open window is
stamped opened as it is written, and migration 0135 stamps the rows already
recorded the same way. The adherence readout, the ordering open rate and the
weighing pass read one definition: a rule read early in a long session is not
counted unread each time it is delivered later.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-24 07:06:18 -05:00
co-authored by Claude Opus 5.5
parent c486524b48
commit 78fa165e67
4 changed files with 102 additions and 2 deletions
+3 -1
View File
@@ -20,7 +20,9 @@ class RuleDelivery(Base):
was delivered once or twenty times. Here each delivery is a row, and the
open is stamped on the delivery it followed — so the open rate per rule,
per moment and per arm is a count of rows, and the ordering function reads
it as the rule's history at that moment.
it as the rule's history at that moment. A delivery made to a session that
had already opened the rule is stamped as it is written, with its own
time: it reached a reader who had the rule.
`at` is where the rule was delivered: the moment it was mounted on
(`work.finish`) or the arm that found it (`pre_tool_rule`). `form` is