diff --git a/reframe/frontend/printer.py b/reframe/frontend/printer.py index be71c6d089..a986646869 100644 --- a/reframe/frontend/printer.py +++ b/reframe/frontend/printer.py @@ -3,8 +3,7 @@ # # SPDX-License-Identifier: BSD-3-Clause -import datetime - +import time import reframe.core.logging as logging import reframe.utility.color as color @@ -68,7 +67,7 @@ def status(self, status, message='', just=None, level=logging.INFO): logging.getlogger().log(level, final_msg) def timestamp(self, msg='', separator=None): - msg = '%s %s' % (msg, datetime.datetime.today().strftime('%c %Z')) + msg = f'{msg} {time.strftime("%c%z")}' if separator: self.separator(separator, msg) else: