From 3612485a874b352fac8f1bd82a0c1180eb35f560 Mon Sep 17 00:00:00 2001 From: Kareem Farid Date: Mon, 18 Nov 2024 11:46:37 +0200 Subject: [PATCH] update creating a yaml file from a sort of yaml Signed-off-by: Kareem Farid --- openlane/steps/openroad.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/openlane/steps/openroad.py b/openlane/steps/openroad.py index a358145e0..43fbe1da2 100644 --- a/openlane/steps/openroad.py +++ b/openlane/steps/openroad.py @@ -15,6 +15,7 @@ import os import re import json +import textwrap import tempfile import functools import subprocess @@ -1128,9 +1129,9 @@ def get_psm_error_count(rpt: io.TextIOWrapper) -> int: vio_type = line[len(VIO_TYPE_PFX) :].strip() sio.write(f"- type: {vio_type}\n") elif "bbox = " in line: - sio.write(line.replace("bbox = ", "- bbox =")) + sio.write(f" {textwrap.dedent(line.replace('bbox = ', '- bbox ='))}") else: - sio.write(line) + sio.write(f" {textwrap.dedent(line)}") sio.seek(0) violations = yaml.load(sio, Loader=yaml.SafeLoader) or []