fix: preserve trace-name validation when routing is disabled - #3972
techmannih wants to merge 1 commit into
Conversation
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
| "platform_disabled", | ||
| "board_disabled", | ||
| "legacy_disabled", | ||
| ]) { |
There was a problem hiding this comment.
Wrong pattern, make the tests explicit for each of the case. Very confusing to review
092eaab to
5454944
Compare
There was a problem hiding this comment.
How is this beneficial? If the board has routingDisabled then why to confuse the AI with this error when It's not needed to route? I don't think this is a valid error from the AI
Video reviewComplete Reviewing commit This comment updates as work progresses. Job: 823941374-issue_comment-5714062801 |
|
Hi @techmannih, thank you for the review and feedback! I will update the PR to address these points shortly. |
1 similar comment
|
Hi @techmannih, thank you for the review and feedback! I will update the PR to address these points shortly. |
Fix
Traces with the same name on separate electrical nets now retain their existing name-conflict diagnostic when PCB routing is disabled. Previously
Group.doInitialPcbDesignRuleChecks()returned before validating names for platform/boardroutingDisabledand disabled legacy autorouters.Run the existing Group name validation before the routing guards. Keep the legacy-router guard next to standalone routing checks; their existing helper already handles
routingDisabled. The production diff remains seven lines inGroup.ts, preserving name scoping and the exception for mutually connected same-named traces.Regression tests
Stacked on #3971, which contains every explicit scenario and its fixture. This layer changes the three disabled-case assertions to require the existing diagnostic and updates their snapshots. All setup, snapshot options, routing-enabled coverage, valid-name controls, and router/cache tests come from the repro layer unchanged.
Only the error-text overlay changes in the three snapshots; PCB geometry and ratsnests are identical. Legacy missing-copper diagnostics remain present. No new error message or error type is introduced.
Related to tscircuit/tscircuit#4948. Native stack:
main→ #3971 → this fix.Validation
tsc --noEmitand Biome checks pass.