Skip to content

fix: stop scanner and roadmap audits from nagging consumer repos#229

Merged
solomonneas merged 1 commit into
mainfrom
fix/scanner-roadmap-defaults
Jul 12, 2026
Merged

fix: stop scanner and roadmap audits from nagging consumer repos#229
solomonneas merged 1 commit into
mainfrom
fix/scanner-roadmap-defaults

Conversation

@solomonneas

Copy link
Copy Markdown
Collaborator

What and why

Three Brigade defaults bugs, all surfaced by wiring a consumer repo (bootstrap-doctor) into Brigade. Each makes the daily brief of a repo that uses brigade (as a library and work-loop tool) but does not own the brigade CLI report noise it can't act on. All three were filed as friction from that repo; this is the cleanup.

1. Sweep ingest fails on self-importing scanners

brigade work sweep (ingest on by default) failed the whole sweep with import_path is not configured for memory-refresh and handoff-ingest. Those scanners append to the inbox via their own commands (brigade work import memory-refresh, brigade handoff sync-issues) and produce no JSONL import file, so there is nothing for the sweep to ingest. _scanner_validate_import_output now treats an absent import_path as a self-importing scanner and skips it silently instead of erroring. Workaround was --no-ingest; now unnecessary.

2. chat-memory-sweep required unconditionally

chat-memory-sweep sat in SCANNER_REQUIRED_IDS always, so a code repo with every chat surface disabled had to choose between a failing scanner (no producer for chat-memory-sweeps/latest.json) and a permanent scanner_required warning. It is now required only when at least one chat surface is enabled (via chat_cmd.health); repos that genuinely run chat surfaces are still nudged.

3. roadmap audit counts brigade's own CLI against every repo

brigade roadmap audit introspects brigade's own argparse parser, so a three-command consumer repo reported ~573 "undocumented" brigade commands and a stale docs/command-inventory.md it never owned. The brigade-catalog checks (roadmap_cli_command_missing_docs, roadmap_command_inventory_current) now run only when the target owns the brigade CLI (detected via pyproject.toml name = "brigade-cli"). The universal check that flags a bogus brigade command in any repo's docs (roadmap_documented_command_missing_cli) is unchanged.

Note on intent (please sanity-check)

Bug 3 reverses behavior that an existing test asserted: test_roadmap_audit_includes_command_inventory_drift expected the inventory-drift check to fire on an arbitrary target. I read that as testing the mechanism rather than an intentional "nag every consumer repo" policy, and updated it to mark its target as brigade-cli, plus added a test that a plain consumer repo gets no command-catalog checks. If you actually want every repo audited against brigade's command surface, say so and I'll drop bug 3 from this PR.

Testing

  • ./scripts/verify passes: ruff lint + format, mypy, version-sync, and the full pytest suite (2085 passed, 3 skipped) at 81.22% coverage.
  • New regression tests: self-importing scanner ingests cleanly; scanner_required ignores a disabled chat-memory-sweep with no surface but warns when a surface is enabled; roadmap audit skips the catalog checks for a consumer repo and keeps them for a brigade-cli target.

Three defaults bugs that made a Brigade-wired consumer repo (one that uses
brigade as a library and work-loop tool, not the brigade source repo itself)
report noise in its daily brief:

- Sweep ingest failed the whole sweep with 'import_path is not configured'
  for self-importing scanners. memory-refresh and handoff-ingest append to
  the inbox via their own commands and have no JSONL import file, so the
  ingest step now skips a scanner with no import_path instead of erroring.

- chat-memory-sweep was unconditionally in SCANNER_REQUIRED_IDS, so a code
  repo with every chat surface disabled got a permanent scanner_required
  warning for a producer that has nothing to sweep. It is now required only
  when at least one chat surface is enabled.

- roadmap audit introspected brigade's own CLI parser against any target, so
  a small consumer repo reported hundreds of 'undocumented' brigade commands
  and a stale docs/command-inventory.md it never owned. The brigade-catalog
  checks (roadmap_cli_command_missing_docs, roadmap_command_inventory_current)
  now run only when the target owns the brigade CLI. The universal check that
  flags a bogus brigade command in any repo's docs is unchanged.
@coderabbitai

coderabbitai Bot commented Jul 12, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are limited based on label configuration.

🏷️ Required labels (at least one) (1)
  • coderabbit-review

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository: escoffier-labs/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 3ef3a9f8-c31b-4d35-8f84-e81a6f89bfd3

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/scanner-roadmap-defaults

Comment @coderabbitai help to get the list of available commands.

@solomonneas solomonneas merged commit 091f15b into main Jul 12, 2026
16 checks passed
@solomonneas solomonneas deleted the fix/scanner-roadmap-defaults branch July 12, 2026 23:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant