Skip to content

Commit

Permalink
Replace characters with marker when there is a decoding error
Browse files Browse the repository at this point in the history
Signed-off-by: Jacob Perron <jacob@openrobotics.org>
  • Loading branch information
jacobperron committed Mar 15, 2019
1 parent 8f1ed68 commit 849824b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions launch/launch/actions/execute_process.py
Original file line number Diff line number Diff line change
Expand Up @@ -300,15 +300,15 @@ def __on_process_stdin(
def __on_process_stdout(
self, event: ProcessIO
) -> Optional[SomeActionsType]:
for line in event.text.decode().splitlines():
for line in event.text.decode(errors='replace').splitlines():
self.__stdout_logger.info(
self.__output_format.format(line=line, this=self)
)

def __on_process_stderr(
self, event: ProcessIO
) -> Optional[SomeActionsType]:
for line in event.text.decode().splitlines():
for line in event.text.decode(errors='replace').splitlines():
self.__stderr_logger.info(
self.__output_format.format(line=line, this=self)
)
Expand Down

0 comments on commit 849824b

Please sign in to comment.