expect a broken pipe

This commit is contained in:
Jakob Ketterl 2021-09-30 23:04:59 +02:00
parent 0b64b4ac97
commit 1e57fb4609

View File

@ -37,6 +37,8 @@ class Module(BaseModule, metaclass=ABCMeta):
data = read() data = read()
except ValueError: except ValueError:
pass pass
except BrokenPipeError:
break
if data is None or isinstance(data, bytes) and len(data) == 0: if data is None or isinstance(data, bytes) and len(data) == 0:
break break
write(data) write(data)