Keep a note with each baseline mark and list the marks by reason - #57
Merged
Merged
Conversation
`baseline mark REASON --note TEXT TARGET...` stores a one-line note of at most 200 characters with the reason, such as the issue a `later` finding will be fixed in. Notes survive rewrites, `--merge` and marking again without one; an empty note removes it. The hook names them in the person's list of dismissals. Baseline entries also record the unit a finding names. Baselines without notes or units load unchanged. `baseline list [--reason ...] [--rule ...] [--format text|md|json]` prints accepted findings by path, then line, with their reason, rule, unit, fingerprint prefix and note; `md` prints a checklist for a cleanup issue. The hook's lists of findings, guards and unreviewed files share one helper, and the baseline keeps one sort for its entries.
Contributor
Author
Decisions (2026-10-03)The user accepts the design as built:
Added scope: update JevGate's agent instructions (the |
The instructions `jevgate init --agent` writes and the plugin's findings skill give a `later` mark the issue that will fix it with `--note`, and name `baseline list --reason later --format md` for exporting those marks.
tauanbinato
marked this pull request as ready for review
October 4, 2026 02:19
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
Closes #53
Closes #54
jevgate baseline mark REASON --note TEXT TARGET...keeps a one-line note (at most 200 characters, no line breaks) with the reason, such as the issue alaterfinding will be fixed in. Notes survivebaselinerewrites,--mergeand marking again without--note;--note ""removes one. The hook names the note in the person's list of dismissals at the end of a turn.unit, the unit a finding names, so the listing can print it. Both fields are optional: baselines without them load and are written back unchanged.jevgate baseline list [--reason intended|later|wrong]... [--rule RULE]... [--format text|md|json]lists accepted findings by path, then line, with reason, rule, unit, fingerprint prefix (8 characters, a validmarktarget) and note.mdprints a checklist to paste into a cleanup issue;jsoncarries the full fingerprint and message.Added scope (user, 2026-10-03): the instructions
jevgate init --agentwrites (src/setup/instructions.md) and the plugin's findings skill tell agents to give alatermark the issue that will fix it with--note "#123", and namejevgate baseline list --reason later --format mdfor exporting those marks.jevgate.schema.jsondescribesjevgate.tomlonly; no schema covers the baseline, so it is unchanged.How it was checked
tests/cli/baseline.rs: text, md and json output, ordering by path then line, filters by reason and rule, a filter that matches nothing, an unknown rule, an empty baseline, and an old baseline (nounit, nonote) that lists and whose unmarked entries are written back with the same fields; a note round-trips through the file and a two-line note is refused without touching the baseline.src/tests/gating.rs: a note survives a rewrite,--mergeafter checks that did and did not cover the file, re-marking without a note, and is cleared by an empty one; the note's length and line rules.src/hook/tests/mod.rs: a dismissal's note reaches the person's message at the end of the turn.cargo fmt --check,cargo clippy --locked --all-targets -- -D warningsandcargo test --lockedpass (886 unit, 82 CLI, 3 lint-policy tests)cargo +1.90.0 check --locked(1.90 is not installed on this machine; no new syntax; CI checks it)CHANGELOG.md has lines under
UnreleasedJevGate gate (
jevgate check --base origin/main --rule all --include-tests, 0.33.0): passed. Fixed: the hook's three "first N, then K more" lists now sharefirst_named, and the baseline's two sort-and-dedup copies sharein_file_order; the text listing builds its columns once. Dismissed one at a time withbaseline mark --note:src/baseline.rs:18file-organization,wrong: every function reads or writes jevgate-baseline.json (marked wrong on main before).src/command.rs:14file-organization,wrong: one function per command (marked wrong on main before; the old entry got the same note).src/tests/gating.rs:5file-organization,intended: the gate and the baseline it reads are tested together, as the module doc says.src/hook/text.rs:98shared-logic,wrong: each formats a different line (an undecided unit, a dismissal, a finding).src/hook/text.rs:181shared-logic,wrong: a singular or plural word chosen by a count; the words differ at each site.src/baseline.rs:275shared-logic,wrong: a filter over different collections with different tests.