You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The remove_custom_properties function in the _Initializer (link) causes a crash if any scene keys exist when cleanup is called. The error is "RuntimeError: IDPropertyGroup changed size during iteration". This happens in Python 3, as unlike Python 2, the keys-call no longer creates a copy of the keys.
Simple fix: Change for key in bpy.context.scene.keys() to for key in list(bpy.context.scene.keys()).
Minimal code example
importblenderprocasbproc# Then import a Blender addon which adds any scene keys on import, like HumGen3D:fromHumGen3DimportBatchHumanGenerator, humandef_main():
bproc.init(clean_up_scene=True) # crash with the above RuntimeErrorif__name__=='__main__':
_main()
Describe the issue
The
remove_custom_properties
function in the_Initializer
(link) causes a crash if any scene keys exist when cleanup is called. The error is "RuntimeError: IDPropertyGroup changed size during iteration
". This happens in Python 3, as unlike Python 2, the keys-call no longer creates a copy of the keys.Simple fix: Change
for key in bpy.context.scene.keys()
tofor key in list(bpy.context.scene.keys())
.Minimal code example
Files required to run the code
No response
Expected behavior
For the init to not throw an error.
BlenderProc version
Github main 2dc7d68
The text was updated successfully, but these errors were encountered: