PD: LGTM - don't catch BaseException

This commit is contained in:
Chris Hennes
2021-09-19 14:37:23 -05:00
parent be5971ad8e
commit ff5bf3e0df
2 changed files with 2 additions and 2 deletions

View File

@@ -153,7 +153,7 @@ class Hole():
secondLineIndex = i
if (firstLineIndex > -1) and (secondLineIndex > -1):
break
except:
except Exception:
# Unknown curvetype GeomAbs_OtherCurve
continue
axis.References = [(support, elementList[0]), (support, "Edge" + str(firstLineIndex+1)), (support, "Edge" + str(secondLineIndex+1))]

View File

@@ -61,7 +61,7 @@ class TaskHole:
body.removeObject(sketch)
try:
document.removeObject(sketch.Name)
except:
except Exception:
pass # This always throws an exception: "Sketch support has been deleted" from SketchObject::execute()
body.removeObject(plane)
document.removeObject(plane.Name)