|
.oO SearXNG Developer Documentation Oo.
|
Namespaces | |
| namespace | answerers |
| namespace | autocomplete |
| namespace | babel_extract |
| namespace | botdetection |
| namespace | cache |
| namespace | compat |
| namespace | data |
| namespace | enginelib |
| namespace | engines |
| ::1337x | |
| namespace | exceptions |
| namespace | extended_types |
| namespace | external_bang |
| namespace | external_urls |
| namespace | favicons |
| namespace | flaskfix |
| namespace | infopage |
| namespace | limiter |
| namespace | locales |
| namespace | metrics |
| namespace | network |
| namespace | openmetrics |
| namespace | plugins |
| namespace | preferences |
| namespace | query |
| namespace | result_types |
| namespace | results |
| namespace | search |
| namespace | settings_defaults |
| namespace | settings_loader |
| namespace | sqlitedb |
| namespace | sxng_locales |
| namespace | unixthreadname |
| namespace | utils |
| namespace | valkeydb |
| namespace | valkeylib |
| namespace | version |
| namespace | weather |
| namespace | webadapter |
| namespace | webapp |
| namespace | webutils |
| namespace | wikidata_units |
Functions | |
| init_settings () | |
| t.Any | get_setting (str name, t.Any default=_unset) |
| _is_color_terminal () | |
| _logging_config_debug () | |
Variables | |
| str | LOG_FORMAT_DEBUG = '%(levelname)-7s %(name)-30.30s: %(message)s' |
| str | LOG_FORMAT_PROD = '%(asctime)-15s %(levelname)s:%(name)s: %(message)s' |
| LOG_LEVEL_PROD = logging.WARNING | |
| str | searx_dir = abspath(dirname(__file__)) |
| str | searx_parent_dir = abspath(dirname(dirname(__file__))) |
| dict | settings = {} |
| bool | sxng_debug = False |
| logger = logging.getLogger('searx') | |
| _unset = object() | |
|
protected |
Definition at line 95 of file __init__.py.
Referenced by _logging_config_debug().
|
protected |
Definition at line 101 of file __init__.py.
References _is_color_terminal(), and init_settings().
Referenced by init_settings().
| t.Any searx.get_setting | ( | str | name, |
| t.Any | default = _unset ) |
Returns the value to which ``name`` point. If there is no such name in the settings and the ``default`` is unset, a :py:obj:`KeyError` is raised.
Definition at line 74 of file __init__.py.
Referenced by searx.favicons.proxy._initial_resolver_map(), searx.webapp.config(), searx.webapp.get_client_settings(), searx.plugins.oa_doi_rewrite.get_doi_resolver(), searx.search.processors.abstract.EngineProcessor.get_params(), searx.webutils.get_static_file_list(), searx.webutils.group_engines_in_tab(), searx.plugins.ahmia_filter.SXNGPlugin.init(), searx.webapp.init(), init_settings(), searx.plugins.initialize(), searx.valkeydb.initialize(), searx.favicons.is_active(), searx.webapp.preferences(), searx.network.raise_for_httperror.raise_for_cloudflare_captcha(), searx.network.raise_for_httperror.raise_for_recaptcha(), searx.webapp.render(), searx.webapp.run(), searx.valkeylib.secret_hash(), and searx.search.processors.abstract.SuspendedStatus.suspend().
| searx.init_settings | ( | ) |
Initialize global ``settings`` and ``sxng_debug`` variables and ``logger`` from ``SEARXNG_SETTINGS_PATH``.
Definition at line 32 of file __init__.py.
References _logging_config_debug(), and get_setting().
Referenced by _logging_config_debug().
|
protected |
Definition at line 29 of file __init__.py.
| str searx.LOG_FORMAT_DEBUG = '%(levelname)-7s %(name)-30.30s: %(message)s' |
Definition at line 15 of file __init__.py.
| str searx.LOG_FORMAT_PROD = '%(asctime)-15s %(levelname)s:%(name)s: %(message)s' |
Definition at line 18 of file __init__.py.
| searx.LOG_LEVEL_PROD = logging.WARNING |
Definition at line 19 of file __init__.py.
| searx.logger = logging.getLogger('searx') |
Definition at line 27 of file __init__.py.
| str searx.searx_dir = abspath(dirname(__file__)) |
Definition at line 21 of file __init__.py.
| str searx.searx_parent_dir = abspath(dirname(dirname(__file__))) |
Definition at line 22 of file __init__.py.
| dict searx.settings = {} |
Definition at line 24 of file __init__.py.
| bool searx.sxng_debug = False |
Definition at line 26 of file __init__.py.