From e3724d29ffb753867ebd1c52f7b644fdcb2bba25 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 26 Apr 2022 15:03:04 +1000 Subject: Cleanup: autopep8 --- doc/blender_file_format/BlendFileDnaExporter_25.py | 2 +- doc/python_api/examples/gpu.8.py | 2 +- release/scripts/modules/bl_i18n_utils/utils_spell_check.py | 2 +- release/scripts/modules/bl_keymap_utils/keymap_from_toolbar.py | 2 +- tests/python/eevee_render_tests.py | 2 +- tests/python/geo_node_test.py | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/blender_file_format/BlendFileDnaExporter_25.py b/doc/blender_file_format/BlendFileDnaExporter_25.py index 91a313b789f..f84f7482baf 100755 --- a/doc/blender_file_format/BlendFileDnaExporter_25.py +++ b/doc/blender_file_format/BlendFileDnaExporter_25.py @@ -411,7 +411,7 @@ def main(): # read blend header from blend file log.info("2: read file:") - if not dir in sys.path: + if dir not in sys.path: sys.path.append(dir) import BlendFileReader diff --git a/doc/python_api/examples/gpu.8.py b/doc/python_api/examples/gpu.8.py index 86a242b0258..385b71d0c1a 100644 --- a/doc/python_api/examples/gpu.8.py +++ b/doc/python_api/examples/gpu.8.py @@ -43,7 +43,7 @@ with offscreen.bind(): offscreen.free() -if not IMAGE_NAME in bpy.data.images: +if IMAGE_NAME not in bpy.data.images: bpy.data.images.new(IMAGE_NAME, WIDTH, HEIGHT) image = bpy.data.images[IMAGE_NAME] image.scale(WIDTH, HEIGHT) diff --git a/release/scripts/modules/bl_i18n_utils/utils_spell_check.py b/release/scripts/modules/bl_i18n_utils/utils_spell_check.py index 31b9705e45c..f9208bbe3ee 100644 --- a/release/scripts/modules/bl_i18n_utils/utils_spell_check.py +++ b/release/scripts/modules/bl_i18n_utils/utils_spell_check.py @@ -668,7 +668,7 @@ class SpellChecker: # Acronyms "aa", "msaa", - "acescg", # ACEScg color space. + "acescg", # ACEScg color space. "ao", "aov", "aovs", "api", diff --git a/release/scripts/modules/bl_keymap_utils/keymap_from_toolbar.py b/release/scripts/modules/bl_keymap_utils/keymap_from_toolbar.py index 6d41e290512..2cfba52d688 100644 --- a/release/scripts/modules/bl_keymap_utils/keymap_from_toolbar.py +++ b/release/scripts/modules/bl_keymap_utils/keymap_from_toolbar.py @@ -391,7 +391,7 @@ def generate(context, space_type, *, use_fallback_keys=True, use_reset=True): if key is not None: kmi_args["type"] = key kmi_tuple = dict_as_tuple(kmi_args) - if not kmi_tuple in kmi_unique_args: + if kmi_tuple not in kmi_unique_args: kmi = keymap.keymap_items.new(idname="wm.tool_set_by_id", value='PRESS', **kmi_args) kmi.properties.name = item.idname kmi_unique_args.add(kmi_tuple) diff --git a/tests/python/eevee_render_tests.py b/tests/python/eevee_render_tests.py index bd14fadb3b3..8c6f08ae76e 100644 --- a/tests/python/eevee_render_tests.py +++ b/tests/python/eevee_render_tests.py @@ -63,7 +63,7 @@ def setup(): collection = bpy.data.collections.new("Reflection") collection.objects.link(plane) # Add all lights to light the plane - if invert == False: + if not invert: for light in bpy.data.objects: if light.type == 'LIGHT': collection.objects.link(light) diff --git a/tests/python/geo_node_test.py b/tests/python/geo_node_test.py index 65ea500d2a1..9d7c634db76 100644 --- a/tests/python/geo_node_test.py +++ b/tests/python/geo_node_test.py @@ -13,5 +13,5 @@ geo_node_test = BlendFileTest("test_object", "expected_object", threshold=1e-4) result = geo_node_test.run_test() # Telling `ctest` about the failed test by raising Exception. -if result == False: +if not result: raise Exception("Failed {}".format(geo_node_test.test_name)) -- cgit v1.2.3