Skip to content

Commit 17d8cd5

Browse files
committed
FIX: PEP8 - E129 visually indented line with same indent as next logical line
1 parent 4089ead commit 17d8cd5

File tree

8 files changed

+25
-26
lines changed

8 files changed

+25
-26
lines changed

doc/sphinxext/numpy_ext/numpydoc.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,8 @@ def mangle_docstrings(app, what, name, obj, options, lines,
8181
def mangle_signature(app, what, name, obj, options, sig, retann):
8282
# Do not try to inspect classes that don't define `__init__`
8383
if (inspect.isclass(obj) and
84-
(not hasattr(obj, '__init__') or
85-
'initializes x; see ' in pydoc.getdoc(obj.__init__))):
84+
(not hasattr(obj, '__init__') or
85+
'initializes x; see ' in pydoc.getdoc(obj.__init__))):
8686
return '', ''
8787

8888
if not (callable(obj) or hasattr(obj, '__argspec_is_invalid_')): return

nipype/external/six.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -704,8 +704,8 @@ def write(data):
704704
data = str(data)
705705
# If the file has an encoding, encode unicode with it.
706706
if (isinstance(fp, file) and
707-
isinstance(data, unicode) and
708-
fp.encoding is not None):
707+
isinstance(data, unicode) and
708+
fp.encoding is not None):
709709
errors = getattr(fp, "errors", None)
710710
if errors is None:
711711
errors = "strict"
@@ -830,7 +830,7 @@ def python_2_unicode_compatible(klass):
830830
# the six meta path importer, since the other six instance will have
831831
# inserted an importer with different class.
832832
if (type(importer).__name__ == "_SixMetaPathImporter" and
833-
importer.name == __name__):
833+
importer.name == __name__):
834834
del sys.meta_path[i]
835835
break
836836
del i, importer

nipype/fixes/numpy/testing/noseclasses.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,8 @@ def _find(self, tests, obj, name, module, source_lines, globs, seen):
106106

107107
# Recurse to methods, properties, and nested classes.
108108
if ((isfunction(val) or isclass(val) or
109-
ismethod(val) or isinstance(val, property)) and
110-
self._from_module(module, val)):
109+
ismethod(val) or isinstance(val, property)) and
110+
self._from_module(module, val)):
111111
valname = '%s.%s' % (name, valname)
112112
self._find(tests, val, valname, module, source_lines,
113113
globs, seen)

nipype/interfaces/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1732,7 +1732,7 @@ def _outputs_from_inputs(self, outputs):
17321732
corresponding_input = getattr(self.inputs, name)
17331733
if isdefined(corresponding_input):
17341734
if (isinstance(corresponding_input, bool) and
1735-
corresponding_input):
1735+
corresponding_input):
17361736
outputs[name] = \
17371737
os.path.abspath(self._outputs_filenames[name])
17381738
else:

nipype/interfaces/fsl/dti.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -647,8 +647,7 @@ def _list_outputs(self):
647647
return outputs
648648

649649

650-
if (Info.version() and
651-
LooseVersion(Info.version()) >= LooseVersion('5.0.0')):
650+
if (Info.version() and LooseVersion(Info.version()) >= LooseVersion('5.0.0')):
652651
CurrentXFibres = XFibres5
653652
CurrentBEDPOST = BEDPOSTX5
654653
else:

nipype/pipeline/plugins/base.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -607,18 +607,18 @@ def _get_args(self, node, keywords):
607607
value = open(value).read()
608608
if (hasattr(node, "plugin_args") and
609609
isinstance(node.plugin_args, dict) and
610-
keyword in node.plugin_args):
611-
if (keyword == "template" and
612-
os.path.isfile(node.plugin_args[keyword])):
613-
tmp_value = open(node.plugin_args[keyword]).read()
614-
else:
615-
tmp_value = node.plugin_args[keyword]
616-
617-
if ('overwrite' in node.plugin_args and
618-
node.plugin_args['overwrite']):
619-
value = tmp_value
620-
else:
621-
value += tmp_value
610+
keyword in node.plugin_args):
611+
if (keyword == "template" and
612+
os.path.isfile(node.plugin_args[keyword])):
613+
tmp_value = open(node.plugin_args[keyword]).read()
614+
else:
615+
tmp_value = node.plugin_args[keyword]
616+
617+
if ('overwrite' in node.plugin_args and
618+
node.plugin_args['overwrite']):
619+
value = tmp_value
620+
else:
621+
value += tmp_value
622622
values += (value, )
623623
return values
624624

tools/apigen.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -346,7 +346,7 @@ def discover_modules(self):
346346
for dirname in dirnames[:]: # copy list - we modify inplace
347347
package_uri = '.'.join((root_uri, dirname))
348348
if (self._uri2path(package_uri) and
349-
self._survives_exclude(package_uri, 'package')):
349+
self._survives_exclude(package_uri, 'package')):
350350
modules.append(package_uri)
351351
else:
352352
dirnames.remove(dirname)
@@ -355,7 +355,7 @@ def discover_modules(self):
355355
module_name = filename[:-3]
356356
module_uri = '.'.join((root_uri, module_name))
357357
if (self._uri2path(module_uri) and
358-
self._survives_exclude(module_uri, 'module')):
358+
self._survives_exclude(module_uri, 'module')):
359359
modules.append(module_uri)
360360
#print sorted(modules) #dbg
361361
return sorted(modules)

tools/interfacedocgen.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ def discover_modules(self):
417417
for dirname in dirnames[:]: # copy list - we modify inplace
418418
package_uri = '.'.join((root_uri, dirname))
419419
if (self._uri2path(package_uri) and
420-
self._survives_exclude(package_uri, 'package')):
420+
self._survives_exclude(package_uri, 'package')):
421421
modules.append(package_uri)
422422
else:
423423
dirnames.remove(dirname)
@@ -426,7 +426,7 @@ def discover_modules(self):
426426
module_name = filename[:-3]
427427
module_uri = '.'.join((root_uri, module_name))
428428
if (self._uri2path(module_uri) and
429-
self._survives_exclude(module_uri, 'module')):
429+
self._survives_exclude(module_uri, 'module')):
430430
modules.append(module_uri)
431431
return sorted(modules)
432432

0 commit comments

Comments
 (0)