Am 02.06.2020 um 23:45 hat John Snow geschrieben: > If the timeout is 0, we can get None back. Handle this explicitly. > > Signed-off-by: John Snow <js...@redhat.com>
Subject line: This is events_wait(), not event_wait(). Both functions exist. > @@ -562,6 +564,8 @@ def _match(event): > # Poll for new events > while True: > event = self._qmp.pull_event(wait=timeout) > + if event is None: > + break > if _match(event): > return event > self._events.append(event) Hm... How could this ever work? I guess we just never really tested whether timeouts actually time out? (It's still somewhat unintuitive that receiving an unrelated event resets the timeout, but not the problem of this series...) Kevin