Page MenuHome

UILayout: prop_search() broken
Closed, ResolvedPublicBUG

Description

System Information
Operating system: Windows-10-10.0.18362-SP0 64 Bits
Graphics card: GeForce GTX 1080/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 441.66

Blender Version
Broken: version: 2.90 (sub 0), branch: master, commit date: 2020-05-10 13:42, hash: rB51ac411ce80c
Worked: 2.82a

Short description of error
Python UILayout.prop_search() is broken. Property values are marked as invalid despite existing within the searched list.
Blend file:


Exact steps for others to reproduce the error
Open the Blend file and run the script.
Go to the 3D view->Panels (N)->BUG. Note the property is highlighted red.
Use the UI to select "Text" instead.
The property is no longer red, but it's wrong now. The property has been set to " Text".

Event Timeline

I found a simple workaround. Just make the custom property a PointerProperty of the desired type then use prop() instead of prop_search().

Julian Eisel (Severin) changed the task status from Needs Triage to Confirmed.May 11 2020, 5:08 PM
Julian Eisel (Severin) triaged this task as High priority.
Julian Eisel (Severin) changed the subtype of this task from "Report" to "Bug".
Julian Eisel (Severin) edited projects, added BF Blender (2.83); removed BF Blender.