- minor changes to increase compatibility with Python 3.8

This commit is contained in:
Marius Stanciu
2020-04-01 18:45:20 +03:00
committed by Marius
parent d326524fe3
commit 3d39916b5f
17 changed files with 72 additions and 67 deletions

View File

@@ -967,7 +967,7 @@ class Excellon(Geometry):
for drill in self.drills:
# poly = drill['point'].buffer(self.tools[drill['tool']]["C"]/2.0)
if drill['tool'] is '':
if drill['tool'] == '':
self.app.inform.emit('[WARNING] %s' %
_("Excellon.create_geometry() -> a drill location was skipped "
"due of not having a tool associated.\n"

View File

@@ -718,7 +718,7 @@ class Gerber(Geometry):
# so it can be processed by FlatCAM.
# But first test to see if the aperture type is "aperture macro". In that case
# we should not test for "size" key as it does not exist in this case.
if self.apertures[current_aperture]["type"] is not "AM":
if self.apertures[current_aperture]["type"] != "AM":
if self.apertures[current_aperture]["size"] == 0:
self.apertures[current_aperture]["size"] = 1e-12
# log.debug(self.apertures[current_aperture])