patch: Fix coverage gaps in template categories (step 1 of #42)#43
Merged
Conversation
`fips-agents patch check` had drifted behind what the template repos actually ship. Closes part 1 of #42. Fixed bugs: - `src/*/__ init__.py` had a literal space, so the pattern matched nothing — MCP package `__init__.py` files were unreachable via patch despite being shipped by the template. - The MCP server template ships `.claude/commands/*.md` but no `claude` category existed for `mcp-server`. Slash command updates were unreachable. Filled gaps the audit surfaced: - MCP `core` now lists `src/main.py` (the entry point). - MCP `docs` now covers `AGENTS.md`, `CONTRIBUTING.md`, `DEVELOPMENT_PROCESS.md`, `OPENSHIFT_DEPLOYMENT.md`. - MCP `build` now covers `.dockerignore`, `.gitignore`, `.gitleaks.toml`. - Agent `claude` category now also globs `.claude/rules/**/*` so `agent-development.md` (and the workflow template's `workflow-development.md`) are patchable. Defense-in-depth additions to `AGENT_NEVER_PATCH`: `tools/**`, `examples/**`, `prompts/**`, `rules/**`, `skills/**`, `.memoryhub.yaml`. These are paths `fips-agents add` writes into and that users customize, so a future pattern broadening cannot clobber them. Steps 2 (evals category) and 3 (per-template manifests) from the audit are tracked separately. Assisted-by: Claude Code (Opus 4.7)
This was referenced May 6, 2026
rdwj
added a commit
that referenced
this pull request
May 7, 2026
Closes #44. The agent and workflow templates ship a full eval harness under `evals/` (assertions, discovery, mock_factory, runner, package init, README). None of those files were covered by any patch category, so updates were invisible to `fips-agents patch check`. This adds an `evals` category to AGENT_FILE_CATEGORIES covering just the harness machinery and registers a `patch evals` subcommand. Set ask_before_patch=True since users may have customized the harness. User-authored eval inputs (`evals/evals.yaml` and `evals/fixtures/`) go to AGENT_NEVER_PATCH so the test plan and data fixtures stay under the user's control. Stacks on top of #43. Assisted-by: Claude Code (Opus 4.7)
rdwj
added a commit
that referenced
this pull request
May 7, 2026
Closes #44. The agent and workflow templates ship a full eval harness under `evals/` (assertions, discovery, mock_factory, runner, package init, README). None of those files were covered by any patch category, so updates were invisible to `fips-agents patch check`. This adds an `evals` category to AGENT_FILE_CATEGORIES covering just the harness machinery and registers a `patch evals` subcommand. Set ask_before_patch=True since users may have customized the harness. User-authored eval inputs (`evals/evals.yaml` and `evals/fixtures/`) go to AGENT_NEVER_PATCH so the test plan and data fixtures stay under the user's control. Stacks on top of #43. Assisted-by: Claude Code (Opus 4.7)
rdwj
added a commit
that referenced
this pull request
May 7, 2026
- Add v0.12.0 changelog entry (manifest loader, evals category, MCP claude category, never-patch matcher fix, pattern gap fills). - Update Patch Commands section: list .fips-template.yaml manifest support, add Gateway/UI category table, refresh per-type tables to match the actual category surface after #43, #46, #48, #49. - Expand the user-customized-files paragraph to cover the new AGENT_NEVER_PATCH entries and the gateway/UI never-patch list. Assisted-by: Claude Code (Opus 4.7)
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.
First of three follow-up PRs for #42 — the lowest-risk slice that fixes a real typo and fills the patterns that have drifted behind what the templates actually ship.
What
src/*/__ init__.pyhad a literal space, so MCP package__init__.pyfiles were unreachable via patch.claudecategory: the MCP template ships.claude/commands/*.mdbut no category covered them.coreaddssrc/main.py; MCPdocsaddsAGENTS.md,CONTRIBUTING.md,DEVELOPMENT_PROCESS.md,OPENSHIFT_DEPLOYMENT.md; MCPbuildadds.dockerignore,.gitignore,.gitleaks.toml. Agentclaudeadds.claude/rules/**/*.AGENT_NEVER_PATCH:tools/**,examples/**,prompts/**,rules/**,skills/**,.memoryhub.yaml— pathsfips-agents addwrites into and that users customize.Out of scope
evalscategory for agent / workflow (step 2 — separate issue / PR)..fips-template.yamlmanifests (step 3 — separate design issue).Test plan
tests/test_patch.pycovering the typo regression and every added pattern.pytest -x -q --no-cov→ 286 passed.black src testsclean.ruff check src testsclean.patch checkagainst the live templates.