From b2a1e565ddc836ac762da1fe988be2eb123653d0 Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Fri, 19 Aug 2022 17:58:37 +0200 Subject: [PATCH] [fix] engine duden - don't raise exception on empty result list Duden expects a word in German, so with query "amazing" the site finds nothing and respons a 404: httpx.HTTPStatusError: Client error '404 Not Found' for url\ 'https://www.duden.de/suchen/dudenonline/amazing' [1] https://github.com/searxng/searxng/issues/1543#issuecomment-1193317054 Suggested-by: @allendema [1] Signed-off-by: Markus Heiser --- searx/engines/duden.py | 1 + 1 file changed, 1 insertion(+) diff --git a/searx/engines/duden.py b/searx/engines/duden.py index da4c4f7da49..f6ab5befaf9 100644 --- a/searx/engines/duden.py +++ b/searx/engines/duden.py @@ -47,6 +47,7 @@ def request(query, params): # after the last page of results, spelling corrections are returned after a HTTP redirect # whatever the page number is params['soft_max_redirects'] = 1 + params['raise_for_httperror'] = False return params