Skip to content

Commit 9475562

Browse files
committed
[OMCSessionZMQ] fix mypy error
1 parent 9e26765 commit 9475562

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

OMPython/OMCSession.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -794,8 +794,9 @@ def sendExpression(self, command: str, parsed: bool = True) -> Any:
794794
f"{log_message}")
795795
msg_long_list.append(msg_long)
796796
if has_error:
797+
msg_long_str = '\n'.join(f"{idx:02d}: {msg}" for idx, msg in enumerate(msg_long_list))
797798
raise OMCSessionException(f"OMC error occurred for 'sendExpression({command}, {parsed}):\n"
798-
f"{'\n'.join(f"{idx:2d}: {msg}" for idx, msg in enumerate(msg_long_list))}")
799+
f"{msg_long_str}")
799800

800801
if parsed is False:
801802
return result

0 commit comments

Comments
 (0)