Move to use copy.deepcopy