Skip to content

Fixes for part assignment, order by Stock by default DESC#709

Open
larroy wants to merge 3 commits intoBouni:mainfrom
larroy:main
Open

Fixes for part assignment, order by Stock by default DESC#709
larroy wants to merge 3 commits intoBouni:mainfrom
larroy:main

Conversation

@larroy
Copy link
Copy Markdown

@larroy larroy commented Mar 26, 2026

When assigning parts, I had to click twice, turns out there was an exception when looking for the LCSC attribute, which seems is not set instantly.

@@ -1 +1 @@
{"partselector": {"basic": false, "extended": false, "preferred": true, "stock": false}, "gerber": {"tented_vias": true, "fill_zones": false, "plot_values": true, "plot_references": true, "lcsc_bom_cpl": true}, "general": {"lcsc_priority": false, "order_number": true}} No newline at end of file
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would say this shouldn't touched here

fp.SetField("LCSC", lcsc)
field = fp.GetFieldByName("LCSC")
field.SetVisible(False)
if hasattr(fp, "GetFieldByName"):
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What happens if there is no attribute? I created my own fix #711 as I haven't realized, that this exist. Either use mine or fix this :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants