Explicitly set the serializer for MemoryDiff and MemoryPatch