diff options
author | Devaev Maxim <[email protected]> | 2020-05-11 08:06:44 +0300 |
---|---|---|
committer | Devaev Maxim <[email protected]> | 2020-05-11 08:06:44 +0300 |
commit | 98a176f7408350741f89547ea6d1d6e519965cbf (patch) | |
tree | 872a8f1c288975c118e0384e44973c944ea5b1f2 /kvmd/apps/vnc/streamer.py | |
parent | 60b6c219d91addfd79a30cfa9c20b398eb3391ae (diff) |
lint fixes
Diffstat (limited to 'kvmd/apps/vnc/streamer.py')
-rw-r--r-- | kvmd/apps/vnc/streamer.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/kvmd/apps/vnc/streamer.py b/kvmd/apps/vnc/streamer.py index 62fce849..fd2232ee 100644 --- a/kvmd/apps/vnc/streamer.py +++ b/kvmd/apps/vnc/streamer.py @@ -61,7 +61,9 @@ class StreamerClient: response.raise_for_status() reader = aiohttp.MultipartReader.from_response(response) while True: - frame = await reader.next() + frame = await reader.next() # pylint: disable=not-callable + if not isinstance(frame, aiohttp.BodyPartReader): + raise RuntimeError("Expected body part") yield ( (frame.headers["X-UStreamer-Online"] == "true"), int(frame.headers["X-UStreamer-Width"]), |