mirror of
https://github.com/GNS3/gns3-server
synced 2024-11-30 20:28:08 +00:00
Merge branch 'master' into 2.0
This commit is contained in:
commit
0c3a2c660a
@ -384,7 +384,8 @@ class ProjectHandler:
|
|||||||
response.content_length = None
|
response.content_length = None
|
||||||
response.start(request)
|
response.start(request)
|
||||||
|
|
||||||
for data in project.export(include_images=bool(request.GET.get("include_images", "0"))):
|
include_images = bool(int(request.json.get("include_images", "0")))
|
||||||
|
for data in project.export(include_images=include_images):
|
||||||
response.write(data)
|
response.write(data)
|
||||||
yield from response.drain()
|
yield from response.drain()
|
||||||
|
|
||||||
|
@ -91,7 +91,8 @@ def md5sum(path):
|
|||||||
try:
|
try:
|
||||||
with open(path + '.md5sum') as f:
|
with open(path + '.md5sum') as f:
|
||||||
return f.read()
|
return f.read()
|
||||||
except OSError:
|
# Unicode error is when user rename an image to .md5sum ....
|
||||||
|
except (OSError, UnicodeDecodeError):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
@ -17,12 +17,14 @@
|
|||||||
|
|
||||||
import sys
|
import sys
|
||||||
import json
|
import json
|
||||||
import jsonschema
|
import urllib
|
||||||
import asyncio
|
import asyncio
|
||||||
import aiohttp
|
import aiohttp
|
||||||
import logging
|
import logging
|
||||||
import urllib
|
import urllib
|
||||||
import traceback
|
import traceback
|
||||||
|
import jsonschema
|
||||||
|
|
||||||
|
|
||||||
log = logging.getLogger(__name__)
|
log = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user