searxng_extra/update/¶
Scripts to update static data in git://searx/data/
update_ahmia_blacklist.py¶
This script saves Ahmia’s blacklist for onion sites.
Output file: git://searx/data/ahmia_blacklist.txt (CI Update data …).
update_currencies.py¶
Fetch currencies from git://searx/engines/wikidata.py engine.
Output file: git://searx/data/currencies.json (CI Update data …).
update_engine_descriptions.py¶
Fetch website description from websites and from git://searx/engines/wikidata.py engine.
Output file: git://searx/data/engine_descriptions.json.
- searxng_extra.update.update_engine_descriptions.get_output()[source]¶
- From descriptions[engine][language] = [description, source] To - output[language][engine] = description_and_source 
- description_and_source can be:
- [description, source] 
- description (if source = “wikipedia”) 
- [f”engine:lang”, “ref”] (reference to another existing description) 
 
 
 
update_external_bangs.py¶
Update git://searx/data/external_bangs.json using the duckduckgo bangs
from BANGS_URL.
- searxng_extra.update.update_external_bangs.BANGS_URL = 'https://duckduckgo.com/bang.js'¶
- JSON file which contains the bangs. 
- searxng_extra.update.update_external_bangs.merge_when_no_leaf(node)[source]¶
- Minimize the number of nodes - A -> B -> C- Bis child of- A
- Cis child of- B
 - If there are no - Cequals to- <LEAF_KEY>, then each- Care merged into- A. For example (5 nodes):- d -> d -> g -> <LEAF_KEY> (ddg) -> i -> g -> <LEAF_KEY> (dig) - becomes (3 nodes): - d -> dg -> <LEAF_KEY> -> ig -> <LEAF_KEY> 
update_firefox_version.py¶
Fetch firefox useragent signatures
Output file: git://searx/data/useragents.json (CI Update data …).
update_engine_traits.py¶
Update searx.enginelib.traits.EngineTraitsMap and git://searx/languages.py
- searx.enginelib.traits.EngineTraitsMap.ENGINE_TRAITS_FILE:
- Persistence of engines traits, fetched from the engines. 
- git://searx/languages.py
- Is generated from intersecting each engine’s supported traits. 
The script git://searxng_extra/update/update_engine_traits.py is called in the CI Update data …
- searxng_extra.update.update_engine_traits.fetch_traits_map()[source]¶
- Fetches supported languages for each engine and writes json file with those. 
- searxng_extra.update.update_engine_traits.filter_locales(traits_map: EngineTraitsMap)[source]¶
- Filter language & region tags by a threshold. 
- class searxng_extra.update.update_engine_traits.UnicodeEscape[source]¶
- Escape unicode string in - pprint.pformat
update_pygments.py¶
Update pygments style
Call this script after each upgrade of pygments
update_locales.py¶
Update locale names in git://searx/data/locales.json used by Locales
update_wikidata_units.py¶
Fetch units from git://searx/engines/wikidata.py engine.
Output file: git://searx/data/wikidata_units.json (CI Update data …).