Searx: http 429 Internal server error

Created on 10 Jul 2020  路  4Comments  路  Source: searx/searx

Just a fresh install on Ubuntu server 20-04
Gives after the installation guide a http 429 on http://ipadrres/searx
Searx in debug gave the following error in the searx.log

Fri Jul 10 16:07:15 2020 - * no app loaded. going in full dynamic mode
Traceback (most recent call last):
File "/usr/local/searx/searx-src/searx/webapp.py", line 74, in
from searx.search import SearchWithPlugins, get_search_query_from_webapp
File "/usr/local/searx/searx-src/searx/search.py", line 32, in
from searx.external_bang import get_bang_url
File "/usr/local/searx/searx-src/searx/external_bang.py", line 13, in
for bang in json.load(json_file)['bang']:
File "/usr/lib/python3.8/json/__init__.py", line 293, in load
return loads(fp.read(),
File "/usr/lib/python3.8/encodings/ascii.py", line 26, in decode
return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 31341: ordinal not in range(128)
Fri Jul 10 16:07:15 2020 - unable to load app 0 (mountpoint='') (callable not found or import error)
Fri Jul 10 16:07:15 2020 -
no app loaded. going in full dynamic mode *

doc installation

Most helpful comment

I have changed line12 external_bang.py

searx/searx/external_bang.py

Line 12 in 4829a76
with open(join(searx_dir, 'data/bangs.json')) as json_file:
with open(join(searx_dir, 'data/bangs.json'), encoding='utf-8') as json_file:

now it works fine thanks Dalf

All 4 comments

If i go back in time with git checkout c21220c6714475cdbf247eba4046ba735d9d402a 2July it works fine
When i do git checkout 4829a76aae8fa6af8d3f814ff780dc6e792b84e5 Created new plugin type custom_results. Added new plugin bang_redirect ( i got the internal server error looks something goes wrong with the bangs

I don't know how you installed your searx instance, but it is probably related to https://github.com/asciimoo/searx/pull/2043

LANG=C.UTF-8
LANGUAGE=C.UTF-8
LC_ALL=C.UTF-8

I have changed line12 external_bang.py

searx/searx/external_bang.py

Line 12 in 4829a76
with open(join(searx_dir, 'data/bangs.json')) as json_file:
with open(join(searx_dir, 'data/bangs.json'), encoding='utf-8') as json_file:

now it works fine thanks Dalf

I close the issue since the problem is solved.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

grravity picture grravity  路  4Comments

virtadpt picture virtadpt  路  3Comments

resynth1943 picture resynth1943  路  3Comments

aleferov picture aleferov  路  4Comments

Pofilo picture Pofilo  路  3Comments