user: How do I use GeometryAttributeConstraint(Constraint) in Blender? Include parameters, examples, warnings and best practices.

assistant: # GeometryAttributeConstraint(Constraint)

base classes — [`bpy_struct`](bpy.types.bpy_struct.html#bpy.types.bpy_struct "bpy.types.bpy_struct"), [`Constraint`](bpy.types.Constraint.html#bpy.types.Constraint "bpy.types.Constraint")

*class* bpy.types.GeometryAttributeConstraint(*Constraint*)
:   Create a constraint-based relationship with an attribute from geometry

    apply_target_transform
    :   Apply the target object’s world transform on top of the attribute’s transform

        Type:
        :   boolean, default False

    attribute_name
    :   Name of the attribute to retrieve the transform from

        Type:
        :   string, default “”, (never None)

    data_type
    :   Select data type of attribute

        - `VECTOR`
          Vector – Vector data type, affects position.
        - `QUATERNION`
          Quaternion – Quaternion data type, affects rotation.
        - `FLOAT4X4`
          4x4 Matrix – 4x4 Matrix data type, affects transform.

        Type:
        :   enum in [`'VECTOR'`, `'QUATERNION'`, `'FLOAT4X4'`], default `'VECTOR'`

    domain
    :   Attribute domain

        Type:
        :   enum in [`'POINT'`, `'EDGE'`, `'FACE'`, `'FACE_CORNER'`, `'CURVE'`, `'INSTANCE'`], default `'POINT'`

    mix_loc
    :   Mix Location

        Type:
        :   boolean, default False

    mix_mode
    :   Specify how the copied and existing transformations are combined

        - `REPLACE`
          Replace – Replace the original transformation with the transform from the attribute.
        - `BEFORE_FULL`
          Before Original (Full) – Apply copied transformation before original, using simple matrix multiplication as if the constraint target is a parent in Full Inherit Scale mode. Will create shear when combining rotation and non-uniform scale..
        - `BEFORE_SPLIT`
          Before Original (Split Channels) – Apply copied transformation before original, handling location, rotation and scale separately, similar to a sequence of three Copy constraints.
        - `AFTER_FULL`
          After Original (Full) – Apply copied transformation after original, using simple matrix multiplication as if the constraint target is a child in Full Inherit Scale mode. Will create shear when combining rotation and non-uniform scale..
        - `AFTER_SPLIT`
          After Original (Split Channels) – Apply copied transformation after original, handling location, rotation and scale separately, similar to a sequence of three Copy constraints.

        Type:
        :   enum in [`'REPLACE'`, `'BEFORE_FULL'`, `'BEFORE_SPLIT'`, `'AFTER_FULL'`, `'AFTER_SPLIT'`], default `'REPLACE'`

    mix_rot
    :   Mix Rotation

        Type:
        :   boolean, default False

    mix_scl
    :   Mix Scale

        Type:
        :   boolean, default False

    sample_index
    :   Sample Index

        Type:
        :   int in [0, inf], default 0

    target
    :   Target geometry object

        Type:
        :   [`Object`](bpy.types.Object.html#bpy.types.Object "bpy.types.Object")

    *classmethod* bl_rna_get_subclass(*id*, *default=None*, */*)
    :   Parameters:
        :   **id** (*str*) – The RNA type identifier.

        Returns:
        :   The RNA type or default when not found.

        Return type:
        :   [`bpy.types.Struct`](bpy.types.Struct.html#bpy.types.Struct "bpy.types.Struct") subclass

    *classmethod* bl_rna_get_subclass_py(*id*, *default=None*, */*)
    :   Parameters:
        :   **id** (*str*) – The RNA type identifier.

        Returns:
        :   The class or default when not found.

        Return type:
        :   type