1
0
mirror of https://github.com/GNS3/gns3-server synced 2024-11-28 11:18:11 +00:00

Catch KeyError: <aiohttp.connector._TransportPlaceholder

Fix #1152
This commit is contained in:
Julien Duponchelle 2017-08-02 10:16:49 +02:00
parent e74eaa8ea8
commit 3bb8cdafb2
No known key found for this signature in database
GPG Key ID: CE8B29639E07F5E8

View File

@ -499,7 +499,7 @@ class Compute:
response = yield from self._session().request(method, url, headers=headers, data=data, auth=self._auth, chunked=chunked, timeout=timeout)
except asyncio.TimeoutError as e:
raise ComputeError("Timeout error when connecting to {}".format(url))
except (aiohttp.ClientError, aiohttp.ServerDisconnectedError, ValueError) as e:
except (aiohttp.ClientError, aiohttp.ServerDisconnectedError, ValueError, KeyError) as e:
raise ComputeError(str(e))
body = yield from response.read()
if body and not raw: