ci/lava: Truncate printed times

We don't need to go down to the microsecond.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31602>
This commit is contained in:
Daniel Stone 2024-09-10 13:42:29 +01:00
parent 65f05f2231
commit 3068279280

View File

@ -304,7 +304,9 @@ def fix_lava_gitlab_section_log():
def print_log(msg: str, *args) -> None:
# Reset color from timestamp, since `msg` can tint the terminal color
print(f"{CONSOLE_LOG['RESET']}{datetime.now(tz=UTC)}: {msg}", *args)
ts = datetime.now(tz=UTC)
ts_str = f"{ts.hour:02}:{ts.minute:02}:{ts.second:02}.{int(ts.microsecond / 1000):03}"
print(f"{CONSOLE_LOG['RESET']}{ts_str}: {msg}", *args)
def fatal_err(msg, exception=None):