From 236f8605cda666e4ea18acf2b57bd6c98fc93f04 Mon Sep 17 00:00:00 2001 From: Markus Lampert Date: Sun, 25 Oct 2020 18:56:47 -0700 Subject: [PATCH] Special provisions for py2 - not understanding why though --- src/Mod/Path/PathTests/TestPathVoronoi.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/Mod/Path/PathTests/TestPathVoronoi.py b/src/Mod/Path/PathTests/TestPathVoronoi.py index a1ad7af9b9..451637d149 100644 --- a/src/Mod/Path/PathTests/TestPathVoronoi.py +++ b/src/Mod/Path/PathTests/TestPathVoronoi.py @@ -27,6 +27,7 @@ import Part import Path import PathScripts.PathGeom as PathGeom import PathTests.PathTestUtils as PathTestUtils +import sys vd = None @@ -44,7 +45,11 @@ def initVD(): vd.construct() for e in vd.Edges: - e.Color = 0 if e.isPrimary() else 1; + if sys.version_info.major > 2: + e.Color = 0 if e.isPrimary() else 1 + else: + e.Color = long(0) if e.isPrimary() else long(1) + vd.colorExterior(2) vd.colorColinear(3) vd.colorTwins(4)