Conversation
LK
approved these changes
Feb 17, 2026
| &paths.pcb.with_extension("kicad_pro"), | ||
| config, | ||
| &netclass_assignments, | ||
| )?; |
There was a problem hiding this comment.
Missing project file now aborts layout sync
Medium Severity
process_layout now always calls patch_project_file whenever board_config exists. patch_kicad_pro immediately reads *.kicad_pro, so runs fail if that file is missing. Since resolve_kicad_files can return a default path for non-existent projects and update_layout_file.py only creates *.kicad_pcb, fresh layouts with board_config can error out.
Additional Locations (1)
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
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.


Note
Medium Risk
Changes affect deterministic generation and mutation of
.kicad_pcb/.kicad_produring layout sync, which could introduce formatting or settings drift across KiCad versions and existing projects despite added idempotency tests.Overview
Moves KiCad board/project configuration patching out of the Python sync step and into Rust.
Layout sync now post-processes both
.kicad_pcband.kicad_pro: the PCB file is structurally patched and prettified to enforce a canonicaltitle_block(with${PCB_NAME}/${CURRENT_DATE}/${PCB_VERSION}) and to apply stackup/layer/thickness updates; the project file is patched via a new Rustkicad_project_patchmodule that idempotently upserts constraint fields, predefined track/via sizes (merging without deleting user entries), netclasses, and only netclass pattern assignments when such assignments exist.Python
update_layout_file.pyis simplified by removing theSetupBoard/--board-configpath and related orphan-cleanup logic, andpcb layout --checknow also detects drift in the generated.kicad_proin addition to the PCB file; release test suppression is updated accordingly.Written by Cursor Bugbot for commit 77c5514. This will update automatically on new commits. Configure here.