Skip to content

Commit 0f83aa6

Browse files
changed error message format (moved newlines for better readability.)
1 parent 24e2457 commit 0f83aa6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

exir/verification/verifier.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -192,11 +192,11 @@ def _check_tensor_args_matching_op_allowed_dtype(gm: GraphModule) -> None:
192192
error_msg = ""
193193
for op, node in validator.violating_ops.items():
194194
# error_msg += f"#####################################################\n"
195-
error_msg += f"Operator: {op} with args: {node[0]}\n"
196-
error_msg += f"stack trace: {node[1].stack_trace}\n\n"
195+
error_msg += f"\nOperator: {op} with args: {node[0]}\n"
196+
error_msg += f"stack trace: {node[1].stack_trace}\n"
197197
# error_msg += f"#####################################################\n"
198198
raise SpecViolationError(
199-
f"These operators are taking Tensor inputs with mismatched dtypes:\n{error_msg}\n"
199+
f"These operators are taking Tensor inputs with mismatched dtypes:\n{error_msg}"
200200
"Please make sure the dtypes of the Tensor inputs are the same as the dtypes of the corresponding outputs."
201201
)
202202

0 commit comments

Comments
 (0)