From 83e15f8209efcd1a6f75daf65290b668a190ff4e Mon Sep 17 00:00:00 2001 From: "Salvador E. Tropea" Date: Mon, 4 Dec 2023 13:54:26 -0300 Subject: [PATCH] [QR Lib][Fixed] Interference with plot outputs When used from the preflight the name of the file changed to the name of a temporal, generating problems with the plot outputs, like pcb_print --- CHANGELOG.md | 3 +++ kibot/out_qr_lib.py | 2 ++ 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b1a7128e..6638b98c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -111,6 +111,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Copy Files: - Warnings when using both, the STEP and WRL model, of the same component - Fail to detect 3D models subdirs when running alone +- QR Lib: + - When used from the preflight the name of the file changed to the name of a + temporal, generating problems with the plot outputs, like pcb_print ## [1.6.3] - 2023-06-26 diff --git a/kibot/out_qr_lib.py b/kibot/out_qr_lib.py index a1fcd084..60316ecc 100644 --- a/kibot/out_qr_lib.py +++ b/kibot/out_qr_lib.py @@ -413,6 +413,8 @@ class QR_LibOptions(BaseOptions): with open(prl_name, 'rt') as f: prl = f.read() GS.board.Save(GS.pcb_file) + # After saving the file the name isn't changed, we must force it!!! + GS.board.SetFileName(GS.pcb_file) if prl: with open(prl_name, 'wt') as f: f.write(prl)