Repository navigation
Description
Summary
The plugins skill's catalog-regression check diffs consecutive run-journal snapshots to name the
interval in which a marketplace catalog first moved backward. The earliest snapshot in that chain is
pre-refresh.<mp>.json, written by sync.md's Step 1. Step 1 pairs that snapshot, a read, with
claude plugin marketplace update, a mutation, in one code fence and one rationale paragraph. The
audit action runs the same algorithm with every mutating call replaced by a prediction, so the
committed prose reads Step 1 as wholly mutating and tells audit to skip it. An audit run's
regression check therefore starts at pre and loses its first interval — the one that attributes a
backward catalog move to the marketplace refresh itself.
The snapshot is a read. audit legitimately declines only the claude plugin marketplace update
call that follows it.
Observed
Read on merged main at be3fb2a8d (claude-ops 0.44.0), the commit that added the guard.
plugins/claude-ops/skills/plugins/context/sync.md, Step 3'sauditbullet states it outright:
"auditissues zero mutating calls, so Step 1 never runs and the catalog is simply however stale
it already was".- The same file's "Run journal" section, in the paragraph on
audit's throwaway scratch directory,
enumerates only "Steps 2-5 project their id lists with--fromagainst a saved report, so it does
need somewhere to put those reports". Step 1's snapshot is not among the reportsauditis said
to write. - Step 1's own rationale justifies the snapshot solely by the refresh that follows it: "The snapshot
goes first because it is the only read taken while the catalog is still pre-refresh, which is what
lets the Run journal's catalog regression check attribute a backward move to this refresh." Under
auditthere is no refresh, so the stated reason reads as inapplicable. - The run-journal file table's
pre-refresh.<mp>.jsonrow is written forsyncalone: "Step 1's,
before that marketplace's refresh, so the refresh's own effect oncatalog_versionsis visible". SKILL.md's "Action: audit" section describesaudit's scratch directory the same partial way and
never says the Step 1 snapshot is taken.
Net effect: an audit run can only diff pre -> mid -> post, and cannot report a catalog
regression whose first appearance is the pre-refresh -> pre boundary.
Expected
- Step 1 separates its snapshot from its refresh: the snapshot is taken by both actions, and only the
claude plugin marketplace updatecall is replaced by a prediction underaudit. - The catalog-regression check's first interval is available in both actions, with the interval's
meaning stated for each: undersynca regression acrosspre-refresh->preis the Step 1
refresh pulling a source that moved backward; underaudit, which issues no refresh, it is the
catalog changing under the run (a concurrent session or a backgroundautoUpdatesweep). audit's scratch-directory handling accounts for the Step 1 snapshot, so the scratchrun_dir
exists before Step 1 runs.- The run journal's
pre-refresh.<mp>.jsonrow andSKILL.md'sauditdescription read correctly
for both actions.
Environment
claude-ops 0.44.0, plugins/claude-ops/skills/plugins/SKILL.md and
plugins/claude-ops/skills/plugins/context/sync.md. Origin: the downgrade guard added in #3936 for
#3930.
Activity
fix(claude-ops): audit takes the plugins skill Step 1 pre-refresh sna…