It is not clear why shallow copy needs to be created to access some fields which are copied from the input object. Just use that object directly. Shallow copying is a weird and legacy concept, it should not be used without huge disclaimer why it is unavoidable in the new code. Pull Request: https://projects.blender.org/blender/blender/pulls/114791