fix: Rewrite DynamicSymbolLoader to prevent schematic file corruption (#40)

Fixes Issue #26 - add_schematic_component corrupts .kicad_sch files

Complete rewrite of DynamicSymbolLoader to use text manipulation instead of sexpdata:
- Preserves KiCAD file formatting perfectly
- Correctly handles KiCAD 9 symbol naming conventions (library prefix for top-level, no prefix for sub-symbols)
- Resolves parent-child symbol dependencies with (extends)
- Adds symbol caching for performance
- Simplifies component addition workflow

Tested on KiCAD 9.0.7 with R, C, LED, ESP32, and transistor components.
Compatible with recent Windows fixes (UUID generation, IPC, JLCPCB).

Co-authored-by: FlowSync0 <249798311+FlowSync0@users.noreply.github.com>
This commit is contained in:
FlowSync0
2026-02-26 17:02:10 +01:00
committed by GitHub
parent e4fa774eda
commit a69d288251
2 changed files with 2268 additions and 2382 deletions

File diff suppressed because it is too large Load Diff