mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 14:01:15 +02:00
Python3.8 support. Ref https://github.com/GNS3/gns3-gui/issues/2895
This commit is contained in:
1 parent
2fd4b2cbc8
commit
a98fc2d308
6 files changed
+10
-9
No files matched your search
@@ -20,13 +20,10 @@ import json
|
||||
import urllib
|
||||
import asyncio
|
||||
import aiohttp
|
||||
import logging
|
||||
import traceback
|
||||
import jsonschema
|
||||
import jsonschema.exceptions
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
from ..compute.error import NodeError, ImageMissingError
|
||||
from ..controller.controller_error import ControllerError
|
||||
from ..ubridge.ubridge_error import UbridgeError
|
||||
@@ -36,6 +33,10 @@ from ..crash_report import CrashReport
|
||||
from ..config import Config
|
||||
|
||||
|
||||
import logging
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
|
||||
async def parse_request(request, input_schema, raw):
|
||||
"""Parse body of request and raise HTTP errors in case of problems"""
|
||||
|
||||
@@ -217,7 +218,7 @@ class Route(object):
|
||||
response = Response(request=request, route=route)
|
||||
response.set_status(409)
|
||||
response.json({"message": str(e), "status": 409, "image": e.image, "exception": e.__class__.__name__})
|
||||
except asyncio.futures.CancelledError:
|
||||
except asyncio.CancelledError:
|
||||
response = Response(request=request, route=route)
|
||||
response.set_status(408)
|
||||
response.json({"message": "Request canceled", "status": 408})
|
||||
|
||||
Reference in new issue
Block a user