From 4abeb7e53970a2a37493e443663e63578ce82b50 Mon Sep 17 00:00:00 2001 From: Dmitriy Klabukov Date: Tue, 22 Dec 2020 19:13:26 +0000 Subject: [PATCH] Fix for exception while merging excellons if there is no slots in second one --- appObjects/FlatCAMExcellon.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/appObjects/FlatCAMExcellon.py b/appObjects/FlatCAMExcellon.py index bf0102c6..c5bac25c 100644 --- a/appObjects/FlatCAMExcellon.py +++ b/appObjects/FlatCAMExcellon.py @@ -1313,7 +1313,8 @@ class ExcellonObject(FlatCAMObj, Excellon): break if t: fused_tools_dict[t]['drills'] += tool_dict['drills'] - fused_tools_dict[t]['slots'] += tool_dict['slots'] + if 'slots' in tool_dict and tool_dict['slots']: + fused_tools_dict[t]['slots'] += tool_dict['slots'] fused_tools_dict[t]['solid_geometry'] += tool_dict['solid_geometry'] else: fused_tools_dict[toolid] = tool_dict