Merge pull request #1084 from moon2l/master

fix bug: TypeError: set(['bing', 'google']) is not JSON serializable,…
This commit is contained in:
Adam Tauber 2017-11-15 14:51:14 +01:00 committed by GitHub
commit 5ceaf21399
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -541,7 +541,8 @@ def index():
'corrections': list(result_container.corrections),
'infoboxes': result_container.infoboxes,
'suggestions': list(result_container.suggestions),
'unresponsive_engines': list(result_container.unresponsive_engines)}),
'unresponsive_engines': list(result_container.unresponsive_engines)},
default=lambda item: list(item) if isinstance(item, set) else item),
mimetype='application/json')
elif output_format == 'csv':
csv = UnicodeWriter(StringIO())