In some situations, the Rally API returns the following error when trying to update a work item:
Could not update: Could not write changes in Unit Of Work
This error can be cause if the action being taken might orphan a record that has a parent requirement.
As an example of this, a ChangeSet object can have Changes as children. These Change objects have a required parent field. If the action is trying to clear the Changes object from the ChangeSet object, it would orphan the Changes, which isn't allowed.
In this situation, you would need to delete or reassign the child object(s) individually as opposed to trying to clear them from the parent object.