From eb581c02818c2e8c7e4dbda83cca34cdb482540d Mon Sep 17 00:00:00 2001 From: Philipp Oeser Date: Tue, 6 Jun 2023 09:47:56 +0200 Subject: [PATCH 1/2] Fix #106759: Error on running blender_icons_geom.py with curve 288e7d0af0c2 added support for legacy curves, these dont have attributes though, but code was checking for an active color atttribute. Now, only do this check (and skip that object) if it is a mesh (that doesnt have vertex an active color atttribute). --- release/datafiles/blender_icons_geom.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/datafiles/blender_icons_geom.py b/release/datafiles/blender_icons_geom.py index 45447892700..186e38b0fe1 100644 --- a/release/datafiles/blender_icons_geom.py +++ b/release/datafiles/blender_icons_geom.py @@ -350,7 +350,7 @@ def main(): if name.rpartition(".")[2].isdigit(): continue - if not ob_eval.data.attributes.active_color: + if ob_eval.type == 'MESH' and not ob_eval.data.attributes.active_color: print("Skipping:", name, "(no vertex colors)") continue -- 2.30.2 From f7b66cedf5da746e3e2fc03f55c749899416e01f Mon Sep 17 00:00:00 2001 From: Philipp Oeser Date: Tue, 6 Jun 2023 11:11:03 +0200 Subject: [PATCH 2/2] be more general in checking existance of attribute we could have other object types supported as well (e.g. curves -- which I wont add in this commit to make this a pure bugfix) --- release/datafiles/blender_icons_geom.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/datafiles/blender_icons_geom.py b/release/datafiles/blender_icons_geom.py index 186e38b0fe1..18cadd427bf 100644 --- a/release/datafiles/blender_icons_geom.py +++ b/release/datafiles/blender_icons_geom.py @@ -350,7 +350,7 @@ def main(): if name.rpartition(".")[2].isdigit(): continue - if ob_eval.type == 'MESH' and not ob_eval.data.attributes.active_color: + if (not hasattr(ob_eval.data, 'attributes')) or not ob_eval.data.attributes.active_color: print("Skipping:", name, "(no vertex colors)") continue -- 2.30.2