From 2e376f219596e31ee985be9185248cca0b635070 Mon Sep 17 00:00:00 2001 From: Pearl Dsilva Date: Tue, 13 Jul 2021 07:22:47 +0530 Subject: [PATCH] marvin: make deployDataCenter.py script py2/py3 compatible (#5139) --- tools/marvin/marvin/deployDataCenter.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/marvin/marvin/deployDataCenter.py b/tools/marvin/marvin/deployDataCenter.py index c3e8511141f..868768982f7 100644 --- a/tools/marvin/marvin/deployDataCenter.py +++ b/tools/marvin/marvin/deployDataCenter.py @@ -71,9 +71,9 @@ class DeployDataCenters(object): ts = strftime("%b_%d_%Y_%H_%M_%S", localtime()) dc_file_path = "dc_entries_" + str(ts) + ".obj" - file_to_write = open(dc_file_path, 'w') + file_to_write = open(dc_file_path, 'wb') if file_to_write: - pickle.dump(self.__cleanUp, file_to_write) + pickle.dump(self.__cleanUp, file_to_write, protocol=0) print("\n=== Data Center Settings are dumped to %s===" % dc_file_path) self.__tcRunLogger.debug("\n=== Data Center Settings are dumped to %s===" % dc_file_path) except Exception as e: