Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Readability #550

Merged
merged 2 commits into from
Oct 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions moler/cmd/commandtextualgeneric.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ def __init__(
)
self.debug_data_received = False # Set True to log as hex all data received by command in data_received
self.re_fail = (
None # Regex to failure the command if it occurrs in the command output
None # Regex to failure the command if it occurs in the command output
)

if not self._newline_chars:
Expand Down Expand Up @@ -645,7 +645,7 @@ def failure_indiction(self, line: str, is_full_line: bool) -> None:
if self.is_failure_indication(line=line, is_full_line=is_full_line):
if self._is_failure_exception(line=line, is_full_line=is_full_line) is False:
self.set_exception(
CommandFailure(self, f"command failed in line '{line}'")
CommandFailure(self, f"command failed in the command output line '{line}'.")
)

def _is_failure_exception(self, line: str, is_full_line: bool) -> bool:
Expand Down
2 changes: 1 addition & 1 deletion moler/cmd/unix/iperf.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ def _command_failure(self, line):
if self._regex_helper.search_compiled(Iperf._re_command_failure, line):
self.set_exception(
CommandFailure(
self, f"ERROR: {self._regex_helper.group('FAILURE_MSG')}"
self, f"ERROR: found in command output: \"{self._regex_helper.group('FAILURE_MSG')}\""
)
)
raise ParsingDone
Expand Down
2 changes: 1 addition & 1 deletion moler/cmd/unix/iperf2.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ def _command_failure(self, line):
if self._regex_helper.search_compiled(Iperf2._re_command_failure, line):
self.set_exception(
CommandFailure(
self, f"ERROR: {self._regex_helper.group('FAILURE_MSG')}"
self, f"ERROR: found in command output: \"{self._regex_helper.group('FAILURE_MSG')}\""
)
)
raise ParsingDone
Expand Down
Loading