Page MenuHome

Bmesh: removed deform parameter of from_object still in PyDoc
Closed, ResolvedPublicBUG

Description

System Information
Operating system: Ubuntu 18.04.5 LTS
Graphics card: nvidia GTX 1050 Ti

Blender Version
Broken: 3.0.0, 93fd07e19cf, master, 2021-06-09
Worked: 2.93.0 LTS

Short description of error
The deform parameter for from_object method of BMesh object was deprecated in 2.93 and removed in 3.0 (task D10086). The latest code in master branch has indeed removed deform from kwlist, and attempting to use in Python console results in TypeError: 'deform' is an invalid keyword argument for from_object() (expected), but deform argument info still exists in PyDoc.

Related, the depsgraph argument was never added to PyDoc (since task D4065).

Exact steps for others to reproduce the error
From starting blend file, open Python console and type:

import bmesh
bm = bmesh.new()
bm.from_object( # press tab to see deform in list, but not depsgraph
bm.from_object(bpy.data.objects['Cube'], bpy.context.evaluated_depsgraph_get(), deform=True) # fails

Note to devs
I have a patch to update PyDoc to exclude deform and include depsgraph. I haven't built Blender from source in many months, so once I have finished installing all deps, rebuilt blender, and have tested the patch, I can submit the patch.

Event Timeline

Aaron Carlisle (Blendify) changed the task status from Needs Triage to Confirmed.Thu, Jun 10, 2:12 AM
Aaron Carlisle (Blendify) changed the subtype of this task from "Report" to "Bug".
Aaron Carlisle (Blendify) moved this task from Backlog to Documentation on the Python API board.

I have a patch to update PyDoc to exclude deform and include depsgraph. I haven't built Blender from source in many months, so once I have finished installing all deps, rebuilt blender, and have tested the patch, I can submit the patch.

Let us know if you need any help, feel free to reach out on https://blender.chat/channel/blender-coders