SearXNG is a free internet metasearch engine which aggregates results from various search services and databases. Users are neither tracked nor profiled.
Python bingbravedegoogleduckduckgogooglemetasearchprivacypythonqwantsearchsearch-enginesearxsearxngstartpageyahoo
[mod] qwant engine: fix typos / minor change
Alexandre Flament0d65a81b1c31
diff --git a/searx/engines/qwant.py b/searx/engines/qwant.pyindex 00b30f4dc..97e461177 100644--- a/searx/engines/qwant.py+++ b/searx/engines/qwant.py@@ -31,12 +31,10 @@ from json import loadsfrom urllib.parse import urlencodefrom flask_babel import gettext-# from searx import loggerfrom searx.utils import match_languagefrom searx.exceptions import SearxEngineAPIExceptionfrom searx.network import raise_for_httperror-#logger = logger.getChild('qwant')# aboutabout = {@@ -182,19 +180,18 @@ def response(resp):})elif mainline_type == 'videos':- # some videos do not have a description: while quant-video- # returns an empty string, such video from a quant-web query+ # some videos do not have a description: while qwant-video+ # returns an empty string, such video from a qwant-web query# miss the 'desc' key.- content = item.get('desc', '')- s, c = item.get('source',''), item.get('channel','')- if content and (s or c):- content += " // "+ d, s, c = item.get('desc'), item.get('source'), item.get('channel')+ content_parts = []+ if d:+ content_parts.append(d)if s:- content += "%s: %s " % (gettext("Source"), s)- if c:- content += "//"+ content_parts.append("%s: %s " % (gettext("Source"), s))if c:- content += " %s: %s " % (gettext("Channel"), c)+ content_parts.append("%s: %s " % (gettext("Channel"), c))+ content = ' // '.join(content_parts)length = timedelta(seconds=item['duration'])pub_date = datetime.fromtimestamp(item['date'])thumbnail = item['thumbnail']