Fix invalid Circuit JSON routes from through-obstacle autorouting#2257
Open
mohan-bee wants to merge 3 commits intotscircuit:mainfrom
Open
Fix invalid Circuit JSON routes from through-obstacle autorouting#2257mohan-bee wants to merge 3 commits intotscircuit:mainfrom
mohan-bee wants to merge 3 commits intotscircuit:mainfrom
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
seveibar
reviewed
May 7, 2026
|
|
||
| return circuitJsonRoutePoints | ||
| }) | ||
| } |
Contributor
There was a problem hiding this comment.
this is incorrect, should be through_pad
seveibar
requested changes
May 8, 2026
Contributor
seveibar
left a comment
There was a problem hiding this comment.
didn't address my comments
|
This PR has been automatically marked as stale because it has had no recent activity. It will be closed if no further activity occurs. |
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.
closes tscircuit/circuit-json-to-kicad#290
This fixes a routing export bug where internal through_pad route points could leak into pcb_trace.route.
through_pad uses start and end, but Circuit JSON traces need normal wire/via route points with top-level x and y. When the internal shape leaked, KiCad export could produce NaN coordinates.
This change converts through_pad points before writing pcb_trace:
creates a via at the start point
adds a wire on the target layer when needed
leaves existing wire and via points unchanged
A repro test was added to make sure rendered autorouter output writes valid pcb_trace routes.