Repository navigation
Prune the waiting-notice ledger when a hold leaves - #660
Conversation
settings.approvalNotices gained one persisted entry per hold ever seen and nothing removed them, so the per-server settings file grew for the life of the install. Its only job is one waiting notice per pending hold, so a sync now drops the entry of every hold that is no longer pending.
|
Verdict: PASS at 3850867 Ran at this tip (tarball of the tip, nothing patched by hand): Gate ③, the source change reverted with the tests kept: The bound is at the right place. The prune runs in the same call as the add, against the same set the add loop consumes (
Two non-blocking notes, for the record, not reasons to hold:
Not run: the full Not enqueued: T3 needs the maintainer's approve together with this PASS. No earlier conclusion exists at this tip — this is the first and only one. |
Owner decision 2026-10-22 09:57 Asia/Shanghai: the gates no longer check for "Not run:". A PASS still needs at least one Ran command, at the head; INC, hold and a wrong sha still refuse. The four real reports ThinkFlowLab#660-ThinkFlowLab#663 now pass the queue entry as written.
…g Not run (ThinkFlowLab#668) Fixes ThinkFlowLab#667 Every queue entry since ThinkFlowLab#658 refused `Birfy's PASS lists no command it ran` (ThinkFlowLab#660–ThinkFlowLab#663). The reviewer writes `Ran at this tip (…):` over a fenced block of `$ ` commands. `review-gate.mjs` read only a bare `Ran:` (`:65`) plus `- ` bullets (`:72-77`), and it had stripped every backtick first (`:32`), so the fence was invisible. - A `Ran …:` heading now counts (`/^Ran\b[^:]*:/`). Its commands are the `$ ` lines of the fenced block below it, or `- ` bullets as before. Words after a longer heading's colon are not a command. - Still refused: an empty `Ran:`, `Ran: -`, output-only blocks and a bare `$`; a PASS at another sha; INC; `hold`. A quoted block's `Ran:` still cannot lend the conclusion evidence (ThinkFlowLab#640). - **Owner decision 2026-10-22 09:57 Asia/Shanghai: 「那还是不检测这个了吧」. The gates no longer require a `Not run:` line.** `decide` drops the "has no Not run line" refusal. `Not run` stays recommended in `.claude/skills/review-pr`, docs/code-standards.md (Verifier honesty 3) and docs/autonomous-dev.md:147. AGENTS.md rule 4 never named it, so it is unchanged. - Fixtures: the four real PASS comments, verbatim, in `.github/scripts/fixtures/review-reports-660-663.json`. Through `merge-gate.mjs` `main()` with the real `review-policy.json`, **all four pass as written**. The same reports with a wrong head or with INC refuse. No changelog fragment: CI-only, as in ThinkFlowLab#640 and ThinkFlowLab#658. ## Verification at dfdc6ad - `ARCH_DOCS_BASE=origin/main TZ=UTC npm run verify` → pass (core 1204, social 319, tree 89, timeline 105, .github/scripts 149, interop 37, live-e2e 16; 0 fail). - review-gate + merge-gate tests → 59/59. Against main's `review-gate.mjs` → 9 fail. Against this PR's previous tip f12fda7 (Not run still required) → 3 fail. - Not run: a real merge_group run; smoke (no host code). ## Landing (T3) This PR's queue entry runs **main's** `review-gate.mjs` (from `base/`), which still wants a bare `Ran:` with bullets **and** a `Not run:` line. The self-review at this tip is written in exactly that shape, so the entry is expected to pass `merge-gate` as long as that PASS stays the newest conclusion at the tip. Any newer report has to keep that shape too. If it doesn't, `merge-gate` reds once, but it isn't a required check, and the queue merges on `tests-ok`: `gh pr merge 668 --auto --squash --match-head-commit dfdc6ad`. No admin-merge, no bypass. --------- Co-authored-by: Birfy <15378933+Birfy@users.noreply.github.com>
Prune the waiting-notice ledger when a hold leaves
settings.approvalNoticesgets one entry each time Bot Social holds a send (syncApprovalNotices) or the owner rejects one (postRejectNote), and nothing ever deleted them, so the per-serverflybot-social-settings*.jsongrew for the life of the install. Its only job is to keep one "Waiting for the owner's approval" note per hold; a hold that is no longer pending never needs its entry again.syncApprovalNoticesnow drops the entry of every hold that is not in the current pending set, so the ledger stays as small as the pending queue. The sibling mapsownLineApprovalsandholdRoomsalready cap at 200; this one is bounded by the live queue instead.plugins/social/test/social.test.jslists one hold (entry written) and then an empty queue (entry must be gone) — it fails without the change (the entry stays in the settings file).docs/subsystems/social.mdrecords the bound.Ran at the tip:
npm run verify(green,TZ=UTC). Not run: smoke (this macOS box has nosetsid, sodev/bench.shcannot startdsh web), Desktop, real-model steward.