Currently, array properties that don't match any of the mathutils types are represented as typing.List. However the true type is bpy_prop_array[T] | typing.Sequence[T], where bpy_prop_array is a generic wrapper for a C array, similar to existing bpy_prop_collection, and implementing a sequence interface. The documentation declares the type to be 'list of', because it is intended to appear to behave as such, but it is not technically correct: Blender native structures simply cannot have a property that is truly a native list.
The suggested type also includes Sequence directly, because similar to mathutils types (see #124), such fields implicitly cast from native Python sequence types, like list or tuple, when they are assigned a value.
bpy_prop_array appears to have the following attributes: __bool__, __contains__, __delitem__, __doc__, __getattribute__, __getitem__, __iter__, __len__, __repr__, __setitem__, foreach_get, foreach_set (but some like __delitem__ look like they may be dummies that error out).
Currently, array properties that don't match any of the mathutils types are represented as
typing.List
. However the true type isbpy_prop_array[T] | typing.Sequence[T]
, wherebpy_prop_array
is a generic wrapper for a C array, similar to existingbpy_prop_collection
, and implementing a sequence interface. The documentation declares the type to be 'list of', because it is intended to appear to behave as such, but it is not technically correct: Blender native structures simply cannot have a property that is truly a nativelist
.The suggested type also includes
Sequence
directly, because similar to mathutils types (see #124), such fields implicitly cast from native Python sequence types, like list or tuple, when they are assigned a value.bpy_prop_array
appears to have the following attributes:__bool__
,__contains__
,__delitem__
,__doc__
,__getattribute__
,__getitem__
,__iter__
,__len__
,__repr__
,__setitem__
,foreach_get
,foreach_set
(but some like__delitem__
look like they may be dummies that error out).