def METHOD_NAME(self, stderr):
    while self._proc.poll() is None:
        line = stderr.readline()
        if line:
            self._err_message.append(line)
    with contextlib.suppress(Exception):
        self._err_message.extend(stderr.readlines())