Repository navigation
A bug report's pointers carry the flags earlier sessions added to a command they had already run - #2337
A bug report's pointers carry the flags earlier sessions added to a command they had already run#2337zlareb1 wants to merge 15 commits into
Conversation
…carries They import lib/command-flags.mjs, which the next commit adds: the plugin tests fail until then. The fixture of the row's two requests is held to the memory wire models. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com>
…ommand they had already run A session that does not know a repository needs a flag on a command runs the command, reads a result it cannot use, and runs it again with the flag. The launcher now notes the runs of each shell command in the session's private state, as hashes of their words. At the session's end the counts go to one memory row a repository: for a program and a flag, the sessions that converged on the flag, the ones that had it on their first run and the ones that ran the program. A later bug report in a session that has the test report reads the row by key beside its search and prints a line for at most two pairs that three or more sessions converged on. The reader refuses a shape it does not know. It never counts a program that acts outside the checkout or a flag whose word forces, destroys, skips or weakens a check, or rewrites files. A session that was handed a pair's line adds nothing to that pair's counts. Both plugin manifests go to 1.2.191. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
| let changed = false; | ||
| const next = pairs.map((pair) => { | ||
| const seen = counts[pair.program]; | ||
| if (!seen || told.includes(pair)) return pair; |
There was a problem hiding this comment.
Unread lines still freeze counts
Medium Severity
flagsLine saves the repository row as soon as memory.get returns, but the prompt only appends those lines when code pointers were sent. revised then treats every pair from handed as already shown, so a session that never saw the line adds nothing to those counts.
Additional Locations (2)
Reviewed by Cursor Bugbot for commit 7059ff9. Configure here.
…e call A wrong line is read by every later session, so the reader refuses more than it reads: - A call with a parenthesis, a brace, a shell keyword or a here-document whose word is not plain is not read at all, and a run in a folder outside the checkout is not noted. - A flag counts only before the run's first bare word: the flag of a subcommand, or of the command a wrapper runs, is not the first word's. Wrappers and interpreters that are given a script are no programs. - A session converged on a flag when more than half of its runs from the first that carries it carry it, so a flag tried once and dropped is not counted. More programs and flag words are refused, and the docs say the two lists are the whole of that rule. - A resumed session stores nothing: it knows what its earlier part learned. - The row names a flag by its word only for a pair it hands and by a hash otherwise, so recall and the session primer tell no session a flag that the line would not. namespace.audit and the mentor leave a hook's read of the row out of their exact-key counts, as for the test cost row: HOOK_READ_KEYS is a regular expression over the whole key, and the audit rules exact_key_store and intentional_exact_key_reads go to versions 4 and 3. The sender census holds the reviewed read of both plugins and the pins of the files it covers. Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
| // The folder of what follows is known only after a `cd` to one plain path. | ||
| if (all[0] !== "cd" || !read || all.length !== 2 || !PLAIN_PATH.test(all[1])) break; | ||
| dir = path.isAbsolute(all[1]) ? all[1] : path.join(dir, all[1]); | ||
| continue; |
There was a problem hiding this comment.
Directory tracking follows cd in pipelines
Medium Severity
A cd in the first stage of a pipeline still updates the folder used for every later command, and a cd before || does too. Those commands either did not run or ran in the original folder, but they can be stored as in-checkout runs and create a false convention.
Additional Locations (2)
Reviewed by Cursor Bugbot for commit 093ecd1. Configure here.
…first run A session can run a program in a shape the reader does not read: after a wrapper, by its path, with its output in a file or inside a substitution. Such a run was invisible, so a session that had the flag from the start could read as one that added it. - Every shell command is read for the names it holds. A program that a command names before its first noted run is not counted for the session. - A session that ran a shell command before a prompt read the row, or one over 64 KiB, stores nothing. - A run carries a flag wherever the flag's word stands. The place before the first bare word decides only whether the flag is counted as added. - A program's name holds no dot, so a module named with one is no program. More interpreters that are given a script are refused, and more flag words: the docs state that the two lists are the whole of the rule. - A pair counts sessions until 30 have run its program. A pair the row does not hand by then is written by no later session, and a full row can give its place to a new pair. - The feature needs no test report. It runs in a Claude Code session on a POSIX host, under the test report's switch, and the launcher notes nothing with no credential. - The sender census is in main's layout again, and HOOKS.md lists LOOM_SESSION_MEMORY once. Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…ine goes on in the next line A flag of one or two letters (`--lf`, `--co`) is no flag: no refused word, three letters at least, can be read in an abbreviation, so a flag refused by its word was counted by its alias. The refused words gain `exec` (in place of `execute`), `plan`, `only`, `collect` and `stepwise`. A call that holds a `|` at a line's end is not read: the next line is a later stage of that pipeline, and it was read as a run. A resumed session is marked only where its runs are noted (`notesOn`): with no credential, in code mode or with session memory off it wrote a mark that nothing removed at the session's end. The docs say that a pair which counts no more does not enter the row again while the row holds it, and name the conditions under which runs are noted. A test holds the feature page's lists of keywords, programs and flag words to the library's. Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…nd no pair a list refuses A session that starts with no credential is marked at its start and stores nothing: its shell commands are not noted, so its first run after a credential comes was read as its first run of the program. The mark is written before the start signs the session up, so a resumed session that is signed up there is marked too. The launcher removes the mark at a SessionEnd with no credential, where no hand-off runs. A row's pair whose program or flag is not counted is read as not there, and the next write of the row leaves it out. Such a pair made the whole row unreadable, so a word added to a list left a repository with a row that printed no line and took no count until someone deleted it. The refused flag words gain `yolo`, `interact` (in place of `interactive`), `bail`, `changed`, `quick`, `exclude`, `select` and `filter`. The programs that act outside the checkout or run a file of recipes gain `cargo`, `gem`, `composer`, `go`, `dnf`, `yum`, `tox`, `nox`, `invoke`, `ninja`, `gradle`, `mvn` and `bazel`, and the words that start another command gain nine wrappers. The docs say that a wrapper which is not on the list is a program, and that a flag after a script it runs is counted as its own. Tests hold three rules that had none: a shell command over 64 KiB marks the session, nothing is noted or read on Windows, and the mentor reads no test tag in the write of either row. `simpleCommands` and `readsOnly` share one split of a command into words (`shellWords`). The `test_report` option's text names command conventions. The tables of what `loom-session-memory` sends at SessionEnd name the second `memory.set`, the Codex page lists the feature among what Codex does not have, and the README states the whole rule for a full row. Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
The reader joined the folder of a `cd` with the host's path rules, so a Windows host turned `cd /tmp/scratch` into `\tmp\scratch`. The paths of a shell call are a POSIX shell's on every host, and the reader now joins them so. Four tests held more than the feature promises, and failed on Windows and under WSL 2: - The test of the feature page's lists read the page with the host's line ends. It now reads a CRLF clone as it reads an LF one. - The mode tests listed `memory.get` among a bug report's ops. The read of the row is sent only where the search has not answered first, and never on Windows, so the session helper leaves that one read out of a session's ops and the mode tests are as they were. - Two prompt tests expected the read on every host. They expect it on a POSIX host and expect none on Windows. Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
… start wrote A session's start writes its command conventions state, and a session is counted only while that state is there. The sweep of day-old state files removed the mark of a session that stores nothing, so a long session was counted again from its next shell command, with its first run of a program not among its runs. A session whose state is gone now stores nothing: one the sweep reached, one that was resumed, one that started with no credential, one whose start the hooks did not see. A run is compared by its folder and its words. The same words in another folder were read as the command the session had already run, so a flag first used in a second package counted as added. A run in another checkout under the row's checkout (a submodule, a worktree, a clone) is not noted: it was counted for the outer repository. The programs that are not counted gain the ones that move or write the files their operands name (`cp`, `ln`, `tar`, `patch` and others), and the refused flag words gain `override`, `batch`, `kill`, `flush`, `cascade`, `reverse`, `bless`, `suppress`, `lenient`, `public`, `share` and others. `verify` becomes `verif` and `upgrade` becomes `grade`, which refuse more spellings. A row's pair is read only with a count of sessions the row can hold, 30 at most. The tests use counts a row can reach. The docs say what a row holds for a pair it does not hand: a hash of the program's name and the flag's word with no secret part, which a reader of the row can try the program's flags against. They say that the counts of a pair stay only while the row hands it, and what happens to a pair another one displaces. One predicate says whether a session's shell commands are counted (`countsRuns` in lib/test-report.mjs): the launcher, the library and the session's start wrote the condition out three times. The read of a repository's row into the session's state and the write that revises it are one helper (lib/repo-row.mjs) for the test cost row and the command conventions row, which each had a copy. Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…ull row gives up a pair it can never hand A release tool and the ClickHouse clients join the programs that are never counted: one more flag can turn a release tool's trial run into a release, and a database client acts outside the checkout. The feature page lists them, and a test holds the page's list to the module's. A full row gives a new pair the place of a pair that counts no more and that the row does not hand, as the docs say. Before, a pair whose counts would hand it kept its place where the row named it by its hash behind two pairs of more converged sessions: no session matches its flag to the hash once 30 have run its program, so it was never handed and never replaced. The test of handing drops the tenth of the sessions that ran the program: a pair counts 30 sessions at most and is handed from three, so the condition could not be false. The docs say that the bound keeps the tenth. HOOKS.md names the state the launcher removes at a SessionEnd with no credential, and lists the session's start among the readers of LOOM_SESSION_MEMORY and of the memory plane. Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…/test-cost.mjs Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com>
…hat a session that is not counted keeps - The row names a flag it does not hand by a hash of the program's name and the word. The README, the feature page, HOOKS.md and the `test_report` option's text said a hash of the word in five places. - HOOKS.md said a session whose shell commands are not counted writes no state. It notes no run and its start writes none, and one whose prompts are told still keeps its copy of the row a bug report read. - `simpleCommands` holds no fallback for a stage `unquotedText` does not read: a call it does not read is refused before the call is cut, and a cut outside quotes leaves every stage readable. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com>
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
There are 3 total unresolved issues (including 2 from previous reviews).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit b189dbf. Configure here.
| export function runs(command) { | ||
| const joined = String(command || "").replace(/\\\n/g, ""); | ||
| const text = joined.length <= MAX_CALL ? withoutBodies(joined) : null; | ||
| const commands = text === null ? null : simpleCommands(withoutComments(text.replace(NO_FILE_REDIRECT, " "))); |
There was a problem hiding this comment.
Comments can start here-documents
Medium Severity
runs strips here-document bodies before it strips comments, and withoutBodies does not treat # as a comment. A << inside a comment is read as an opener, so later real commands up to a matching line are dropped. Losing those runs can make a flag look converged when the session did not keep it.
Additional Locations (2)
Reviewed by Cursor Bugbot for commit b189dbf. Configure here.
…call - `names` reads a word of one dash and letters from after its first `m`, so `python -mmypy` and `python -Bmmypy` name `mypy`. Such a run is not read, and a session whose first run had that shape now has no count for the program where it was counted as one that added the flag. - `runs` holds no size bound. `noteRuns` ends a session's count at a call over 64 KiB before it reads the call, and the docs state the bound there only. - `revised` and `noted` name three things by what they are: `inRow`, `freeSlot` and `nameCounts`. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com>
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com>
- The session's state of command conventions is a file of lines. The start writes the first, and `noteRuns` adds one line for a command that changes the state and rewrites none. Each hook used to rewrite the whole state from the copy it read, so of two hooks that overlapped one lost its command, and a session could be counted with a first run it did not have. `stateOf` reads the lines back through the rule `noted` held, now `entry` and `folded`. - A test holds that a session with LOOM_SESSION_MEMORY=off still gets the line at a bug report. - The module's header says what a program with no known first run is before it says what a name is, and `revised` adds one to `ran` plainly. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Lareb Zafar <lareb.zafar@clickhouse.com>


Changelog category (leave one):
Changelog entry (one or two sentences a user of Loom can read without the diff; the release pull request collects these into the release notes):
The Claude Code plugin now tells a session a command convention of its repository. Under a bug report's code pointers it prints, for a flag that three or more earlier sessions added to a command they had already run, how many sessions did so; the counts come from the sessions' shell commands, with no model call.
Why
A repository can need a flag on a command that nothing in it names. A type checker with an incremental cache is one example: run without
--no-incrementalit can print a result the session cannot use.The line gives counts and no instruction:
How it works:
hooks/loom-record.mjsnotes its runs, and the names its text holds, in the session's private state (noteRunsin the newlib/command-flags.mjs), from the prompt that read the repository's row on. The state holds the program's name, the flag's word and hashes of the runs' folders and words and of the names, and no other text of a command. It is a file of lines: the session's start writes the first, and each shell command that changes the state adds one after the others and rewrites none.hooks/loom-session-memory.mjshands onememory.setto the flusher: the repository's row with the session's counts (flagsPost).hooks/loom-prompt-pack.mjsreads that row by key beside a bug report's search and prints a line for at most two of its pairs under the pointers (flagsLine).hooks/loom-session-start.mjswrites that state at the start of a new session whose shell commands are counted (startFlags). A session is counted only while it holds the state: a resumed session, one that starts with no credential and one whose state is gone store nothing.lib/repo-row.mjs, for this row and the test cost row.namespace.auditand the mentor leave the row's read out of their exact-key counts, as they do for the test cost row.The rules, each stated in the feature page,
HOOKS.mdand the README:|at a line's end (the pipeline goes on in the next line), a simple command that starts with a shell keyword (if,for,while,functionand the others), or a here-document whose word is not a plain word. A missed convention costs nothing. A wrong line is read by every later session..giton the way down from the root (a submodule, a worktree, a clone): its runs are another repository's. The folder is the command's, or the one acdof the call to one plain path changed to. The reader joins the folders of a call as POSIX paths on every host.python -m. A script path is never a program, and neither is a module named with a dot (python -m scripts.sync), which is a file of the checkout. A word that starts another command (env,timeout,sudo,uv,npxand others) is no program, and neither is an interpreter that is given a script (bash,node,ruby,julia,awkand the others of the list in the docs). An interpreter or a wrapper that is not on its list is a program, and a flag after the script it runs is counted as its own: the docs say so.--name=value) and a short flag are not counted. Neither is a flag of one or two letters (--lf,--co): it is an abbreviation, and no refused word can be read in it. A flag is counted as added only before the run's first bare word, so the flag of a subcommand, or of the command a wrapper runs, is not counted for the first word's program. A run that holds the flag's word after that still carries the flag: a session whose first run holds it there had the flag on its first run.cdnamed. After acdto a relative path it is the command's folder with the path as the call wrote it, since the hook is given the session's folder from before the call or from after it: two such runs are the same only after the samecdfrom the same folder.timeout, by its path, with its output in a file or inside a$(. So every shell command is read for the names it holds, a word or the last part of a path anywhere in its text. A word of one dash and letters also names what follows its firstm, so the module inpython -mmypyis a name. A program that a command names before its first noted run, or names more often than it runs it, is not counted for the session.pip install mypybefore the firstmypyrun ends the count ofmypy.force,yes,override,delete,kill,flush,skip,ignore,suppress,verif,fix,format,exec,commit,dry,run,plan,only,collect,exclude,filter,prompt,test,lint,error,quiet,public,shareand others), and a flag whose word holds one of them is refused: such a flag forces or confirms, destroys or rewrites, turns a trial run into a real one or back, skips, narrows or weakens a check, reaches outside the checkout or waits for a person. The program list holds programs that act outside the checkout, as a release tool and a database client do, move or write the files their operands name, or run a file of recipes (git,rm,cp,ln,tar,patch,ssh,docker,curl,pip,npm,cargo,semantic-release,psql,clickhouse-client,make,toxand others). The two lists are the whole of the rule, and the docs print both in full and say so: a flag of a program on neither list can be counted, whatever it does. A test holds the feature page's lists to the module's. A pair of a stored row whose program or flag is not counted is read as not there, and the next write of the row leaves it out: a word that joins a list later ends that pair's line and leaves the row's other pairs readable. The line states what earlier sessions did and gives no instruction.The line names no time. The hooks hold no duration of a shell call, so there is nothing to print one from.
Scope and risk
codemode, with session memory off or with no credential the start writes none, so the launcher notes no run. With session memory off, or once a credential has come, a bug report still prints the line, so the session still keeps its copy of the row it read; incodemode no row is read and no state is written. A session that starts with no credential stores nothing, also where a credential comes later: its earlier shell commands were not noted. The start writes the state before it signs the session up, and the launcher removes a session's state at a SessionEnd with no credential, where no hand-off runs. Whether a session's shell commands are counted is one predicate,countsRunsinlib/test-report.mjs, which the launcher, the library and the session's start ask. The row's read is sent beside the prompt's search and never waited for past its answer. Every path returns nothing on an error.node --test --test-name-pattern="same time" tests/command-flags.test.mjsstarts twelve hooks together and finds twelve programs; with a state that each hook rewrote whole, one to three of them were missing in each of three runs.memory.getat its first bug report in a checkout, and none after. A Codex session reads no row and notes no run: the launcher that reads the shell commands is Claude Code's. Nothing is noted or read on Windows, where acdcan name a folder by a path the reader does not resolve.HOOK_READ_KEYSinserver/memory/domain/namespace_shapes.pyis now a regular expression that holds the whole key of either row, andnamespace.auditand the mentor test a read's key withmatch. The audit rulesexact_key_storeandintentional_exact_key_readsgo to versions 4 and 3. No table, op or field changes.repo:<id>/command-flags/shell, taggedcommand-flags. The write names the value the session read at its first bug report (if_match_sha256) and is create-only after a miss. A row that another session wrote after that read refuses the write, and the session's counts are dropped, so a long session loses its counts more often than a short one. The docs state that loss. A value that is not the row's sentence is neither printed nor overwritten.memory.deleteon its key.tests/unit/session_content_senders.jsonholds the reviewedmemory.getof both plugins'lib/repo-row.mjs, in place of the one oflib/test-cost.mjs, and the pins of the files this change touches, in the layout the file has onmain. The module's regular expressions hold no quote character, which the census's scanner would read as the start of a string.lib/command-flags.mjscuts a command with the helpers oflib/shell-command.mjs, which exports four names it kept to itself and one split of a simple command into words (shellWords) thatreadsOnlyuses too. The row's read, its copy in the session's state and its conditional write are one helper for both rows, the newlib/repo-row.mjs(heldRow,rowPost), with the state's kind, the key, the parser and the tag as its arguments.lib/test-cost.mjsloses its copy.hooks/loom-record.mjs,hooks/loom-session-memory.mjs,hooks/loom-prompt-pack.mjsandhooks/loom-session-start.mjschange by a few lines each.lib/test-report.mjsgains the two predicates besidetestReportOn.lib/test-cost.mjschanges by 6 lines added and 35 removed: its read and its write call the helper.lib/test-gate.mjsandhooks/loom-test-report.mjsare untouched. Three test files change by a few lines: the stub server oftests/test-cost.test.mjsleaves the new row's requests out of the counts its tests assert, the session helpertests/mode-session.mjsleaves the row's read out of the ops of a session, since it is sent only where the search has not answered first, andtests/prompt-pack-hook.test.mjslists the row'smemory.getamong the requests of a bug report on a POSIX host and expects none on Windows.tests/plugin-modes.test.mjsis untouched. Thetest_reportoption's text in the Claude Code manifest names command conventions, and the Codex page lists the feature among what Codex does not have. Prettier pads four tables again: the switch table ofHOOKS.md, since the row ofLOOM_SESSION_MEMORYgrew, and the hook tables ofHOOKS.md, the README and the feature page, since the row ofloom-session-memorynames the secondmemory.set.mainchanged the test cost files after this branch began. The branch holds a merge ofmain. Git joinedlib/test-cost.mjs,lib/test-report.mjs,HOOKS.md, the README and the feature page with no conflict. The version line of both manifests and the two lines of the sender census that pin the hash oflib/test-cost.mjsconflicted: the merge keeps 1.2.191 and pins the hash of the merged file.mainis at 1.2.190.Compatibility, rollout and rollback
memory.getandmemory.seton the keyrepo:<id>/command-flags/shell, with the fields the test cost row uses;tests/unit/test_plugin_memory_contract.pychecks both requests and the reply against the wire models, and both keys againstHOOK_READ_KEYS.LOOM_TEST_REPORT=off(or thetest_reportoption) stops the note and the line,LOOM_SESSION_MEMORY=offthe note and the write, andcodemode all three. The feature has no switch of its own. A server of an earlier release counts the new row's read among the exact-key reads of the namespace and of the agent, one a session and checkout, until it is upgraded.memory.deleteon the key removes one.Tests
lib/command-flags.mjs:node --test integrations/claude-code-plugin/tests/command-flags.test.mjs. The second adds the module. The third to the ninth are review rounds: the rules above that the earlier commits did not hold, with a test for each, and the tests that failed on Windows and under WSL 2. Two merges ofmainfollow, with one more review round between them: the docs say what the hash of a flag is made of, and the reader loses a fallback that no call reaches. One more review round follows: a module in the word of an interpreter's-mis a name of its call, and the bound on a call's size is checked in one place, where it ends the session's count. After a third merge ofmain, the last commit is a review round too: the state is a file of lines, so shell commands whose hooks run at the same time are all noted, and a test holds that a session with session memory off still gets the line.cd, the calls that are not read), the refused programs, interpreters, wrappers and flag words, a wrapper that is on no list, a flag of one or two letters, the feature page's lists against the module's, the bare-word rule, the names of a call and a program named before its first run, what a session counts, which pairs are handed, how a row is revised, the 30-session bound, a row with a count over it, a pair that lost its place and enters again, the stored sentence with its hashes and its parser, a row's pair that is not counted, and the hooks end to end against a stub server: the note after a command that passed or failed, the write at the session's end, the line under a bug report's pointers with no test report, shell commands whose hooks run at the same time, the state read from its lines, a file that does not start with the start's line, the switches, the line of a session with session memory off, a Codex client, a second checkout, a resumed session, a start after a compaction, a session whose start the hooks did not see, a session whose state the day-old sweep removed, a session that starts with no credential and gets one later, the state's removal at an end with no credential, a start with a switch off, which writes no state, the same words in another folder, a flag added with a move to another folder, a run in another checkout under the row's checkout, a shell command before the row's read, a shell command over 64 KiB, a run outside the checkout, a row the secret redaction would change, which is not sent, and a write the server refuses, which is not sent again. One test runs only on Windows: no state, no noted run and no read of the row there.node --test integrations/claude-code-plugin/tests/*.test.mjsholds 1374 tests, 8 of them skipped on a POSIX host. CI runs it on Linux, macOS, Windows, WSL 2 and Alpine. On a loaded local machine the whole run can fail a few timing tests, a different set each run; the last local run failed one, intests/file-context-read.test.mjs, which passes when that file is run alone. The five test files that exercise the change pass when run alone:node --test tests/command-flags.test.mjs tests/plugin-modes.test.mjs tests/prompt-pack-hook.test.mjs tests/record-hook.test.mjs tests/test-cost.test.mjsfrom the plugin's folder gives 238 pass and 1 skipped, the test that runs only on Windows..venv/bin/python -m pytest tests/unit/test_session_content_senders.py tests/unit/test_plugin_memory_contract.py tests/unit/test_codex_plugin.py tests/unit/test_doc_links.py tests/unit/test_public_copy.py tests/unit/test_agent_instructions.py tests/unit/test_agent_plugin.py tests/unit/test_plugin_agrees_with_server.py: 579 pass.tests/unit/test_mentor.pyandtests/unit/test_namespace_audit.pyhold the server's side: a hook's reads of both rows are left out of the mentor's and the audit's counts, and the mentor reads no test tag in a hook's write of either row. The mentor's tests of the hooks pass locally. Ten tests of the two files that load thememorytable stop atUnknown setting 'enable_quantized_codec'with my local ClickHouse binary, nine of them tests this change does not touch, so the audit's test runs in CI. I ran itsNOT match(...)predicate over the test's rows withclickhouse local.tests/analyzerandtests/unit/test_package_contracts.pypass.make format-check,make lintandmake typecheckpass.node --checkpasses over every hook and library file of both plugins.python -m scripts.codegen.agent_plugin_syncwrote the Codex copies andpython -m scripts.codegen.docs_referencethe mentor's reference page.claude plugin validate integrations/claude-code-plugin --profile directory --strictreports one warning with the local client, about the plugin'sbin/folder, which this change does not touch.AI assistance in the code (leave one; writing this description with AI is fine):
AI-generated (an agent wrote most of the diff): Claude Code. I checked the reader against the shapes in the tests, ran the plugin's whole test suite, read the merge of
main's change to the test cost files, and read every doc sentence against the code.I can explain every line of this diff and how it interacts with the rest of Loom.
Checklist
make test-unitand applicable integration results are reported by CI; a full local run is not required before pushing.docs/reference/configuration.mdand thedocs/reference/tables (python scripts/codegen/docs_reference.py), the reach manifest,schemas/schema.sql(make schema-dump), the Codex plugin copies (python3 scripts/codegen/agent_plugin_sync.py) and the standalone skill bundles (python3 scripts/codegen/standalone_skills.py).main; no merged migration is edited.hooks/,lib/,bin/,skills/,.mcp.json, the Codexplugin-defaults.json) bumps both plugin manifests' version, and no other open PR uses that version.npm --prefix frontend run build) and its tests pass, iffrontend/changed.docs/describe the system as it now is, and this description names any operator steps and wire changes.tests/unit/test_public_copy.py).git commit -s), as CONTRIBUTING.md asks.🤖 Generated with Claude Code