Skip to content

Commit 784a9c6

Browse files
committed
refactor: replace simulation tool SyntaxError with RuntimeError
The `SyntaxError` is meant for use by Python's parser. Though we are doing our own parsing logic here, it is typically used to suggest an error in some given Python source code, not a file in general. Signed-off-by: Alex Jones <alex.jones@lowrisc.org>
1 parent 95f8269 commit 784a9c6

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/dvsim/sim/tool/vcs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ def get_cov_summary_table(cov_report_path: Path) -> tuple[Sequence[Sequence[str]
5252

5353
# If we reached here, then we were unable to extract the coverage.
5454
msg = f"Coverage data not found in {cov_report_path}!"
55-
raise SyntaxError(msg)
55+
raise RuntimeError(msg)
5656

5757
@staticmethod
5858
def get_job_runtime(log_text: Sequence[str]) -> tuple[float, str]:

src/dvsim/sim/tool/xcelium.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ def get_cov_summary_table(cov_report_path: Path) -> tuple[Sequence[Sequence[str]
8080

8181
# If we reached here, then we were unable to extract the coverage.
8282
msg = f"Coverage data not found in {buf.name}!"
83-
raise SyntaxError(msg)
83+
raise RuntimeError(msg)
8484

8585
@staticmethod
8686
def get_job_runtime(log_text: Sequence[str]) -> tuple[float, str]:

0 commit comments

Comments
 (0)