summaryrefslogtreecommitdiff
path: root/searx/webapp.py
diff options
context:
space:
mode:
authorJinyuan Huang <88757735+BernieHuang2008@users.noreply.github.com>2023-10-05 14:42:14 +0000
committerMarkus Heiser <markus.heiser@darmarIT.de>2024-04-27 20:01:27 +0200
commitecee56533c318bd3ead0dfdaf74568836ccec12e (patch)
tree74496f7e3d2895c8a1bcdd9bcb86565adf0a5974 /searx/webapp.py
parent11fdc2f56ad7947de836dbe7e9b1b65dc6a8f33c (diff)
downloadsearxng-ecee56533c318bd3ead0dfdaf74568836ccec12e.tar.gz
searxng-ecee56533c318bd3ead0dfdaf74568836ccec12e.zip
improve "search existing issues from github" link
Diffstat (limited to 'searx/webapp.py')
-rwxr-xr-xsearx/webapp.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/searx/webapp.py b/searx/webapp.py
index a6cadcf6c..0901af8ea 100755
--- a/searx/webapp.py
+++ b/searx/webapp.py
@@ -1161,6 +1161,21 @@ def stats():
reliability_order = 1 - reliability_order
return (reliability_order, key, engine_stat['name'])
+ technical_report = []
+ for error in engine_reliabilities.get(selected_engine_name, {}).get('errors', []):
+ technical_report.append(
+ f"\
+ Error: {error['exception_classname'] or error['log_message']} \
+ Parameters: {error['log_parameters']} \
+ File name: {error['filename'] }:{ error['line_no'] } \
+ Error Function: {error['function']} \
+ Code: {error['code']} \
+ ".replace(
+ ' ' * 12, ''
+ ).strip()
+ )
+ technical_report = ' '.join(technical_report)
+
engine_stats['time'] = sorted(engine_stats['time'], reverse=reverse, key=get_key)
return render(
# fmt: off
@@ -1170,6 +1185,7 @@ def stats():
engine_reliabilities = engine_reliabilities,
selected_engine_name = selected_engine_name,
searx_git_branch = GIT_BRANCH,
+ technical_report = technical_report,
# fmt: on
)