mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 05:51:15 +02:00
Controller side unique node name allocation. Ref #541.
This commit is contained in:
1 parent
6cd136b423
commit
2bde02d459
11 files changed
+128
-47
No files matched your search
@@ -332,7 +332,7 @@ class Compute:
|
||||
if body:
|
||||
try:
|
||||
msg = json.loads(body)["message"]
|
||||
except (KeyError, json.decoder.JSONDecodeError):
|
||||
except (KeyError, ValueError):
|
||||
msg = body
|
||||
else:
|
||||
msg = ""
|
||||
@@ -349,7 +349,7 @@ class Compute:
|
||||
try:
|
||||
raise ComputeConflict(json.loads(body))
|
||||
# If the 409 doesn't come from a GNS3 server
|
||||
except json.decoder.JSONDecodeError:
|
||||
except ValueError:
|
||||
raise aiohttp.web.HTTPConflict(text=msg)
|
||||
elif response.status == 500:
|
||||
raise aiohttp.web.HTTPInternalServerError(text="Internal server error {}".format(url))
|
||||
|
||||
Reference in new issue
Block a user