Designators for parts-with-sublayouts are not unique
When you add multiple sublayouts to a document, the existing designators of parts within those sublayouts remain whatever they were created to be in the source document.
This is a problem, because designators need to be globally unique within a PCB document. So when the sublayout is added to the main document, any conflicting designators should be updated.
Original bug report that raises this issue tangentially: https://fluxai.canny.io/admin/feedback/featurerequests/p/bom-file-and-sub-layouts?owner=bryan-939
A few things to be aware of when implementing this:
* Don't get confused here with the sublayout's designator. We're talking here about designators of components _inside_ the sublayout.
* I think we should preserve designator values that don't conflict. The sublayout author may have intended them to be meaningful.
* Per discussion with Bryan/Jared/Dominic, we should NOT implement this by mutating the part_version_data.extracted_element_cache -- very soon, part_version_data will be a reference and should be treated as readonly.
* This is a separate issue to finding a designator value that's conflict-free (i.e. one that doesn't clash with designators inside sublayouts). Bryan is addressing that separately (will post PR when ready)
marked this post as