Validate net-label and connector placement together before committing - #1212
Open
imrishabh18 wants to merge 2 commits into
Open
imrishabh18 wants to merge 2 commits into
imrishabh18 wants to merge 2 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
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.
Stacked on #1210 (
repro/rp2040-shaft-position).In the shaft-position schematic, the ENC_SCL label connector ends only 0.001 units from SDA. The label-clearance pass checks strict perpendicular crossings, which misses near-contact and endpoint contact, and only proposes an outward displacement. Clearing label text can therefore create an ambiguous wire attachment or leave the label unresolved.
The existing placement pass now validates the rendered label and its complete connector as one candidate, with 0.05 clearance from unrelated traces, including inline terminal wires. This rejects near-contact, endpoint contact, parallel overlap and crossing. Group changes are atomic and proposed connectors are also checked against one another. Same-net attachment remains legal.
If the usual outward proposal fails for an individual label, the same search tries alternate anchors and allowed orientations in connector-length order. It respects chips, text, labels, attachment geometry and same-net branches; blocked proposals do not mutate the output. In the shaft-position replay, ENC_SCL faces left beside its resistor on a short connector, clear of SDA. The SDA route remains unchanged. There is no additional cleanup/shortening stage.
Validation:
bun test: 416 passed, 4 existing skips, 0 failures.bunx tsc --noEmit,bun run format:checkand diff checks pass.The original shaft-position geometry is replayed at the label-clearance stage, not claimed as a captured historical full-pipeline input. Open
InlineNetLabelSolver/shaft-position-label-clearancein Cosmos to inspect it.