Commit Graph

41 Commits (master)

Author SHA1 Message Date
Markus Heiser 8df1f0c47e [mod] add 'Accept-Language' HTTP header to online processores
Most engines that support languages (and regions) use the Accept-Language from
the WEB browser to build a response that fits to the language (and region).

- add new engine option: send_accept_language_header

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2 years ago
Martin Fischer b02f762687 [enh] add more categories 2 years ago
Markus Heiser dc4f1f705d [pylint] Bing (Images) engine
Fix remarks from pylint and remove obsolete try/except block

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2 years ago
Markus Heiser d84226bf63 [fix] issues reported by pylint
Fix pylint issues from commit (3d96a983)

    [format.python] initial formatting of the python code

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2 years ago
Markus Heiser 3d96a9839a [format.python] initial formatting of the python code
This patch was generated by black [1]::

    make format.python

[1] https://github.com/psf/black

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2 years ago
Noémi Ványi 1be6ab2a91 Fix paging of Bing Images 3 years ago
Alexandre Flament ca93a01844 [mod] dynamically set language_support variable
The language_support variable is set to True by default,
and set to False in only 5 engines.

Except the documentation and the /config URL, this variable is not used.

This commit remove the variable definition in the engines, and
set value according to supported_languages length: False when the length is 0,
True otherwise.

Close #2485
3 years ago
Alexandre Flament a4dcfa025c [enh] engines: add about variable
move meta information from comment to the about variable
so the preferences, the documentation can show these information
3 years ago
Alexandre Flament b00d108673 [mod] pylint: numerous minor code fixes 4 years ago
Alexandre Flament 3038052c79 [mod] remove unused import
use
from searx.engines.duckduckgo import _fetch_supported_languages, supported_languages_url  # NOQA
so it is possible to easily remove all unused import using autoflake:
autoflake --in-place --recursive --remove-all-unused-imports searx tests
4 years ago
Dalf 1022228d95 Drop Python 2 (1/n): remove unicode string and url_utils 4 years ago
Adam Tauber 6ded6e7a9a [fix] skip uncomplete image results - closes #1496 4 years ago
Markus Heiser e0c99d9dcb bugfix: fetch_supported_languages bing, -news, -videos, -images
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
4 years ago
Frank de Lange 11fc9913e9 [enh] bing_images: use data from embedded JSON to improve results (e.g. real page title) (#1568)
use data from embedded JSON to improve results (e.g. real page title), add image format and source info (see PR #1567), improve paging logic (it now works)
5 years ago
Marc Abonce Seguin 5568f24d6c [fix] check language aliases when setting search language 6 years ago
Léo Bourrel 73ec2ba74e Update bing image engine with new image json format 6 years ago
Marc Abonce Seguin 772c048d01 refactor engine's search language handling
Add match_language function in utils to match any user given
language code with a list of engine's supported languages.

Also add language_aliases dict on each engine to translate
standard language codes into the custom codes used by the engine.
6 years ago
marc a524dbb823 [fix] language support for bing images and videos 7 years ago
marc 9ee8e552da [fix] bing images 7 years ago
Adam Tauber 52e615dede [enh] py3 compatibility 7 years ago
marc af35eee10b tests for _fetch_supported_languages in engines
and refactor method to make it testable without making requests
8 years ago
marc f62ce21f50 [mod] fetch supported languages for several engines
utils/fetch_languages.py gets languages supported by each engine and
generates engines_languages.json with each engine's supported language.
8 years ago
marc 149802c569 [enh] add supported_languages on engines and auto-generate languages.py 8 years ago
Noémi Ványi c59c76e6ee add year to time range to engines which support "Last year"
Engines:
 * Bing images
 * Flickr (noapi)
 * Google
 * Google Images
 * Google News
8 years ago
Noémi Ványi 5c02b9ef31 add time range support for bing images 8 years ago
Adam Tauber 71de593a5b [fix] bing images page change 8 years ago
Adam Tauber ebbf33343a [fix] bing images changes 8 years ago
Adam Tauber 604f32f672 [fix] bing unicode encode error - fixes #408 9 years ago
Dalf 9e147d91f0 bing_images & www1x engines use https connections 9 years ago
Alexandre Flament 4689fe341c update versions.cfg to use the current up-to-date packages 9 years ago
Alexandre Flament 043b269c6e [fix] tests 9 years ago
Alexandre Flament 99efd790c8 engines: use https when possible 9 years ago
Thomas Pointhuber 832ea60e3d [fix] pep8, tests 9 years ago
Thomas Pointhuber e7de9674b1 [enh] add safesearch functionality
2 = strict
1 = moderate
0 = none
9 years ago
Cqoicebordel dad0434f34 Bing images' unit test 9 years ago
Cqoicebordel 4238812a51 Flake8 10 years ago
Cqoicebordel cb4a3fe598 Add thumbnails in images results
- Modify engines to create/fetch an URL for the thumbnails
- Modify themes to show thumbnails instead of full images.

In Courgette, the result is not very beautiful. Should we change it ?
10 years ago
dalf 7c13d630e4 [fix] pep8 : engines (errors E121, E127, E128 and E501 still exist) 10 years ago
Adam Tauber 46e3e1a390 [fix] print removed 10 years ago
Thomas Pointhuber 3d61d9b930 little refactoring 10 years ago
Thomas Pointhuber cdf74fe563 add bing_images 10 years ago