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] image proxy: /image with the default network (#6816)
Brock Vojkovicb00212a83661
diff --git a/searx/network/network.py b/searx/network/network.pyindex f28f60194..76e6cc741 100644--- a/searx/network/network.py+++ b/searx/network/network.py@@ -409,14 +409,6 @@ def initialize(if isinstance(network, str):NETWORKS[engine_name] = NETWORKS[network]- # the /image_proxy endpoint has a dedicated network.- # same parameters than the default network, but HTTP/2 is disabled.- # It decreases the CPU load average, and the total time is more or less the same- if 'image_proxy' not in NETWORKS:- image_proxy_params = default_params.copy()- image_proxy_params['enable_http2'] = False- NETWORKS['image_proxy'] = new_network(image_proxy_params, logger_name='image_proxy')-@atexit.registerdef done():diff --git a/searx/webapp.py b/searx/webapp.pyindex bbb4b1540..38c2564e7 100755--- a/searx/webapp.py+++ b/searx/webapp.py@@ -117,7 +117,7 @@ from searx import faviconsfrom searx.valkeydb import initialize as valkey_initializefrom searx.sxng_locales import sxng_localesimport searx.search-from searx.network import stream as http_stream, set_context_network_name+from searx.network import stream as http_streamlogger = logger.getChild('webapp')@@ -1012,7 +1012,7 @@ def preferences():app.add_url_rule('/favicon_proxy', methods=['GET'], endpoint="favicon_proxy", view_func=favicons.favicon_proxy)[email protected]('/image_proxy', methods=['GET'])[email protected]('/image', methods=['GET'])def image_proxy():# pylint: disable=too-many-return-statements, too-many-branches@@ -1033,7 +1033,6 @@ def image_proxy():'Sec-GPC': '1','DNT': '1',}- set_context_network_name('image_proxy')resp, stream = http_stream(method='GET', url=url, headers=request_headers, allow_redirects=True)content_length = resp.headers.get('Content-Length')if content_length and content_length.isdigit() and int(content_length) > maximum_size:@@ -1198,7 +1197,7 @@ def robots():"""User-agent: *Allow: /info/en/aboutDisallow: /stats-Disallow: /image_proxy+Disallow: /imageDisallow: /preferencesDisallow: /*?*q=*""",