diff --git a/searx/engines/yandex.py b/searx/engines/yandex.py index 938fdd18..b83a747f 100644 --- a/searx/engines/yandex.py +++ b/searx/engines/yandex.py @@ -29,10 +29,10 @@ language_map = {'ru': 'ru', base_url = 'https://yandex.{tld}/' search_url = 'search/?{query}&p={page}' -results_xpath = '//div[@class="serp-item serp-item_plain_yes clearfix i-bem"]' +results_xpath = '//li[@class="serp-item"]' url_xpath = './/h2/a/@href' title_xpath = './/h2/a//text()' -content_xpath = './/div[@class="serp-item__text"]//text()' +content_xpath = './/div[@class="text-container typo typo_text_m typo_line_m organic__text"]//text()' def request(query, params): diff --git a/searx/settings.yml b/searx/settings.yml index ef703fba..eee2903b 100644 --- a/searx/settings.yml +++ b/searx/settings.yml @@ -192,6 +192,7 @@ engines: - name : gigablast engine : gigablast shortcut : gb + timeout : 3.0 disabled: True - name : gitlab @@ -250,8 +251,8 @@ engines: engine : xpath search_url : https://play.google.com/store/search?q={query}&c=movies url_xpath : //a[@class="title"]/@href - title_xpath : //a[@class="title"] - content_xpath : //a[@class="subtitle"] + title_xpath : //a[@class="title"]/@title + content_xpath : //a[contains(@class, "subtitle")] categories : videos shortcut : gpm disabled : True @@ -282,8 +283,8 @@ engines: engine : xpath paging : True search_url : https://habrahabr.ru/search/page{pageno}/?q={query} - url_xpath : //div[@class="search_results"]//a[@class="post_title"]/@href - title_xpath : //div[@class="search_results"]//a[@class="post_title"] + url_xpath : //div[@class="search_results"]//a[contains(@class, "post__title_link")]/@href + title_xpath : //div[@class="search_results"]//a[contains(@class, "post__title_link")] content_xpath : //div[@class="search_results"]//div[contains(@class, "content")] categories : it timeout : 4.0