In the past, some files were tested with the standard profile, others with a
profile in which most of the messages were switched off ... some files were not
checked at all.
- ``PYLINT_SEARXNG_DISABLE_OPTION`` has been abolished
- the distinction ``# lint: pylint`` is no longer necessary
- the pylint tasks have been reduced from three to two
1. ./searx/engines -> lint engines with additional builtins
2. ./searx ./searxng_extra ./tests -> lint all other python files
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
To improve modularization this patch:
- moves *locale* related implementation from the webapp.py application to the
locale.py module.
- The initialization of the locales is now done in the application (webapp) and
is no longer done while importing searx.locales.
In the searx.locales module a new dictionary named `LOCALE_BEST_MATCH` has been
added. In this dictionary we can map languages without a translation to
languages we have a translation for.
To fix#1303 zh-HK has been mapped to zh-Hant-TW (we do not need additional
translations of traditional Chinese)
Closes: https://github.com/searxng/searxng/issues/1303
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
The previous implementation used two hash sets and a list.
... that's not necessary ... a single hash map suffices.
And it's also less error prone ... because the previous data structure
allowed a setting to be enabled and disabled at the same time.