LGTM: remove unnecessary 'pass' statements

Issue: A pass statement is only necessary when it is the only statement in a block (the list of statements forming part of a compound statement). This is because the purpose of the pass statement is to allow empty blocks where they would otherwise be syntactically invalid. If the block already contains other statements then the pass statement is unnecessary.

Recommendation: Remove the pass statement.

Relevant links: 
1a82a5e136/files/src/Mod/Import/stepZ.py (x78f479c31a062553):1

1a82a5e136/files/src/Mod/OpenSCAD/OpenSCADCommands.py (xad4868ffcdf82498):1

1a82a5e136/files/src/App/FreeCADInit.py (x9034ec6815c48e38):1
This commit is contained in:
luz.paz
2019-12-16 22:56:04 -05:00
committed by Yorik van Havre
parent d49edcc982
commit a00769bebf
3 changed files with 0 additions and 3 deletions

View File

@@ -192,7 +192,6 @@ def InitApplications():
PathEnvironment += path + os.pathsep
except UnicodeDecodeError:
Wrn('Filter invalid module path: u{}\n'.format(repr(path)))
pass
# new paths must be prepended to avoid to load a wrong version of a library
try:

View File

@@ -105,7 +105,6 @@ def import_stpz(fn,fc,doc):
os.remove(tempfilepath)
except OSError:
sayzerr("error on removing "+tempfilepath+" file")
pass
###
def open(filename,doc=None):

View File

@@ -327,7 +327,6 @@ class OpenSCADMeshBooleanWidget(QtGui.QWidget):
class OpenSCADMeshBooleanTask:
def __init__(self):
pass
self.form = OpenSCADMeshBooleanWidget()
self.form.buttonadd.clicked.connect(self.doboolean)
def getStandardButtons(self):