implementation mismatch in bmesh python #38150
Labels
No Label
Interest
Animation & Rigging
Interest
Blender Cloud
Interest
Collada
Interest
Core
Interest
Documentation
Interest
Eevee & Viewport
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
Import and Export
Interest
Modeling
Interest
Modifiers
Interest
Nodes & Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds, Tests & Devices
Interest
Python API
Interest
Rendering & Cycles
Interest
Sculpt, Paint & Texture
Interest
Translations
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Meta
Good First Issue
Meta
Papercut
Module
Add-ons (BF-Blender)
Module
Add-ons (Community)
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
7 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender-addons#38150
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
System Information
windows 8.1 64bit,
Blender Version
Broken: all (2.65, 2.67, 2.69, blender-2.69-18a1e17-win64-vc12.zip)
Short description of error
there are names of methods flipped
e.g.
bmesh.types.BMLayerCollection.items() gives values of the collection
and
bmesh.types.BMLayerCollection.values() gives key-value-tuples of the collection
Exact steps for others to reproduce the error
when i call items(), i get description and result of values():
when i call values(), i get description and result of items():
issue_-_implementation_mismatch_in_bmesh.blend
Changed status to: 'Open'
Added subscriber: @beta-tester
This issue was referenced by blender/blender-addons-contrib@ee15db9db5
This issue was referenced by blender/blender@ee15db9db5
Changed status from 'Open' to: 'Resolved'
Closed by commit blender/blender@ee15db9db5.
Changed status from 'Resolved' to: 'Open'
the doc part is now corrected with the last commit,
BUT still the functionallitiy is incorrect!
items() gives me as result a list of values. but i expect a list of key-value pairs as result, like when i call dict.items()
in values() gives me as result a list of key-value pairs, expect is a list of values as result, like dict.values()
it looks like all BMLayerCollection shows the same behavior maybe the link from C/CPP-method to Python-method is swapped
BTW: BMesh.verts.layers.bevel_weight, i did not find a way how to create that layer in the UI.
further, i found out, that the doc of bmesh.types.BMDeformVert is swapped too, but the functionality of the method items() and values() behind is ok.
maybe there are more missmatches in BMesh to review...
issue_-_implementation_mismatch_in_bmesh_v1.blend
This issue was referenced by blender/blender-addons-contrib@c2508b6e1b
This issue was referenced by blender/blender@c2508b6e1b
Changed status from 'Open' to: 'Resolved'
Closed by commit blender/blender@c2508b6e1b.
Changed status from 'Resolved' to: 'Open'
no, not fully fixed yet, "the doc of bmesh.types.BMDeformVert is swapped too" issue is still present.
bmesh.types.BMDeformVert.items.doc shows doc of values()
bmesh.types.BMDeformVert.values.doc shows doc of items()
Added subscriber: @ThomasDinges
Added subscriber: @Sergey
This issue was referenced by blender/blender-addons-contrib@18db6c58ec
This issue was referenced by blender/blender@18db6c58ec
Changed status from 'Open' to: 'Resolved'
Closed by commit blender/blender@18db6c58ec.
i scare about to tell you, but i think there was a mistake in that commit blender/blender@18db6c58ec (by accident, a good code line was turning to a bad one)
[blender.git] / source / blender / python / bmesh / bmesh_py_types.c
1387: PyDoc_STRVAR(bpy_bmvert_calc_edgeangle_doc,
1388: -".. method:: calcedgeangle()\n"
1388: +".. method:: calcvert_angle()\n"
Changed status from 'Resolved' to: 'Open'
i get more and more confused with this report...
on the API reference page of 2.69.10
http://www.blender.org/documentation/blender_python_api_2_69_10/bmesh.types.html?highlight=calc_edge_angle#bmesh.types.BMVert.calc_edge_angle
the function is called "calc_edge_angle".
in blender itself, i get this (i tested now with 'blender-2.69-97aab5a-win64-vc12.zip'):
with "print(dir(bmv))"
[..., 'calc_shell_factor', 'calc_vert_angle', 'co', 'copy_from', 'copy_from_face_interp', 'copy_from_vert_interp', 'hide', 'hide_set', 'index', 'is_boundary', 'is_manifold', 'is_valid', 'is_wire', 'link_edges', 'link_faces', 'link_loops', 'normal', 'normal_update', 'select', 'select_set', 'tag']
(no such function is available, but calc_vert_angle)
and "print(bmv.calc_vert_angle.doc)" gives me:
what is the correct name/doc/functionality now - 'calc_edge_angle' or 'calc_vert_angle' ?
sorry, that i am such a pendant smart-ass - it is not my intention to waste so much developing time of you - really.
issue_-_implementation_mismatch_in_bmesh_v2.blend
Changed status from 'Open' to: 'Resolved'
Added subscriber: @brecht
It's
calc_vert_angle
, the python API docs are just outdated, they are updated regularly but not every day.