Attribute values discarded when changing an object's label (regression since v2.68.0, PR #10715)
Actions before raising this issue
- I searched the existing issues and did not find anything similar.
- I read/searched the docs
Steps to Reproduce
Root cause: the attribute-carryover block in saveLabel was removed in PR #10715 (2026-06-04). Last release with it: v2.67.0. First without: v2.68.0.
- Create a task with two labels, A and B, each with an identical attribute spec (same name, same input_type, same values).
- Draw a polygon with label A and set the attribute to a valid value.
- Change the object's label from A to B.
- Observe the attribute has reset to the label's default / blank.
Expected Behavior
The attribute value should carry over, since label B has an attribute with the same name and the existing value is still valid for it.
Possible Solution
This looks like an unintended removal during the annotation model refactor. saveLabel used to contain a carryover block:
Before (v2.67.0): https://github.com/cvat-ai/cvat/blob/e030d924fc00647b7d0e9376e3cccdaf52991b88/cvat-core/src/annotations-objects.ts#L239-L249
That loop is absent from the current implementation, which now does:
It was removed in PR #10715 ("Refactor cvat-core annotation object models", 2026-06-04). PR #10712, which split annotations-objects.ts into per-shape modules earlier the same day, still contained it. First tagged release with the removal: v2.68.0. Last release with the behavior intact: v2.67.0. The behavior itself dates back to PR #3309.
Context
This causes silent data loss during relabeling.
Environment
Reproduces on CVAT Online.Source: cvat-ai/cvat