Open thirtythreeforty opened 1 year ago
@thirtythreeforty I wonder if this is a workflow that aligns with kicad. As you mentioned, kicad expects a single project per directory. Are you trying to reuse schematic sheets between projects/boards? The difficulty in reusing schematic sheets between boards is a long standing gap in functionality in kicad.
That's exactly what I was doing :) and yes, I agree KiCAD doesn't really support it so well. I think it would be easy enough to name the jlcpcb folder based on the top schematic name, but if you want not to support this scenario I would understand. Just a sanity check before writing the db would be nice.
@thirtythreeforty Can you provide a project with multiple boards so we can test possible changes?
multiboard-a has parts assigned. Opening jlcpcb-tools in multiboard-b triggers the console message:
07-29 11:26:45 com_github_bouni_kicad-jlcpcb-tools.store 240:Part U1 is already in the database but value, footprint, bom or pos values changed in the board file, part will be updated, lcsc overwritten/cleared.
2023.07.29 11:26:45 - DEBUG - update_from_board - Part U1 is already in the database but value, footprint, bom or pos values changed in the board file, part will be updated, lcsc overwritten/cleared.
Describe the bug When creating multiple KiCAD projects, or multiple boards, in the same directory, this plugin unconditionally uses the database at
jlcpcb/project.db
for all board files. If data is already present from a different board, it is immediately destroyed upon opening the plugin.To Reproduce Steps to reproduce the behavior:
Expected behavior Ideally I expect the plugin to maintain a separate database for each board file. (Intuitively, I expect the .kicad_sch and .kicad_pcb files to contain all the component data, so the presence of the database is already a little surprising.) Failing that, if the database is from a different board, I want the plugin to show an error about the situation and refuse to modify the existing database.
KiCad Version