diff --git a/read2tree/Mapper.py b/read2tree/Mapper.py index f46baff..ea7b372 100644 --- a/read2tree/Mapper.py +++ b/read2tree/Mapper.py @@ -638,8 +638,10 @@ def _output_shell(self, line): return None (output, err) = shell_command.communicate() - self.logger.debug("Shell output: "+ str(output)) - self.logger.debug("Shell err: " + str(err)) + if output: + self.logger.debug("Shell output: "+ str(output)) + if err: + self.logger.debug("Shell err: " + str(err)) shell_command.wait() if shell_command.returncode != 0: