From 234a57cfc669a49240ba1c3034f41e32a629a017 Mon Sep 17 00:00:00 2001 From: Sabol Martin Date: Fri, 12 Feb 2021 16:16:16 +0100 Subject: [PATCH] fix: Part containing more then 9 units (2 digits present). Start line parsing with TAB instead of unit number --- kibot/kicad/v5_sch.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/kibot/kicad/v5_sch.py b/kibot/kicad/v5_sch.py index 50705c8c..7276c2d9 100644 --- a/kibot/kicad/v5_sch.py +++ b/kibot/kicad/v5_sch.py @@ -1010,11 +1010,11 @@ class SchematicComponent(object): # Redundant pos if not line.startswith('\t'+str(comp.unit)): raise SchFileError('Missing component redundant position', line, f) - res = _split_space(line[2:]) - if len(res) != 2: + res = _split_space(line[1:]) + if len(res) != 3: raise SchFileError('Malformed component redundant position', line, f) - xr = int(res[0]) - yr = int(res[1]) + xr = int(res[1]) + yr = int(res[2]) if comp.x != xr or comp.y != yr: logger.warning(W_INCPOS + 'Inconsistent position for component {} ({},{} vs {},{})'. format(comp.f_ref, comp.x, comp.y, xr, yr))