Repair a library
repair_libraryRemove orphaned 3D-model data from PcbLib files by deleting unreferenced embedded models and fixing body references to missing STEP models, resolving library validation errors.
Instructions
Repair a PcbLib by removing orphaned 3D-model data: (1) embedded models not referenced by any footprint, and (2) component body references that point to non-existent models. This fixes libraries where STEP model data is missing but references remain (validate_library reports both conditions). PcbLib only; a SchLib is refused.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dry_run | No | If true, report what would be fixed without making changes (default: false) | |
| filepath | Yes | Path to the library file (.PcbLib) |