Fixing deepcopy to be a copy so module references don't break comparison