Skip to content

fix(validate): include KiCad version in cache key - #88

Open
Princess0407 wants to merge 1 commit into
CopperPilot:mainfrom
Princess0407:fix/kicad-version-cache-invalidation
Open

Princess0407 wants to merge 1 commit into
CopperPilot:mainfrom
Princess0407:fix/kicad-version-cache-invalidation

Conversation

@Princess0407

Copy link
Copy Markdown

What changed and why

Fixes a cache invalidation issue in the validation runner where cached ERC and DRC results could be reused after changing the installed KiCad CLI version. Previously, Runner.cache_key() accounted for design inputs, check configuration, reviewer settings, and execution options, but did not include the detected KiCad version. Consequently, running validation with KiCad 9 and subsequently upgrading to KiCad 10 could result in the previous ERC/DRC results being reused without executing the checks against the new version.

Changes

  • Added the detected KiCad CLI version to the validation cache key.
  • Ensured cache entries generated using different KiCad versions are treated independently.
  • Added test_kicad_version_change_invalidates_cached_erc_and_drc to verify that changing from KiCad 9 to KiCad 10 invalidates cached ERC and DRC results and triggers fresh executions.

Test plan

  • make lint
  • make test
  • Targeted regression test: test_kicad_version_change_invalidates_cached_erc_and_drc — passed
  • Validation tests: tests/test_validate.py — 73 passed
  • Full non-live test suite: ./local_pytest.py -m "not live" — 1,102 passed, 1 skipped, 5 deselected
  • Live test not applicable: this change affects local validation cache invalidation and does not modify authentication or hosted execution.

Checklist

  • Tests added or updated
  • Docs update not required; this is an internal validation cache-key change with no change to the public CLI interface.
  • No new server, model-picker, computer-use, MCP, sandbox, or LangSmith surface.

This branch has not been deployed

No deployments
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