You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(Led): adopt auto-selected supplier part pin 1 polarity when polarity is unpinned - #5598
When <led /> uses a standard Footprinter footprint without explicit pinLabels, explicit <port>/<footprint> children, or explicit anodepin/cathodepin options, resolve supplier part candidates during FetchPartFootprint and adopt the supplier part's conclusive pin 1 polarity (anode or cathode) before trace, schematic, CAD, and DRC phases run.
Keep .anode/.cathode (.pos/.neg) selectors, source_port hints, schematic symbol port bindings, Footprinter silkscreen/fabrication polarity artwork, and 3D footprinter_string polarity options consistent with the adopted pin 1 polarity, while preserving source_component_misconfigured_error diagnostics whenever polarity is explicitly authored via pinLabels or footprint options.
Cache resolved supplier orientation analyses per component instance so PartOrientationAnalysis reuses the FetchPartFootprint lookup without issuing duplicate fetchPartCircuitJson requests when localCacheEngine is absent.
Validation
bun test tests/components/normal-components --timeout 30000 (504 passed, 0 failed)
Status check-in to keep this PR active — CI checks are green and the branch is mergeable against base. Happy to address any review feedback whenever convenient!
Status check-in to keep this PR active — CI checks are green and the branch is mergeable against base. Happy to address any review feedback whenever convenient!
Status check-in to keep this PR active — CI checks are green and the branch is mergeable against base. Happy to address any review feedback whenever convenient!
I filed #5565 and retested this on current main (v0.0.2478, 188 commits after this branch's base). It still merges cleanly, and tsc --noEmit is clean. I swapped the build into tscircuit 0.0.3293 and used an empty .tscircuit/cache.
So an explicit polarity is still checked, and only the default adapts to the part. The new test file fails on main (2 of 3) and passes on this branch (3 of 3).
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
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.
Fixes #5565
Summary
<led />uses a standard Footprinter footprint without explicitpinLabels, explicit<port>/<footprint>children, or explicitanodepin/cathodepinoptions, resolve supplier part candidates duringFetchPartFootprintand adopt the supplier part's conclusivepin 1polarity (anodeorcathode) before trace, schematic, CAD, and DRC phases run..anode/.cathode(.pos/.neg) selectors,source_porthints, schematic symbol port bindings, Footprinter silkscreen/fabrication polarity artwork, and 3Dfootprinter_stringpolarity options consistent with the adoptedpin 1polarity, while preservingsource_component_misconfigured_errordiagnostics whenever polarity is explicitly authored viapinLabelsor footprint options.PartOrientationAnalysisreuses theFetchPartFootprintlookup without issuing duplicatefetchPartCircuitJsonrequests whenlocalCacheEngineis absent.Validation
bun test tests/components/normal-components --timeout 30000(504 passed, 0 failed)bunx tsc --noEmitbun run check:class-exportsbun run build && bun run smoke-test:distbunx biome format