704 Commits

Author SHA1 Message Date
Markus Heiser
ee66b070a9 [mod] aol engines: disable by default (#5975)
The AOL engines deliver no results or too many incorrect results; in #5972 it is
reported that the AOL-images do not work, and on AOL-web the language selection
seems to depend more on the IP than on the selected language / Locally, the
language selection works for me, on the public server only English results are
displayed, which significantly worsens the result list.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-04-13 11:04:11 +02:00
Markus Heiser
9e08a6771f [mod] GH workflow "update translations from Weblate" (area:i18n) (#5968)
Rename label of the Weblate updates (PR) from `translation` to `area:i18n`.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-04-11 11:48:45 +02:00
Bnyro
919aeae42a [mod] pexels: add default api key as fallback 2026-04-11 10:40:39 +02:00
Bnyro
20fc6fe80d [fix] pexels: circumvent botdetection by passing referer header
As a side effect, Cloudscraper is no longer needed.
It probably only ever worked by setting the correct request headers,
so we don't really need it since we can just set the right request
headers and ciphersuites ourselves.
2026-04-11 10:40:39 +02:00
Bnyro
fb68010f72 [fix] tagesschau: parse error when there's no first sentence (#5959)
Example:

```json
{
    "sophoraId" : "rbb-von-24-trockentoiletten-in-berliner-parks-bleiben-acht-im-betrieb-102",
    "externalId" : "tagesschau_fm-story-rbb_park-toilette-klimafreundlich",
    "title" : "Von 24 Trockentoiletten in Berliner Parks bleiben acht im Betrieb",
    "date" : "2026-04-09T19:16:51.000+02:00",
    "teaserImage" : {
      "title" : "402109255",
      "copyright" : "dpa/Paul Zinken",
      "alttext" : "\"Toilette\" steht auf dem Schild an einer neuen Parktoilette in einem Park in Berlin. (Quelle: dpa/Paul Zinken)",
      "imageVariants" : {
        "1x1-144" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStQvU/1x1-144.jpg",
        "1x1-256" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStSJ8/1x1-256.jpg",
        "1x1-432" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStTkw/1x1-432.jpg",
        "1x1-640" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStU_E/1x1-640.jpg",
        "1x1-840" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStWZo/1x1-840.jpg",
        "16x9-256" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvh0M/16x9-256.jpg",
        "16x9-384" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvjXw/16x9-384.jpg",
        "16x9-512" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvlIQ/16x9-512.jpg",
        "16x9-640" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvmjA/16x9-640.jpg",
        "16x9-960" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvpk8/16x9-960.jpg",
        "16x9-1280" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSveow/16x9-1280.jpg",
        "16x9-1920" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvgNE/16x9-1920.jpg"
      },
      "type" : "image"
    },
    "tags" : [ {
      "tag" : "rbb"
    }, {
      "tag" : "Berlin"
    } ],
    "updateCheckUrl" : "https://www.tagesschau.de/api2u/rbb-von-24-trockentoiletten-in-berliner-parks-bleiben-acht-im-betrieb-102.json?view=hasChanged&lastKnown=C168EFEC89F7D1C16BC08D8E641A0503",
    "content" : [ {
      "value" : "Von 24 kostenlosen Trockentoiletten in Berliner Parks sind 16 Anlagen im März wieder abgebaut worden. Acht Toiletten werden nach Auskunft der Senatsverwaltung für Klimaschutz und Umwelt weiterbetrieben.",
      "type" : "text"
    }, {
      "value" : "Die Toiletten waren laut den Angaben der Senatsverwaltung Teil eines Pilotprojekts. Es startete im März 2023 und war zunächst als einjähriger Test angelegt. Für den Fall einer positiven Nutzung und eines reibungslosen Betriebs wurden vertraglich zwei Verlängerungsoptionen von jeweils einem weiteren Jahr vorgesehen. Diese Optionen seien in Anspruch genommen worden und nun ausgeschöpft.",
      "type" : "text"
    }, {
      "value" : "<h2>Nutzer waren zufrieden</h2>",
      "type" : "headline"
    }, {
      "value" : "Dabei waren die Nutzerinnen und Nutzer offensichtlich recht zufrieden mit den Klos, wie aus Befragungsdaten der Senatsverwaltung hervorgeht. Die Befragten bewerteten die Toiletten weitgehend als attraktiv. Auch die Sauberkeit und der Geruch wurden überwiegend positiv bewertet. [<a href=\"https://www.berlin.de/sen/uvk/mobilitaet-und-verkehr/infrastruktur/oeffentliche-toiletten/klimafreundliche-parktoiletten/\" type=\"extern\">berlin.de</a>]",
      "type" : "text"
    }, {
      "box" : {
        "text" : "<ul><br/><li>Lichtenberg: Naturerfahrungsraum Herzberge (neuer Standort)</li><br/><li>Mitte: Kulturforum (neuer Standort)</li><br/><li>Steglitz-Zehlendorf: Stadtpark Steglitz und Spielplatz am Lauenburger Platz</li><br/><li>Tempelhof-Schöneberg: Cheruskerpark und Heinrich-Lassen-Park</li><br/><li>Friedrichshain-Kreuzberg: Engelwiese Alt-Stralau</li><br/><li>Treptow-Köpenick: Wuhlheide an der Treskowallee</li><br/></ul>",
        "title" : "Diese Trockentoiletten werden weiterbetrieben",
        "infobox" : false
      },
      "type" : "box"
    }, {
      "value" : "<h2>Neues Vergabeverfahren für Parktoiletten</h2>",
      "type" : "headline"
    }, {
      "value" : "Im Anschluss an das Pilotprojekt sei geplant, im Rahmen eines Vergabeverfahrens neue Parktoiletten zu beschaffen, teilte ein Sprecher der Senatsverwaltung rbb|24 mit. Wie genau diese Anlagen aussehen sollen, wurde nicht gesagt. Die Versorgung solle aber durch \"modernere Anlagen mit höheren Kapazitäten und einer besseren Barrierefreiheit\" verbessert werden.<br /> <br />Das Vergabeverfahren wird den Angaben zufolge derzeit vorbereitet, sodass die ersten neuen Anlagen möglichst ab 2027 errichtet werden können.",
      "type" : "text"
    }, {
      "value" : "Sendung: rbb|24, 09.04.2026, 19:16 Uhr<br /> <br />Video: rbb|24, 09.04.2026, Johanna Steinlen",
      "type" : "text"
    } ],
    "tracking" : [ {
      "sid" : "app.inland.regional.berlin.rbb-von-24-trockentoiletten-in-berliner-parks-bleiben-acht-im-betrieb-102",
      "src" : "rbb",
      "ctp" : "nicht-definiert",
      "pdt" : "20260409T1920",
      "otp" : "meldung",
      "cid" : "rbb-von-24-trockentoiletten-in-berliner-parks-bleiben-acht-im-betrieb-102",
      "pti" : "Von_24_Trockentoiletten_in_Berliner_Parks_bleiben_acht_im_Betrieb",
      "bcr" : "nein",
      "type" : "generic",
      "av_full_show" : false
    } ],
    "topline" : "Berlin",
    "images" : [ {
      "title" : "402109255",
      "copyright" : "dpa/Paul Zinken",
      "alttext" : "\"Toilette\" steht auf dem Schild an einer neuen Parktoilette in einem Park in Berlin. (Quelle: dpa/Paul Zinken)",
      "imageVariants" : {
        "1x1-144" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStQvU/1x1-144.jpg",
        "1x1-256" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStSJ8/1x1-256.jpg",
        "1x1-432" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStTkw/1x1-432.jpg",
        "1x1-640" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStU_E/1x1-640.jpg",
        "1x1-840" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSStWZo/1x1-840.jpg",
        "16x9-256" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvh0M/16x9-256.jpg",
        "16x9-384" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvjXw/16x9-384.jpg",
        "16x9-512" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvlIQ/16x9-512.jpg",
        "16x9-640" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvmjA/16x9-640.jpg",
        "16x9-960" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvpk8/16x9-960.jpg",
        "16x9-1280" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSveow/16x9-1280.jpg",
        "16x9-1920" : "https://images.tagesschau.de/image/5dad7c26-72b0-4c5c-9758-cf3e351d86ac/AAABnXNCEmI/AAABnSSvgNE/16x9-1920.jpg"
      },
      "type" : "image"
    } ],
    "brandingImage" : {
      "title" : "Logo Rundfunk Berlin-Brandenburg",
      "copyright" : "rbb24",
      "alttext" : "Logo Rundfunk Berlin-Brandenburg",
      "imageVariants" : {
        "original" : "https://images.tagesschau.de/image/e03b1ea1-c03d-4d50-bfb2-41c40808e93a/AAABlaqAiSQ/AAABnR8VW9w/original.png"
      },
      "type" : "image"
    },
    "details" : "https://www.tagesschau.de/api2u/inland/regional/berlin/rbb-von-24-trockentoiletten-in-berliner-parks-bleiben-acht-im-betrieb-102.json",
    "detailsweb" : "https://www.tagesschau.de/inland/regional/berlin/rbb-von-24-trockentoiletten-in-berliner-parks-bleiben-acht-im-betrieb-102.html",
    "shareURL" : "https://www.rbb24.de/panorama/beitrag/2026/04/park-toilette-klimafreundlich.html",
    "geotags" : [ ],
    "regionId" : 3,
    "regionIds" : [ 3 ],
    "breakingNews" : false,
    "type" : "story"
  }
```
2026-04-11 09:34:22 +02:00
dependabot[bot]
e90c036ed6 [upd] pypi: Bump the minor group with 4 updates (#5965)
Bumps the minor group with 4 updates: [lxml](https://github.com/lxml/lxml), [msgspec](https://github.com/jcrist/msgspec), [granian](https://github.com/emmett-framework/granian) and [selenium](https://github.com/SeleniumHQ/Selenium).


Updates `lxml` from 6.0.2 to 6.0.3
- [Release notes](https://github.com/lxml/lxml/releases)
- [Changelog](https://github.com/lxml/lxml/blob/master/CHANGES.txt)
- [Commits](https://github.com/lxml/lxml/compare/lxml-6.0.2...lxml-6.0.3)

Updates `msgspec` from 0.20.0 to 0.21.0
- [Release notes](https://github.com/jcrist/msgspec/releases)
- [Changelog](https://github.com/jcrist/msgspec/blob/main/docs/changelog.md)
- [Commits](https://github.com/jcrist/msgspec/compare/0.20.0...0.21.0)

Updates `granian` from 2.7.2 to 2.7.3
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.7.2...v2.7.3)

Updates `selenium` from 4.41.0 to 4.43.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.41.0...selenium-4.43.0)
2026-04-11 09:31:46 +02:00
github-actions[bot]
e094ed3976 [l10n] update translations from Weblate (#5966)
02aad3f5a - 2026-04-08 - AndersNordh <andersnordh@noreply.codeberg.org>
29686752b - 2026-04-05 - JanDziaslo <jandziaslo@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-04-11 09:01:18 +02:00
dependabot[bot]
7737a0da1a [upd] github-actions: Bump docker/scout-action from 1.20.3 to 1.20.4 (#5963)
Bumps [docker/scout-action](https://github.com/docker/scout-action) from 1.20.3 to 1.20.4.
- [Release notes](https://github.com/docker/scout-action/releases)
- [Commits](8910519cee...bacf462e8d)

---
updated-dependencies:
- dependency-name: docker/scout-action
  dependency-version: 1.20.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-10 16:02:22 +02:00
Esen
67af4894d4 [fix] google: switch to using "Google Go App" (NSTNWV) useragent 2026-04-10 10:09:02 +02:00
Ivan Gabaldon
08ef7a63d7 [enh] engine: rework lingva
lingva.thedaviddelta.com instance is dead, use lingva.ml
2026-04-07 15:49:46 +02:00
dependabot[bot]
346a467077 [upd] web-client (simple): Bump the minor group (#5946)
Bumps the minor group in /client/simple with 2 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) and [browserslist](https://github.com/browserslist/browserslist).

Updates `@biomejs/biome` from 2.4.9 to 2.4.10
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.4.10/packages/@biomejs/biome)

Updates `browserslist` from 4.28.1 to 4.28.2
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.28.1...4.28.2)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.4.10
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: browserslist
  dependency-version: 4.28.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-07 08:19:56 +02:00
Markus Heiser
e12b722ddc [upd] pygments dependency - make themes.all (#5947)
PR #5947 upgraded the pygments dependency, this commit updates
the static files ::

    $ make themes.all

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-04-06 07:35:43 +02:00
dependabot[bot]
24948350f6 [upd] pypi: Bump the minor group with 2 updates (#5947)
Bumps the minor group with 2 updates: [pygments](https://github.com/pygments/pygments) and [basedpyright](https://github.com/detachhead/basedpyright).

Updates `pygments` from 2.19.2 to 2.20.0
- [Release notes](https://github.com/pygments/pygments/releases)
- [Changelog](https://github.com/pygments/pygments/blob/master/CHANGES)
- [Commits](https://github.com/pygments/pygments/compare/2.19.2...2.20.0)

Updates `basedpyright` from 1.38.4 to 1.39.0
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.38.4...v1.39.0)
2026-04-06 07:35:43 +02:00
Aadniz
474b0a55b0 [fix] karmasearch engine: setting Referer header to bypass bot detection (#5953) 2026-04-05 03:59:39 +02:00
Ivan Gabaldon
69f04d59dc [fix] docs: container compose typo (#5952) 2026-04-04 21:57:32 +02:00
Markus Heiser
7adace694c [doc] add missing packages required for installation (#5951)
Related:

- https://github.com/searxng/searxng/pull/5763
- https://github.com/searxng/searxng/pull/5765
- https://github.com/searxng/searxng/pull/5346

Closes: https://github.com/searxng/searxng/issues/5937

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-04-04 19:02:44 +02:00
Nicolas Dato
e92f6b70a0 [mod] duckduckgo: restore Sec-Fetch-* headers to prevent rate limits 2026-04-04 17:44:35 +02:00
github-actions[bot]
c980fa1efc [l10n] update translations from Weblate (#5948)
81ade0dcf - 2026-03-31 - Linerly <linerly@noreply.codeberg.org>
6d96e9916 - 2026-03-30 - danilo-jlle <danilo-jlle@noreply.codeberg.org>
f2a7ef464 - 2026-03-29 - Maoyue_OUO <maoyue_ouo@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-04-03 23:02:03 +02:00
dependabot[bot]
53141be387 [upd] github-actions: Bump github/codeql-action from 4.34.1 to 4.35.1 (#5945)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.34.1 to 4.35.1.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](3869755554...c10b8064de)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.35.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-03 09:42:21 +02:00
dependabot[bot]
953933d472 [upd] github-actions: Bump docker/login-action from 4.0.0 to 4.1.0 (#5944)
Bumps [docker/login-action](https://github.com/docker/login-action) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](b45d80f862...4907a6ddec)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-version: 4.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-03 09:41:08 +02:00
Robert Clabough
bab3879cba [fix] tubearchivist engine: add trailing slash to API URL 2026-04-01 21:19:14 +02:00
github-actions[bot]
7ac4ff39fe [data] update searx.data - update_firefox_version.py (#5924)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-29 08:32:52 +02:00
github-actions[bot]
ea6f491c93 [data] update searx.data - update_external_bangs.py (#5925)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-29 08:32:26 +02:00
github-actions[bot]
5ecf7515dc [data] update searx.data - update_gsa_useragents.py (#5926)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-29 08:31:52 +02:00
github-actions[bot]
c8208fa8bb [data] update searx.data - update_ahmia_blacklist.py (#5927)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-29 08:05:41 +02:00
github-actions[bot]
40e5ba9fdc [data] update searx.data - update_currencies.py (#5930)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-29 08:04:15 +02:00
dependabot[bot]
cf5389afd4 [upd] web-client (simple): Bump the minor group (#5915)
Bumps the minor group in /client/simple with 3 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [stylelint](https://github.com/stylelint/stylelint) and [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).

Updates `@biomejs/biome` from 2.4.8 to 2.4.9
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.4.9/packages/@biomejs/biome)

Updates `stylelint` from 17.5.0 to 17.6.0
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/17.5.0...17.6.0)

Updates `vite` from 8.0.2 to 8.0.3
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/create-vite@8.0.3/packages/vite)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.4.9
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: stylelint
  dependency-version: 17.6.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: vite
  dependency-version: 8.0.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-28 18:12:01 +01:00
github-actions[bot]
ae51c349fd [l10n] update translations from Weblate (#5917)
b17f6ca00 - 2026-03-26 - bittin <bittin@noreply.codeberg.org>
e43bc66a4 - 2026-03-26 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
41cb62330 - 2026-03-26 - gallegonovato <gallegonovato@noreply.codeberg.org>
48308f385 - 2026-03-25 - Outbreak2096 <outbreak2096@noreply.codeberg.org>
a91644d65 - 2026-03-25 - Stephan-P <stephan-p@noreply.codeberg.org>
af44a9e71 - 2026-03-25 - kratos <makesocialfoss32@keemail.me>
f5be3ecd0 - 2026-03-25 - ghose <ghose@noreply.codeberg.org>
7e4a2e0a5 - 2026-03-25 - return42 <return42@noreply.codeberg.org>
6768f2fbc - 2026-03-25 - Fjuro <fjuro@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-28 18:11:02 +01:00
Ivan Gabaldon
6b9856d643 [mod] container: rework compose (#5906)
* [mod] container: rework compose

See https://docs.searxng.org/admin/installation-docker.html#migrate-from-searxng-docker

* [mod] container: apply suggestions

https://github.com/searxng/searxng/pull/5906#discussion_r3004917087
https://github.com/searxng/searxng/pull/5906#discussion_r3004917090
https://github.com/searxng/searxng/pull/5906#discussion_r3004917084
2026-03-28 16:45:06 +01:00
dependabot[bot]
e58516daf5 [upd] pypi: Bump basedpyright from 1.38.3 to 1.38.4 in the minor group (#5916)
Bumps the minor group with 1 update: [basedpyright](https://github.com/detachhead/basedpyright).


Updates `basedpyright` from 1.38.3 to 1.38.4
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.38.3...v1.38.4)

---
updated-dependencies:
- dependency-name: basedpyright
  dependency-version: 1.38.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-28 07:46:23 +01:00
dependabot[bot]
265858ee2b [upd] github-actions: Bump docker/scout-action from 1.20.2 to 1.20.3 (#5913)
Bumps [docker/scout-action](https://github.com/docker/scout-action) from 1.20.2 to 1.20.3.
- [Release notes](https://github.com/docker/scout-action/releases)
- [Commits](1128f02d1e...8910519cee)

---
updated-dependencies:
- dependency-name: docker/scout-action
  dependency-version: 1.20.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-27 14:01:04 +01:00
dependabot[bot]
d7a83b8d8a [upd] github-actions: Bump github/codeql-action from 4.33.0 to 4.34.1 (#5914)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.33.0 to 4.34.1.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](b1bff81932...3869755554)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.34.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-27 14:00:14 +01:00
Markus Heiser
e734424006 [fix] engine - karmasearch crash when searching with long queries (#5912)
Karmasearch seem to crash when searching with long queries >= 100 characters.
The returned JSON is exactly this `["",[]]`, which will crash when trying to
access `resp.json()["results"]`

Close: https://github.com/searxng/searxng/issues/5911

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-26 15:54:32 +01:00
Bnyro
fe1d6d9c48 [fix] unsplash: fix engine due to anubis bot blocking (#5907)
Unsplash started using [Anubis](https://anubis.techaro.lol/)
for blocking crawlers. Therefore, requests using common
user agents (e.g. Firefox, Chrome) must pass a JavaScript
challenge.

However, other user agents seem unaffected for now, hence
settings the UA to something different does still work.
2026-03-25 20:36:17 +01:00
Markus Heiser
0dc032435a [chore] make data.traits - add regions from karmasearch
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-25 19:45:46 +01:00
Bnyro
bd8106e40e [feat] engines: add karmasearch engine (brave mirror) 2026-03-25 19:45:46 +01:00
Markus Heiser
541c6c3cb1 [chore] make data.traits - fix bing engine traits (#5903)
bing's traits.languages has been removed in #5793

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-25 12:09:43 +01:00
dependabot[bot]
02ba387865 [upd] web-client (simple): Bump the group (#5874)
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-24 22:17:07 +01:00
dependabot[bot]
8c1570af1c [upd] pypi: Bump basedpyright from 1.38.2 to 1.38.3 in the minor group (#5876)
Bumps the minor group with 1 update: [basedpyright](https://github.com/detachhead/basedpyright).

Updates `basedpyright` from 1.38.2 to 1.38.3
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.38.2...v1.38.3)
2026-03-24 21:44:27 +01:00
Markus Heiser
c52d23f262 [fix] clean up and update python requirements (#5899)
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-24 21:41:39 +01:00
dependabot[bot]
ae4b73039f [upd] pypi: Bump sphinx-issues from 5.0.1 to 6.0.0 (#5877)
Bumps [sphinx-issues](https://github.com/sloria/sphinx-issues) from 5.0.1 to 6.0.0.
- [Commits](https://github.com/sloria/sphinx-issues/compare/5.0.1...6.0.0)

---
updated-dependencies:
- dependency-name: sphinx-issues
  dependency-version: 6.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...
2026-03-24 20:58:30 +01:00
Bnyro
220c42c8e9 [feat] engines: add support for aol.com (#5882)
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-24 20:44:15 +01:00
Markus Heiser
99ec6f296e [mod] drop support for Python releases older than 4 years (#5895)
The end-of-life (EOL) of a Python release is reached after 5 years, with the
last three years dedicated to security fixes. [1]

Unfortunately, this doesn't apply to common libraries (dependencies): bug fixes
are often only included in major releases, and minor releases with corresponding
security fixes are rarely offered.

To make matters worse, these dependencies often prematurely discontinue their
support for older Python releases (because, for example, they want/need to use
new Python features).

If we want to offer secure software, we are faced with the dilemma of either
supporting old Python releases and accepting that there are security bugs in the
dependencies, or ending support for older Python versions before the actual EOL
of the Python release.

[1] https://devguide.python.org/versions/

Closes: https://github.com/searxng/searxng/issues/5869

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-24 20:26:34 +01:00
Markus Heiser
054174a19d [build] /static 2026-03-24 20:21:27 +01:00
Ruben D.
5e8255f28a [MOD] generate manifest PWA icons (#5859) 2026-03-24 20:21:27 +01:00
Ruben D.
3dc4d5daa8 [mod] add manifest.json template and route (#5859)
URLs, name and colors are automatically rendered into manifest.json.
Furthermore user preference of theme (light, dark, black) and theme colors are
respected.  Theme colors can be set in settings.yml
2026-03-24 20:21:27 +01:00
Markus Heiser
924fc52f54 [build] /static 2026-03-24 19:39:11 +01:00
Markus Heiser
8d44ff51e2 [mod] remove the "Submit a new issue on Github" form (#5896)
Submitting an issue on GitHub isn't a end user task .. most issue reports coming
from this form are not filled out, since end users are not familiar with the
needs of a developer community.

Closes: https://github.com/searxng/searxng/issues/5820
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-24 19:39:11 +01:00
Bnyro
f8056b5e44 [chore] make data.traits 2026-03-24 15:55:54 +01:00
Bnyro
71cea1d87f [feat] engines: add boardreader engine (#5881) 2026-03-24 15:55:54 +01:00
Markus Heiser
c4f51aa4ac [fix] google engine - don't set __Secure-ENID in the HTTP header (#5894)
PR #5892 only deepends on the UA and the __Secure-ENID is not needed [1].

[1] https://github.com/searxng/searxng/pull/5892#issuecomment-4114835195

Suggested-by: @yeyuchen198

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-24 15:16:47 +01:00
mg95
2c1ce3bd37 [fix] google: switch to using "Google App" for Android useragent (#5892)
I found a bypass using the Android Google App this time. However, unlike the iPhone GSA method, this one does have rate limits. Although it took a couple of hundred consecutive requests to trigger them.
2026-03-23 14:55:48 +01:00
dependabot[bot]
6c7e9c1976 [upd] github-actions: Bump actions/cache from 5.0.3 to 5.0.4 (#5873)
Bumps [actions/cache](https://github.com/actions/cache) from 5.0.3 to 5.0.4.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](cdf6c1fa76...668228422a)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: 5.0.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-20 22:00:17 +01:00
dependabot[bot]
8ad72872b5 [upd] github-actions: Bump github/codeql-action from 4.32.6 to 4.33.0 (#5872)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.6 to 4.33.0.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](0d579ffd05...b1bff81932)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.33.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-20 21:00:27 +01:00
Aadniz
2bf5f00e7d [build] /static 2026-03-20 16:31:32 +01:00
Aadniz
5ab3ef774b [feat] client/simple: show/hide autocomplete list on focus/blur
The autocomplete suggestion list is currently a bit hard to close if it has been spawned once. Sometimes you may write something in the input field, change your mind and then want to click the first result on the page. But since the dropdown cannot be closed, the dropdown is in the way to be able to click on the first result.
2026-03-20 16:31:32 +01:00
dependabot[bot]
3810dc9d1c [upd] web-client (simple): Bump vite in /client/simple (#5856)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.16 to 8.0.0.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/create-vite@8.0.0/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-18 15:14:37 +01:00
dependabot[bot]
c589b56d69 [upd] web-client (simple): Bump the minor group (#5855)
Bumps the minor group in /client/simple with 2 updates: [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [less](https://github.com/less/less.js).

Updates `@types/node` from 25.3.5 to 25.5.0
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `less` from 4.5.1 to 4.6.3
- [Release notes](https://github.com/less/less.js/releases)
- [Changelog](https://github.com/less/less.js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/less/less.js/compare/v4.5.1...v4.6.3)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-version: 25.5.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: less
  dependency-version: 4.6.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-18 15:12:57 +01:00
Ivan Gabaldon
6521190bb4 [enh] engines: rework bing engine (#5793)
* [enh] engines: rework bing engine

Only Bing-Web has been reworked.

Some features now require JavaScript (paging and time-range results).
Cookies no longer work, parameters such as `cc`, `ui`, ... alter the results.

The engine only appears to use the locale from `Accept-Language` header properly.

The rest of Bing's child engines (Bing-Image, Bing-Video, ...) seem to benefit
from using `mkt` param in conjunction with the `Accept-Language` header
override, although Bing-Web does not (?)

* [enh] explicit mkt

* [fix] engines: bing_videos.py

https://github.com/searxng/searxng/pull/5793#pullrequestreview-3881883250
2026-03-18 14:55:25 +01:00
Markus Heiser
2bb8ac17c6 [fix] Youtube video - "Error 153" send HTTP Referrer (referrerpolicy) (#5858)
For videos from ``www.youtube.com`` this patch adds ``referrerpolicy`` and other
by YT required permission policies for the iframe.

API Clients that use the YouTube embedded player (including the YouTube IFrame
Player API) must provide identification through the HTTP ``Referer`` request
header[1].

If the error still occurs, check if server headers (e.g., in .htaccess or Nginx)
are overriding the referrer policy[2].

[1] https://developers.google.com/youtube/terms/required-minimum-functionality#embedded-player-api-client-identity
[2] hint comes from AI: https://chat.mistral.ai
[3] https://developers.google.com/youtube/player_parameters


Close: https://github.com/searxng/searxng/issues/5844

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-17 19:52:46 +01:00
Aadniz
4c4ed4b198 [fix] google engine: Result image thumbnails 2026-03-16 23:35:33 +01:00
dependabot[bot]
3c1f68c59e [upd] github-actions: Bump docker/scout-action from 1.18.2 to 1.20.2 (#5854)
Bumps [docker/scout-action](https://github.com/docker/scout-action) from 1.18.2 to 1.20.2.
- [Release notes](https://github.com/docker/scout-action/releases)
- [Commits](f8c7768240...1128f02d1e)

---
updated-dependencies:
- dependency-name: docker/scout-action
  dependency-version: 1.20.2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-13 14:09:07 +01:00
Renaud Allard
23fb76f08f Fix XSS via unsafe rendering of untrusted external data in templates (#5826)
Remove |safe filter from 6 template locations where data from external
search engine APIs was rendered as raw HTML without sanitization. Jinja2
autoescape now properly escapes these fields.

The |safe filter was originally added in commit 213041adc (March 2021)
by copying the pattern from result.title|safe and result.content|safe.
However, title and content are pre-escaped via escape() in webapp.py
lines 704-706 before highlight_content() adds trusted <span> tags for
search term highlighting. The metadata, info.value, link.url_label,
repository, and filename fields never go through any escaping and flow
directly from external API responses to the template.

Affected templates and their untrusted data sources:
- macros.html: result.metadata from DuckDuckGo, Reuters, Presearch,
  Podcast Index, Fyyd, bpb, moviepilot, mediawiki, and others
- paper.html: result.metadata from academic search engines
- map.html: info.value and link.url_label from OpenStreetMap
  user-contributed extratags
- code.html: result.repository and result.filename from GitHub API

Example exploit: a search engine API returning
metadata='<img src=x onerror=alert(document.cookie)>' would execute
arbitrary JavaScript in every user's browser viewing that result.
2026-03-13 13:28:31 +01:00
github-actions[bot]
867a43ac1f [l10n] update translations from Weblate (#5857)
7bbad1a8d - 2026-03-10 - omeritzics <omeritzics@noreply.codeberg.org>
68a483eec - 2026-03-08 - Stephan-P <stephan-p@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-13 12:43:21 +01:00
Bnyro
3d3a78f3aa chore: add link to ai policy in issue/pr templates 2026-03-12 16:04:00 +01:00
Bnyro
3a032d63a9 docs: add AI policy 2026-03-12 16:04:00 +01:00
Bnyro
e30d490429 [mod] right dao: remove engine (#5849)
Since about a month, the website just says "temporarily unavailable", so it's safe to assume that it's just no longer working

Related:

- https://github.com/searxng/searxng/pull/3798
2026-03-12 15:20:53 +01:00
SeriousConcept1134
8b95b2058b [fix] google engines: update XPaths for modern mobile UI (#5836)
Google recently changed the DOM structure for mobile-centric responses, causing the `google_videos` engine to return zero results and the main `google` engine to drop the majority of its results (due to missing snippets or failed URL parsing). These changes restore the functionality and improve the result count for both engines.

This patch updates the parsing logic for both the `google` and `google_videos` engines to handle the modern HTML structure returned by Google when using GSA (Google Search App) User-Agents.

**Specific changes include:**

* **Google Videos (`gov`)**:
    * Updated title XPath to support `role="heading"`.
    * Improved URL extraction to correctly decode Google redirectors (`/url?q=...`) using `unquote`.
    * Added support for the `WRu9Cd` class to capture publication metadata (author/date).
    * Broadened thumbnail search and added a fallback to YouTube's `hqdefault.jpg`.

* **Google Web**:
    * Relaxed the strict snippet (`content`) requirement. Valid results are no longer discarded if a snippet is missing in the mobile UI.
    * Hardened URL extraction to handle both direct and redirected URLs safely.
    * Improved thumbnail extraction by searching the entire result block.
2026-03-10 09:05:54 +01:00
dependabot[bot]
d4954a0646 [upd] web-client (simple): Bump the minor group (#5818)
Bumps the minor group in /client/simple with 3 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [svgo](https://github.com/svg/svgo).


Updates `@biomejs/biome` from 2.4.4 to 2.4.6
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.4.6/packages/@biomejs/biome)

Updates `@types/node` from 25.3.2 to 25.3.5
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `svgo` from 4.0.0 to 4.0.1
- [Release notes](https://github.com/svg/svgo/releases)
- [Commits](https://github.com/svg/svgo/compare/v4.0.0...v4.0.1)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.4.6
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 25.3.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: svgo
  dependency-version: 4.0.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-09 14:25:05 +01:00
vojkovic
a563127a26 [fix] engines: remove google arc/async params 2026-03-08 23:22:32 +08:00
dependabot[bot]
0716de6bc8 [upd] github-actions: Bump github/codeql-action from 4.32.4 to 4.32.6 (#5814)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.4 to 4.32.6.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](89a39a4e59...0d579ffd05)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.32.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-06 23:00:07 +01:00
Brock Vojkovic
68ff08f224 [mod] drop fasttext-predict (#5795)
Removes the `fasttext-predict` dependency and the language detection code.

If a user now selects `auto` for the search language, the detected language now
falls back directly to the `Accept-Language` header sent by the browser (which was already the fallback when fasttext returned no result).

- fasttext's [language detection is unreliable](https://github.com/searxng/searxng/issues/4195) for some languages, especially short search queries, and in particular for queries containing proper names which is a common case.
- `fasttext-predict` consumes [significant memory](https://github.com/searxng/searxng/pull/1969#issuecomment-1345366676) without offering users much real value.
- the upstream fasttext project was archived by Meta in 2024
- users already have two better alternatives: the `Accept-Language` header and the search-syntax language prefix (e.g. `:fr` or `:de`).

Related: https://github.com/searxng/searxng/issues/4195
Closes: https://github.com/searxng/searxng/issues/5790
2026-03-06 15:40:44 +01:00
dependabot[bot]
c7ba2158f9 [upd] pypi: Bump the minor group with 2 updates (#5817)
Bumps the minor group with 2 updates: [nose2[coverage_plugin]](https://github.com/nose-devs/nose2) and [sphinx-tabs](https://github.com/executablebooks/sphinx-tabs).


Updates `nose2[coverage_plugin]` from 0.15.1 to 0.16.0
- [Changelog](https://github.com/nose-devs/nose2/blob/main/docs/changelog.rst)
- [Commits](https://github.com/nose-devs/nose2/compare/0.15.1...0.16.0)

Updates `sphinx-tabs` from 3.4.7 to 3.5.0
- [Release notes](https://github.com/executablebooks/sphinx-tabs/releases)
- [Changelog](https://github.com/executablebooks/sphinx-tabs/blob/main/CHANGELOG.md)
- [Commits](https://github.com/executablebooks/sphinx-tabs/compare/v3.4.7...v3.5.0)
2026-03-06 15:15:08 +01:00
dependabot[bot]
c1b211aeea [upd] github-actions: Bump docker/login-action from 3.7.0 to 4.0.0 (#5816)
Bumps [docker/login-action](https://github.com/docker/login-action) from 3.7.0 to 4.0.0.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](c94ce9fb46...b45d80f862)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-version: 4.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-06 14:18:54 +01:00
dependabot[bot]
08d2b92b2a [upd] github-actions: Bump docker/setup-qemu-action from 3.7.0 to 4.0.0 (#5815)
Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action) from 3.7.0 to 4.0.0.
- [Release notes](https://github.com/docker/setup-qemu-action/releases)
- [Commits](c7c5346462...ce360397dd)

---
updated-dependencies:
- dependency-name: docker/setup-qemu-action
  dependency-version: 4.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-06 14:15:36 +01:00
dependabot[bot]
7cc4eedc1a [upd] github-actions: Bump actions/setup-node from 6.2.0 to 6.3.0 (#5813)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 6.2.0 to 6.3.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](6044e13b5d...53b83947a5)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 6.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-06 14:14:46 +01:00
github-actions[bot]
25e457c8d5 [l10n] update translations from Weblate (#5812)
5a33207b4 - 2026-03-03 - Linerly <linerly@noreply.codeberg.org>
b84870677 - 2026-03-01 - return42 <return42@noreply.codeberg.org>
8862bb219 - 2026-03-01 - return42 <return42@noreply.codeberg.org>
f64625f8b - 2026-03-01 - return42 <return42@noreply.codeberg.org>
5424e5190 - 2026-03-01 - return42 <return42@noreply.codeberg.org>
999ed9500 - 2026-03-01 - return42 <return42@noreply.codeberg.org>
55f674a81 - 2026-03-01 - return42 <return42@noreply.codeberg.org>
ccc5398f1 - 2026-03-01 - return42 <return42@noreply.codeberg.org>
eefcd7854 - 2026-02-28 - cdli <cdli@noreply.codeberg.org>
5985f8df0 - 2026-02-27 - boradog <boradog@noreply.codeberg.org>
cd0213e39 - 2026-02-28 - DeckPacker <deckpacker@noreply.codeberg.org>
94c0b5fc8 - 2026-02-28 - Serpensin <serpensin@noreply.codeberg.org>
a86b8d609 - 2026-02-28 - DeckPacker <deckpacker@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-06 08:56:15 +01:00
Bnyro
56e565a582 [feat] autocomplete: add bing autocompleter 2026-03-05 20:56:02 +01:00
Ivan Gabaldon
380f1c4a49 [upd] engines: sync "aa" mirrors (#5807) 2026-03-05 19:08:05 +01:00
github-actions[bot]
b5c1c28048 [data] update searx.data - update_engine_descriptions.py (#5791)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-03 22:36:53 +01:00
Ivan Gabaldon
fc53162eec [data] update searx.data - update_engine_traits.py 2026-03-03 20:31:25 +01:00
Ivan Gabaldon
2b03a61832 [enh] data: traits population
Job failing since October 2025.

enh: always raise and reuse data
fix: brave unknown locale
fix: startpage add "brazilian"
2026-03-03 20:31:25 +01:00
Markus Heiser
a9f3baefe6 [fix] unhandled Exceptions in radio_browser.py
Closes: https://github.com/searxng/searxng/issues/5439
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-03 20:31:25 +01:00
Markus Heiser
d1f9409afc [fix] remove base_url https://annas-archive.li
Related:

- https://github.com/searxng/searxng/issues/5773
- https://github.com/searxng/searxng/pull/5780

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-03 20:31:25 +01:00
Ivan Gabaldon
f6e360a134 [mod] engines: remove stract engine (#5800)
Engine probably dead, developer doesn't have time to maintain it anymore:

- https://github.com/StractOrg/stract/issues/267

Related:

- https://github.com/searxng/searxng/pull/3099
2026-03-03 11:47:15 +01:00
Ivan Gabaldon
bc31c29d8a [mod] engines: remove livespace engine (#5798)
Related:

- https://github.com/searxng/searxng/pull/3222
- https://web.archive.org/web/20240524174947/https://about.live.space/post/thank-you
2026-03-03 11:27:33 +01:00
Ivan Gabaldon
65ae6ad902 [mod] engines: remove searchcode engine
Microslop fault https://web.archive.org/web/20260111060432/https://boyter.org/posts/searchcode-is-being-rebooted/
2026-03-03 00:24:15 +01:00
Ivan Gabaldon
dd98f761ad [mod] ci: remove checker
Missed on https://github.com/searxng/searxng/pull/5767
2026-03-02 07:18:32 +01:00
github-actions[bot]
162c04a1c4 [data] update searx.data - update_wikidata_units.py (#5785)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-01 10:55:10 +01:00
Ivan Gabaldon
e084139ca9 [enh] data: uas to a set (#5789)
* [enh] data: uas to a set

* [data] update searx.data - update_gsa_useragents.py

Closes: https://github.com/searxng/searxng/pull/5786
2026-03-01 10:53:39 +01:00
Markus Heiser
8fc549574f [doc] fix minor issues in the DDG engine's doc-strings
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-03-01 10:05:19 +01:00
dependabot[bot]
0eb4970621 [upd] pypi: Bump the minor group with 10 updates
Bumps the minor group with 10 updates:

| Package | From | To |
| --- | --- | --- |
| [certifi](https://github.com/certifi/python-certifi) | `2026.1.4` | `2026.2.25` |
| [typer](https://github.com/fastapi/typer) | `0.24.0` | `0.24.1` |
| [whitenoise](https://github.com/evansd/whitenoise) | `6.11.0` | `6.12.0` |
| [pylint](https://github.com/pylint-dev/pylint) | `4.0.4` | `4.0.5` |
| [pallets-sphinx-themes](https://github.com/pallets/pallets-sphinx-themes) | `2.3.0` | `2.5.0` |
| [sphinxcontrib-programoutput](https://github.com/OpenNTI/sphinxcontrib-programoutput) | `0.18` | `0.19` |
| [granian[reload]](https://github.com/emmett-framework/granian) | `2.7.1` | `2.7.2` |
| [basedpyright](https://github.com/detachhead/basedpyright) | `1.38.1` | `1.38.2` |
| [granian](https://github.com/emmett-framework/granian) | `2.7.1` | `2.7.2` |
| [granian[pname]](https://github.com/emmett-framework/granian) | `2.7.1` | `2.7.2` |


Updates `certifi` from 2026.1.4 to 2026.2.25
- [Commits](https://github.com/certifi/python-certifi/compare/2026.01.04...2026.02.25)

Updates `typer` from 0.24.0 to 0.24.1
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.24.0...0.24.1)

Updates `whitenoise` from 6.11.0 to 6.12.0
- [Changelog](https://github.com/evansd/whitenoise/blob/main/docs/changelog.rst)
- [Commits](https://github.com/evansd/whitenoise/compare/6.11.0...6.12.0)

Updates `pylint` from 4.0.4 to 4.0.5
- [Release notes](https://github.com/pylint-dev/pylint/releases)
- [Commits](https://github.com/pylint-dev/pylint/compare/v4.0.4...v4.0.5)

Updates `pallets-sphinx-themes` from 2.3.0 to 2.5.0
- [Release notes](https://github.com/pallets/pallets-sphinx-themes/releases)
- [Changelog](https://github.com/pallets/pallets-sphinx-themes/blob/main/CHANGES.md)
- [Commits](https://github.com/pallets/pallets-sphinx-themes/compare/2.3.0...2.5.0)

Updates `sphinxcontrib-programoutput` from 0.18 to 0.19
- [Changelog](https://github.com/OpenNTI/sphinxcontrib-programoutput/blob/master/CHANGES.rst)
- [Commits](https://github.com/OpenNTI/sphinxcontrib-programoutput/compare/0.18...0.19)

Updates `granian[reload]` from 2.7.1 to 2.7.2
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.7.1...v2.7.2)

Updates `basedpyright` from 1.38.1 to 1.38.2
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.38.1...v1.38.2)

Updates `granian` from 2.7.1 to 2.7.2
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.7.1...v2.7.2)

Updates `granian[pname]` from 2.7.1 to 2.7.2
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.7.1...v2.7.2)

---
updated-dependencies:
- dependency-name: certifi
  dependency-version: 2026.2.25
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: typer
  dependency-version: 0.24.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: whitenoise
  dependency-version: 6.12.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: pylint
  dependency-version: 4.0.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: pallets-sphinx-themes
  dependency-version: 2.5.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: sphinxcontrib-programoutput
  dependency-version: '0.19'
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: granian[reload]
  dependency-version: 2.7.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: basedpyright
  dependency-version: 1.38.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: granian
  dependency-version: 2.7.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: granian[pname]
  dependency-version: 2.7.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-03-01 10:05:19 +01:00
github-actions[bot]
5a72560319 [data] update searx.data - update_currencies.py (#5788) 2026-03-01 09:22:40 +01:00
github-actions[bot]
5e7aae3f16 [data] update searx.data - update_ahmia_blacklist.py (#5784)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-01 09:20:55 +01:00
github-actions[bot]
62b153f5c1 [data] update searx.data - update_firefox_version.py (#5787)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-03-01 09:19:50 +01:00
Ivan Gabaldon
a2108ce2e5 [enh] engines: rework "aa" engine (#5780)
* [enh] engines: rework "aa" engine

fix: update mirror domains
enh: sync website layout
feat: add `type`, `tags` result fields

* [fix] engines: apply suggestions

https://github.com/searxng/searxng/pull/5780#discussion_r2866198969
https://github.com/searxng/searxng/pull/5780#discussion_r2866207218
https://github.com/searxng/searxng/pull/5780#discussion_r2866211874
https://github.com/searxng/searxng/pull/5780#discussion_r2866228648
https://github.com/searxng/searxng/pull/5780#discussion_r2866232545
https://github.com/searxng/searxng/pull/5780#discussion_r2866235830
2026-02-28 11:35:58 +01:00
github-actions[bot]
31cc7ef7f0 [l10n] update translations from Weblate (#5779)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-02-28 09:37:28 +01:00
mgcsysinfcat
2728331362 [fix] xpath.py: fix safesearch handling if safesearch set to disabled 2026-02-27 21:55:13 +01:00
mgcsysinfcat
ebb300424c [mod] fynd: add safe search support 2026-02-27 21:55:13 +01:00
Zhijie He
0c284b5b09 [mod] sogou: support published date, redirect URLs, ... 2026-02-27 21:45:02 +01:00
dependabot[bot]
8e9ed5f9be [upd] web-client (simple): Bump vite from 8.0.0-beta.15 to 8.0.0-beta.16 in /client/simple (#5777)
* [upd] web-client (simple): Bump vite in /client/simple

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.15 to 8.0.0-beta.16.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.16/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.16
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [upd] themes: rebuild static

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2026-02-27 09:51:42 +01:00
dependabot[bot]
d6c80e4dd1 [upd] web-client (simple): Bump the minor group (#5775)
Bumps the minor group in /client/simple with 3 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [edge.js](https://github.com/edge-js/edge).

Updates `@biomejs/biome` from 2.4.3 to 2.4.4
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.4.4/packages/@biomejs/biome)

Updates `@types/node` from 25.3.0 to 25.3.2
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `edge.js` from 6.4.0 to 6.5.0
- [Release notes](https://github.com/edge-js/edge/releases)
- [Changelog](https://github.com/edge-js/edge/blob/6.x/CHANGELOG.md)
- [Commits](https://github.com/edge-js/edge/compare/v6.4.0...v6.5.0)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.4.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 25.3.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: edge.js
  dependency-version: 6.5.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-27 09:38:54 +01:00
dependabot[bot]
2756341b21 [upd] github-actions: Bump github/codeql-action from 4.32.3 to 4.32.4 (#5774)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.3 to 4.32.4.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](9e907b5e64...89a39a4e59)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.32.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-27 09:30:00 +01:00
Bnyro
c3e3d2d85d [feat] engines: add pexels engine 2026-02-26 11:35:10 +01:00
Bnyro
4964d664f0 [build] /static 2026-02-23 10:57:12 +01:00
Bnyro
845a78daf8 [feat] image results page: also display request statistics (i.e. engine response times)
Apparently the engine statistics have been hidden from the images page when
infinite scroll was added as a preference in 56e34947a6

However, now that we also display engine statistics in the results page,
I don't see any reason why this should still be hidden from the images tab.

For example, this is very useful for seeing which engines work and which ones are broken.
2026-02-23 10:57:12 +01:00
Markus Heiser
191818b865 [mod] drop SearXNG's checker (#5767)
To date, there is no analysis for the checker that could be evaluated in any
meaningful way.

- https://github.com/searxng/searxng/issues/3407
- https://github.com/searxng/searxng/pull/3312

The checker would need to be completely redesigned, but even then, its
usefulness and the maintenance required for it would be disproportionate.

TBH: In its current form, it is useless and only consumes resources and
causes the engines to be blocked, because these tests (query terms) come
from *hundreds* of instances and could be interpreted as bot attacks.

Related issues: [search.checker](https://github.com/searxng/searxng/issues?q=label%3A%22search.checker%22)

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-22 14:44:21 +01:00
Markus Heiser
5054e69844 [fix] searxng.sh fails: No module named 'pybind11' (#5765)
Related: https://github.com/searxng/searxng/discussions/5748#discussioncomment-15880660

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-22 10:23:59 +01:00
Markus Heiser
029b74e4f5 [fix] online engines: remove HTTP Sec-Fetch-* headers
The Sec-Fetch-* headers seem to cause more problems than they solve. They will
be removed for now.

Related:

- https://github.com/searxng/searxng/pull/5758#pullrequestreview-3834221131

Suggested-by: @Bnyro
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-22 09:30:16 +01:00
Markus Heiser
2e6eeb1d79 [fix] complete overhaul of the DuckDuckGo engines
DDG has reimplemented its bot protection, and the DDG engines "images", "news"
and "videos" no longer work in SearXNG and DDG-Web access often ends with a
CAPTCHA.

Related:

- issue 4824
- https://github.com/ggfevans/searxng/blob/mod-sidecar-harvester/docs/ddg-bot-detection-research.md

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-22 09:30:16 +01:00
Markus Heiser
490f28f0a6 [mod] online engines - set common HTTP headers
The online engines emulate a request as it would come from a web browser, which
is why the HTTP headers in the default settings should also be set the way a
standard web browser would set them.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-22 09:30:16 +01:00
Markus Heiser
cc39cf7df3 [mod] fix some minor type hint issues / add some type hints more
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-22 09:30:16 +01:00
Markus Heiser
76f0712319 [mod] settings.yml - adjust default suspended_times from hours to minutes
The default settings for the suspend times were previously 24 hours and 3 hours,
respectively. Based on my experience, these defaults are too high; most engines
handle suspend times of 3 minutes or 1 hour (captcha) without any problems.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-22 09:30:16 +01:00
Markus Heiser
89a63114c4 [fix] searxng.sh fails: No module named 'typing_extensions'
Closes: #5761

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-21 13:41:52 +01:00
Bnyro
9754e7b4e2 [mod] engines: remove seekr engine
Looks like https://www.seekr.com/ was sold to an other company
that does something with enterprise AI and no longer provides any
web search engine.
2026-02-21 11:26:53 +01:00
Ivan Gabaldon
93ac6ceb35 [fix] themes: run \#invoke after class constructor (#5757)
Move \#invoke into a microtask that will run after current call stack completes

Closes: https://github.com/searxng/searxng/issues/5756
2026-02-20 13:00:17 +01:00
dependabot[bot]
4e6e8425ca [upd] web-client (simple): Bump vite in /client/simple (#5751)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.14 to 8.0.0-beta.15.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.15/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-20 11:08:41 +01:00
dependabot[bot]
062b1320a2 [upd] web-client (simple): Bump the minor group (#5749)
Bumps the minor group in /client/simple with 2 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) and [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node).

Updates `@biomejs/biome` from 2.3.15 to 2.4.3
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.4.3/packages/@biomejs/biome)

Updates `@types/node` from 25.2.3 to 25.3.0
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.4.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 25.3.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-20 11:08:32 +01:00
dependabot[bot]
95f95e96c4 [upd] pypi: Bump the minor group with 5 updates
Bumps the minor group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [flask](https://github.com/pallets/flask) | `3.1.2` | `3.1.3` |
| [typer](https://github.com/fastapi/typer) | `0.23.0` | `0.24.0` |
| [selenium](https://github.com/SeleniumHQ/Selenium) | `4.40.0` | `4.41.0` |
| [basedpyright](https://github.com/detachhead/basedpyright) | `1.38.0` | `1.38.1` |
| [types-lxml](https://github.com/abelcheung/types-lxml) | `2026.1.1` | `2026.2.16` |


Updates `flask` from 3.1.2 to 3.1.3
- [Release notes](https://github.com/pallets/flask/releases)
- [Changelog](https://github.com/pallets/flask/blob/main/CHANGES.rst)
- [Commits](https://github.com/pallets/flask/compare/3.1.2...3.1.3)

Updates `typer` from 0.23.0 to 0.24.0
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.23.0...0.24.0)

Updates `selenium` from 4.40.0 to 4.41.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.40.0...selenium-4.41.0)

Updates `basedpyright` from 1.38.0 to 1.38.1
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.38.0...v1.38.1)

Updates `types-lxml` from 2026.1.1 to 2026.2.16
- [Release notes](https://github.com/abelcheung/types-lxml/releases)
- [Changelog](https://github.com/abelcheung/types-lxml/blob/main/CHANGELOG.md)
- [Commits](https://github.com/abelcheung/types-lxml/compare/2026.01.01...2026.02.16)

---
updated-dependencies:
- dependency-name: flask
  dependency-version: 3.1.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: typer
  dependency-version: 0.24.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: selenium
  dependency-version: 4.41.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: basedpyright
  dependency-version: 1.38.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: types-lxml
  dependency-version: 2026.2.16
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-02-20 11:01:32 +01:00
dependabot[bot]
8f824d34a8 [upd] github-actions: Bump github/codeql-action from 4.32.2 to 4.32.3 (#5753)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.2 to 4.32.3.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](45cbd0c69e...9e907b5e64)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.32.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-20 10:52:55 +01:00
searxng-bot
4027ff5699 [l10n] update translations from Weblate
97552c40b - 2026-02-17 - boradog <boradog@noreply.codeberg.org>
2026-02-20 08:54:50 +01:00
Ivan Gabaldon
17544140fb [fix] ci: cache keys (#5745)
YAML block (literal) scalar style also takes quotes into account:

Expected:
  `container-amd64-20260216-acbc0ea29f44f7fc7eeadcf91d421c66f26dbbdd48cc284691f8fd8982ab7323, container-amd64-20260216-, container-amd64-`

Got:
  `container-amd64-20260216-acbc0ea29f44f7fc7eeadcf91d421c66f26dbbdd48cc284691f8fd8982ab7323, "container-amd64-20260216-", "container-amd64-"`
2026-02-19 10:37:20 +01:00
Carsten Csiky
8e824017dc [feat] engines: add artstation engine (#5728)
- use proper Brave API with api_key for search

Co-authored-by: Bnyro <bnyro@tutanota.com>
2026-02-16 14:18:08 +01:00
dependabot[bot]
da9c0815ac [upd] web-client (simple): Bump the minor group (#5737)
Bumps the minor group in /client/simple with 4 updates: [ol](https://github.com/openlayers/openlayers), [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [mathjs](https://github.com/josdejong/mathjs).

Updates `ol` from 10.7.0 to 10.8.0
- [Release notes](https://github.com/openlayers/openlayers/releases)
- [Commits](https://github.com/openlayers/openlayers/compare/v10.7.0...v10.8.0)

Updates `@biomejs/biome` from 2.3.14 to 2.3.15
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.3.15/packages/@biomejs/biome)

Updates `@types/node` from 25.2.1 to 25.2.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `mathjs` from 15.1.0 to 15.1.1
- [Changelog](https://github.com/josdejong/mathjs/blob/develop/HISTORY.md)
- [Commits](https://github.com/josdejong/mathjs/compare/v15.1.0...v15.1.1)

---
updated-dependencies:
- dependency-name: ol
  dependency-version: 10.8.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: "@biomejs/biome"
  dependency-version: 2.3.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 25.2.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: mathjs
  dependency-version: 15.1.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-15 11:30:35 +01:00
Markus Heiser
39ac4d4387 [upd] granian 2.7.0 -> 2.7.1 & basedpyright 1.37.4 -> 1.38.0
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-14 13:20:55 +01:00
Markus Heiser
51ded5e690 [fix] migrate from typer-slim to typer
Package typer-slim does nothing other than depend on typer. The only reason this
package exists is as a migration path for old projects that used to depend on
typer-slim, so that they can get the latest version of typer.

Install instead:

    pip install typer

Package typer-slimis deprecated and will stop receiving any updates and
published versions.

[1] https://pypi.org/project/typer-slim/

Closes: https://github.com/searxng/searxng/issues/5742
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-14 13:08:40 +01:00
dependabot[bot]
97e572728f [upd] web-client (simple): Bump vite in /client/simple (#5738)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.13 to 8.0.0-beta.14.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.14/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-13 10:49:31 +01:00
Ivan Gabaldon
a2db6f6500 Revert "[upd] pypi: ..."
This reverts commit 61d5456852

Related https://github.com/searxng/searxng/issues/5742
2026-02-13 10:30:04 +01:00
dependabot[bot]
61d5456852 [upd] pypi: Bump the minor group with 5 updates
Bumps the minor group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [typer-slim](https://github.com/fastapi/typer) | `0.21.1` | `0.23.0` |
| [granian[reload]](https://github.com/emmett-framework/granian) | `2.7.0` | `2.7.1` |
| [basedpyright](https://github.com/detachhead/basedpyright) | `1.37.4` | `1.38.0` |
| [granian](https://github.com/emmett-framework/granian) | `2.7.0` | `2.7.1` |
| [granian[pname]](https://github.com/emmett-framework/granian) | `2.7.0` | `2.7.1` |


Updates `typer-slim` from 0.21.1 to 0.23.0
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.21.1...0.23.0)

Updates `granian[reload]` from 2.7.0 to 2.7.1
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.7.0...v2.7.1)

Updates `basedpyright` from 1.37.4 to 1.38.0
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.37.4...v1.38.0)

Updates `granian` from 2.7.0 to 2.7.1
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.7.0...v2.7.1)

Updates `granian[pname]` from 2.7.0 to 2.7.1
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.7.0...v2.7.1)

---
updated-dependencies:
- dependency-name: typer-slim
  dependency-version: 0.23.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: granian[reload]
  dependency-version: 2.7.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: basedpyright
  dependency-version: 1.38.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: granian
  dependency-version: 2.7.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: granian[pname]
  dependency-version: 2.7.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-02-13 08:42:54 +01:00
searxng-bot
0277ce9bca [l10n] update translations from Weblate
ca4353e2d - 2026-02-12 - greatdng <greatdng@noreply.codeberg.org>
2026-02-13 08:41:58 +01:00
Austin-Olacsi
970f2b8430 [feat] add nist.gov vulnerability search 2026-02-11 00:44:19 +01:00
Markus Heiser
b5bb27f231 [fix] test_locale_optimized_territory_1_fr (test_locales.TestLocales)
Unit test fails::

    Traceback (most recent call last):
      File "/share/searxng/local/py3/lib/python3.10/site-packages/parameterized/parameterized.py", line 620, in standalone_func
        return func(*(a + p.args), **p.kwargs, **kw)
      File "/share/searxng/tests/unit/test_locales.py", line 121, in test_locale_optimized_territory
        self.assertEqual(locales.match_locale(locale, locale_list), expected_locale)
    AssertionError: 'fr-CH' != 'fr-BE'
    - fr-CH
    + fr-BE

With the `babel` update from 2.17.0 to 2.18.0 the population DB has been
updated (the test was implemented for the old values).

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-02-06 14:42:13 +01:00
dependabot[bot]
578e59a54e [upd] pypi: Bump the minor group with 5 updates
Bumps the minor group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [granian](https://github.com/emmett-framework/granian) | `2.6.1` | `2.7.0` |
| [granian[pname]](https://github.com/emmett-framework/granian) | `2.6.1` | `2.7.0` |
| [babel](https://github.com/python-babel/babel) | `2.17.0` | `2.18.0` |
| [granian[reload]](https://github.com/emmett-framework/granian) | `2.6.1` | `2.7.0` |
| [basedpyright](https://github.com/detachhead/basedpyright) | `1.37.2` | `1.37.4` |


Updates `granian` from 2.6.1 to 2.7.0
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.6.1...v2.7.0)

Updates `granian[pname]` from 2.6.1 to 2.7.0
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.6.1...v2.7.0)

Updates `babel` from 2.17.0 to 2.18.0
- [Release notes](https://github.com/python-babel/babel/releases)
- [Changelog](https://github.com/python-babel/babel/blob/master/CHANGES.rst)
- [Commits](https://github.com/python-babel/babel/compare/v2.17.0...v2.18.0)

Updates `granian[reload]` from 2.6.1 to 2.7.0
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.6.1...v2.7.0)

Updates `basedpyright` from 1.37.2 to 1.37.4
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.37.2...v1.37.4)

---
updated-dependencies:
- dependency-name: granian
  dependency-version: 2.7.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: granian[pname]
  dependency-version: 2.7.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: babel
  dependency-version: 2.18.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: granian[reload]
  dependency-version: 2.7.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: basedpyright
  dependency-version: 1.37.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-02-06 14:42:13 +01:00
dependabot[bot]
9ab8c36161 [upd] web-client (simple): Bump the minor group (#5722)
Bumps the minor group in /client/simple with 3 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [vite-bundle-analyzer](https://github.com/nonzzz/vite-bundle-analyzer).

Updates `@biomejs/biome` from 2.3.13 to 2.3.14
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.3.14/packages/@biomejs/biome)

Updates `@types/node` from 25.1.0 to 25.2.1
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `vite-bundle-analyzer` from 1.3.2 to 1.3.6
- [Release notes](https://github.com/nonzzz/vite-bundle-analyzer/releases)
- [Changelog](https://github.com/nonzzz/vite-bundle-analyzer/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nonzzz/vite-bundle-analyzer/compare/v1.3.2...v1.3.6)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.3.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 25.2.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: vite-bundle-analyzer
  dependency-version: 1.3.6
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-06 11:57:12 +01:00
dependabot[bot]
bd69e9c7ab [upd] web-client (simple): Bump vite from 8.0.0-beta.11 to 8.0.0-beta.13 in /client/simple (#5723)
* [upd] web-client (simple): Bump vite in /client/simple

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.11 to 8.0.0-beta.13.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.13/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.13
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [upd] themes: rebuild static

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2026-02-06 11:43:12 +01:00
github-actions[bot]
aeb3c0e274 [l10n] update translations from Weblate (#5726)
3f24736b5 - 2026-02-03 - AndersNordh <andersnordh@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-02-06 11:20:06 +01:00
dependabot[bot]
9f5dedabba [upd] github-actions: Bump github/codeql-action from 4.32.0 to 4.32.2 (#5721)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.0 to 4.32.2.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](b20883b0cd...45cbd0c69e)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.32.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-06 11:18:26 +01:00
dependabot[bot]
f7a608703d [upd] web-client (simple): Bump the minor group (#5709)
Bumps the minor group in /client/simple with 3 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [sort-package-json](https://github.com/keithamus/sort-package-json).

Updates `@biomejs/biome` from 2.3.11 to 2.3.13
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.3.13/packages/@biomejs/biome)

Updates `@types/node` from 25.0.10 to 25.1.0
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `sort-package-json` from 3.6.0 to 3.6.1
- [Release notes](https://github.com/keithamus/sort-package-json/releases)
- [Commits](https://github.com/keithamus/sort-package-json/compare/v3.6.0...v3.6.1)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.3.13
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 25.1.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: sort-package-json
  dependency-version: 3.6.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-03 11:44:34 +01:00
Ivan Gabaldon
92d37152c2 [upd] ci: static podman v5.7.1 (#5714) 2026-02-02 22:40:33 +01:00
dependabot[bot]
ad42b553bf [upd] web-client (simple): Bump vite in /client/simple (#5711)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.9 to 8.0.0-beta.11.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.11/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-30 19:56:55 +01:00
dependabot[bot]
1c292dd9a4 [upd] github-actions: Bump docker/login-action from 3.6.0 to 3.7.0 (#5710)
Bumps [docker/login-action](https://github.com/docker/login-action) from 3.6.0 to 3.7.0.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](5e57cd1181...c94ce9fb46)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-version: 3.7.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-30 19:41:00 +01:00
dependabot[bot]
2ad404a3bf [upd] github-actions: Bump github/codeql-action from 4.31.10 to 4.32.0 (#5707)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.10 to 4.32.0.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](cdefb33c0f...b20883b0cd)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.32.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-30 19:40:15 +01:00
dependabot[bot]
ca67782626 [upd] github-actions: Bump actions/cache from 5.0.2 to 5.0.3 (#5708)
Bumps [actions/cache](https://github.com/actions/cache) from 5.0.2 to 5.0.3.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](8b402f58fb...cdf6c1fa76)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: 5.0.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-30 19:39:55 +01:00
dependabot[bot]
0a4ea004cf [upd] pypi: Bump basedpyright from 1.37.1 to 1.37.2 in the minor group (#5712)
Bumps the minor group with 1 update: [basedpyright](https://github.com/detachhead/basedpyright).

Updates `basedpyright` from 1.37.1 to 1.37.2
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.37.1...v1.37.2)
2026-01-30 08:41:35 +01:00
github-actions[bot]
15133c2f25 [data] update searx.data - update_firefox_version.py (#5699)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-01-29 10:29:28 +01:00
github-actions[bot]
a7f15f4289 [data] update searx.data - update_wikidata_units.py (#5700)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-01-29 10:28:54 +01:00
github-actions[bot]
ac4b1275a3 [data] update searx.data - update_currencies.py (#5702)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-01-29 10:28:22 +01:00
github-actions[bot]
bf2e7f8fc5 [data] update searx.data - update_engine_descriptions.py (#5703)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-01-29 10:27:07 +01:00
github-actions[bot]
cdbf41bb9b [data] update searx.data - update_ahmia_blacklist.py (#5701)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-01-29 10:24:33 +01:00
Austin-Olacsi
966988e360 [feat] engines: add artstation engine (#5689) 2026-01-27 17:18:46 +01:00
Ivan Gabaldon
a9877aba3e [fix] themes: module resolution (#5694)
Vite should not pregen static paths on build, but rather compute the relative path at runtime.

- https://vite.dev/config/shared-options#base

Closes: https://github.com/searxng/searxng/issues/5561
2026-01-27 11:32:23 +01:00
Hu Butui
da6ab39049 [fix] iqiyi: Add support for multiple videos per album
Add support for albums containing multiple videos in iqiyi engine. When
albumInfo contains a "videos" list, process each video individually to
create separate search results for each episode/video instead of a single
result for the entire album.

Also get video length from `duration` instead of `subscriptContent`.

Signed-off-by: Hu Butui <hot123tea123@gmail.com>
2026-01-26 19:46:05 +01:00
Austin-Olacsi
5271c3b9e1 [fix] pixiv: update pixiv proxy docs URL in settings.yml 2026-01-26 19:31:10 +01:00
Markus Heiser
eea1892863 [fix] presearch - AttributeError: 'NoneType' object has no attribute 'territory' (#5687)
For unknown locales, the return value of::

    locales.get_locale(params['searxng_locale'])

is None which cuase the following issue::

    ERROR   searx.engines.presearch       : exception : 'NoneType' object has no attribute 'territory'
    Traceback (most recent call last):
      File "search/processors/online.py", line 256, in search
        search_results = self._search_basic(query, params)
      File "search/processors/online.py", line 231, in _search_basic
        self.engine.request(query, params)
        ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
      File "engines/presearch.py", line 153, in request
        request_id, cookies = _get_request_id(query, params)
                              ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
      File "engines/presearch.py", line 140, in _get_request_id
        if l.territory:
           ^^^^^^^^^^^
    AttributeError: 'NoneType' object has no attribute 'territory'

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2026-01-24 07:25:49 +01:00
dependabot[bot]
c97d4d9b6c [upd] pypi: Bump selenium from 4.39.0 to 4.40.0 in the minor group (#5684)
Bumps the minor group with 1 update: [selenium](https://github.com/SeleniumHQ/Selenium).


Updates `selenium` from 4.39.0 to 4.40.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.39.0...selenium-4.40.0)

---
updated-dependencies:
- dependency-name: selenium
  dependency-version: 4.40.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 10:57:27 +01:00
dependabot[bot]
38de71b3e0 [upd] web-client (simple): Bump vite in /client/simple (#5683)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.8 to 8.0.0-beta.9.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.9/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.9
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 10:45:21 +01:00
dependabot[bot]
a77d5d1258 [upd] web-client (simple): Bump @types/node (#5680)
Bumps the minor group in /client/simple with 1 update: [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node).


Updates `@types/node` from 25.0.9 to 25.0.10
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-version: 25.0.10
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 10:15:24 +01:00
dependabot[bot]
68944b4484 [upd] github-actions: Bump peter-evans/create-pull-request (#5681)
Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 8.0.0 to 8.1.0.
- [Release notes](https://github.com/peter-evans/create-pull-request/releases)
- [Commits](98357b18bf...c0f553fe54)

---
updated-dependencies:
- dependency-name: peter-evans/create-pull-request
  dependency-version: 8.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 10:14:17 +01:00
dependabot[bot]
c60f59609e [upd] github-actions: Bump actions/setup-python from 6.1.0 to 6.2.0 (#5682)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 6.1.0 to 6.2.0.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](83679a892e...a309ff8b42)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-version: 6.2.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 10:13:22 +01:00
dependabot[bot]
8473b030c5 [upd] github-actions: Bump actions/cache from 5.0.1 to 5.0.2 (#5685)
Bumps [actions/cache](https://github.com/actions/cache) from 5.0.1 to 5.0.2.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](9255dc7a25...8b402f58fb)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: 5.0.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 10:10:38 +01:00
dependabot[bot]
9dd3baf45c [upd] github-actions: Bump actions/checkout from 6.0.1 to 6.0.2 (#5679)
Bumps [actions/checkout](https://github.com/actions/checkout) from 6.0.1 to 6.0.2.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](8e8c483db8...de0fac2e45)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 6.0.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 10:10:14 +01:00
Hu Butui
410996df9e [fix] iqiyi: update album_info key
subscriptionContent -> subscriptContent

Signed-off-by: Hu Butui <hot123tea123@gmail.com>
2026-01-20 13:39:29 +01:00
Bnyro
313fda426c [fix] annas archive: rotate between available backup domains
- closes https://github.com/searxng/searxng/issues/5633
2026-01-20 13:39:19 +01:00
mg95
277be51bc0 [fix] google: decode urls before passing them onto results (#5674)
Fixes #5673
2026-01-19 21:21:22 +01:00
dependabot[bot]
2d9f213ca8 Bump wlc from 1.17.1 to 1.17.2 in the pip group across 1 directory (#5672)
Bumps the pip group with 1 update in the / directory: [wlc](https://github.com/WeblateOrg/wlc).


Updates `wlc` from 1.17.1 to 1.17.2
- [Release notes](https://github.com/WeblateOrg/wlc/releases)
- [Changelog](https://github.com/WeblateOrg/wlc/blob/main/CHANGES.rst)
- [Commits](https://github.com/WeblateOrg/wlc/compare/1.17.1...1.17.2)

---
updated-dependencies:
- dependency-name: wlc
  dependency-version: 1.17.2
  dependency-type: direct:development
  dependency-group: pip
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-16 19:42:07 +01:00
dependabot[bot]
97814c62a8 [upd] web-client (simple): Bump vite from 8.0.0-beta.7 to 8.0.0-beta.8 in /client/simple (#5668)
* [upd] web-client (simple): Bump vite in /client/simple

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.7 to 8.0.0-beta.8.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.8/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [upd] theme: rebuild static

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2026-01-16 10:58:36 +01:00
dependabot[bot]
ee4943ebd7 [upd] web-client (simple): Bump @types/node (#5667)
Bumps the minor group in /client/simple with 1 update: [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node).


Updates `@types/node` from 25.0.3 to 25.0.9
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-version: 25.0.9
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-16 10:22:50 +01:00
dependabot[bot]
086c1533a4 [upd] github-actions: Bump JamesIves/github-pages-deploy-action (#5666)
Bumps [JamesIves/github-pages-deploy-action](https://github.com/jamesives/github-pages-deploy-action) from 4.7.6 to 4.8.0.
- [Release notes](https://github.com/jamesives/github-pages-deploy-action/releases)
- [Commits](9d877eea73...d92aa235d0)

---
updated-dependencies:
- dependency-name: JamesIves/github-pages-deploy-action
  dependency-version: 4.8.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-16 10:22:26 +01:00
dependabot[bot]
55c01c0757 [upd] github-actions: Bump github/codeql-action from 4.31.9 to 4.31.10 (#5665)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.9 to 4.31.10.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](5d4e8d1aca...cdefb33c0f)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.10
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-16 10:21:56 +01:00
dependabot[bot]
279e098168 [upd] github-actions: Bump actions/setup-node from 6.1.0 to 6.2.0 (#5664)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 6.1.0 to 6.2.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](395ad32622...6044e13b5d)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 6.2.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-16 10:21:32 +01:00
Bnyro
c4f1b216d1 [feat] brave: show related query suggestions (#5614) 2026-01-16 08:39:56 +01:00
Bnyro
b93a68bb48 [feat] engines: add fynd engine (#5616)
The engine is quite fast (< 30ms) and provides very
decent search results for most short queries.

More information:
- <https://fynd.com>
- <https://seirdy.one/posts/2021/03/10/search-engines-with-own-indexes/>
2026-01-16 08:39:16 +01:00
dependabot[bot]
3f80eb80d0 [upd] pypi: Bump the minor group with 3 updates (#5670)
Bumps the minor group with 3 updates: [tomli](https://github.com/hukkin/tomli), [yamllint](https://github.com/adrienverge/yamllint) and [wlc](https://github.com/WeblateOrg/wlc).


Updates `tomli` from 2.3.0 to 2.4.0
- [Changelog](https://github.com/hukkin/tomli/blob/master/CHANGELOG.md)
- [Commits](https://github.com/hukkin/tomli/compare/2.3.0...2.4.0)

Updates `yamllint` from 1.37.1 to 1.38.0
- [Release notes](https://github.com/adrienverge/yamllint/releases)
- [Changelog](https://github.com/adrienverge/yamllint/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/adrienverge/yamllint/compare/v1.37.1...v1.38.0)

Updates `wlc` from 1.16.1 to 1.17.1
- [Release notes](https://github.com/WeblateOrg/wlc/releases)
- [Changelog](https://github.com/WeblateOrg/wlc/blob/main/CHANGES.rst)
- [Commits](https://github.com/WeblateOrg/wlc/compare/1.16.1...1.17.1)
2026-01-16 08:36:50 +01:00
github-actions[bot]
697f53ecde [l10n] update translations from Weblate (#5663)
9df66899a - 2026-01-12 - danilo-jlle <danilo-jlle@noreply.codeberg.org>
6152814e4 - 2026-01-10 - Maoyue_OUO <maoyue_ouo@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2026-01-16 08:24:58 +01:00
mg95
cf74e1d9e9 [fix] google: switch to using GSA for iPhone useragent 2026-01-11 16:21:01 +01:00
Bnyro
44405bd03c [fix] yep: fix 403 forbidden errors
Apparently, yep has been broken for a while. Measures to fix it:
- only use HTTP/1.1, because our HTTP2 client gets fingerprinted and blocked
- send the `Origin` HTTP header
2026-01-10 12:46:22 +01:00
Austin-Olacsi
26e275222b [feat] engines: add CachyOS Packages Search 2026-01-10 12:45:27 +01:00
Elvyria
ae48f50245 [mod] replace #suggestions list wrapper <div> with <ul> (#5575)
This PR removes the "dot" prefix value from the `#suggestions` list's entries and adds it back via CSS instead. It makes styling easier and less hacky for those who are interested, removing the dot with just styles is currently not as easy as I would like it to be.
2026-01-10 10:18:49 +01:00
dependabot[bot]
b83e88ea78 [upd] pypi: Bump the minor group with 5 updates (#5648)
Bumps the minor group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [granian](https://github.com/emmett-framework/granian) | `2.6.0` | `2.6.1` |
| [granian[pname]](https://github.com/emmett-framework/granian) | `2.6.0` | `2.6.1` |
| [typer-slim](https://github.com/fastapi/typer) | `0.21.0` | `0.21.1` |
| [granian[reload]](https://github.com/emmett-framework/granian) | `2.6.0` | `2.6.1` |
| [basedpyright](https://github.com/detachhead/basedpyright) | `1.36.2` | `1.37.1` |


Updates `granian` from 2.6.0 to 2.6.1
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.6.0...v2.6.1)

Updates `granian[pname]` from 2.6.0 to 2.6.1
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.6.0...v2.6.1)

Updates `typer-slim` from 0.21.0 to 0.21.1
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.21.0...0.21.1)

Updates `granian[reload]` from 2.6.0 to 2.6.1
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.6.0...v2.6.1)

Updates `basedpyright` from 1.36.2 to 1.37.1
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.36.2...v1.37.1)

---
updated-dependencies:
- dependency-name: granian
  dependency-version: 2.6.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: granian[pname]
  dependency-version: 2.6.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: typer-slim
  dependency-version: 0.21.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: granian[reload]
  dependency-version: 2.6.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: basedpyright
  dependency-version: 1.37.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-09 11:17:12 +01:00
dependabot[bot]
a684b91fe7 [upd] web-client (simple): Bump vite from 8.0.0-beta.5 to 8.0.0-beta.7 in /client/simple (#5649)
* [upd] web-client (simple): Bump vite in /client/simple

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.5 to 8.0.0-beta.7.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.7/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.7
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [fix] themes: rebuild static

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2026-01-09 11:15:14 +01:00
dependabot[bot]
27d965234a [upd] web-client (simple): Bump @biomejs/biome (#5646)
Bumps the minor group in /client/simple with 1 update: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome).

Updates `@biomejs/biome` from 2.3.10 to 2.3.11
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.3.11/packages/@biomejs/biome)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.3.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-09 11:10:45 +01:00
dependabot[bot]
c769c194d6 [upd] web-client (simple): Bump stylelint-config-standard-less from 3.0.1 to 4.0.1 in /client/simple (#5647)
* [upd] web-client (simple): Bump stylelint-config-standard-less

Bumps [stylelint-config-standard-less](https://github.com/stylelint-less/stylelint-less/tree/HEAD/packages/stylelint-config-standard-less) from 3.0.1 to 4.0.1.
- [Release notes](https://github.com/stylelint-less/stylelint-less/releases)
- [Changelog](https://github.com/stylelint-less/stylelint-less/blob/main/packages/stylelint-config-standard-less/CHANGELOG.md)
- [Commits](https://github.com/stylelint-less/stylelint-less/commits/stylelint-config-standard-less@4.0.1/packages/stylelint-config-standard-less)

---
updated-dependencies:
- dependency-name: stylelint-config-standard-less
  dependency-version: 4.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* [fix] themes: rebuild static

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2026-01-09 11:06:11 +01:00
searxng-bot
65186c3301 [l10n] update translations from Weblate
14c165051 - 2026-01-07 - Minami-o <minami-o@noreply.codeberg.org>
2026-01-09 10:39:57 +01:00
dependabot[bot]
f6a428b60d [upd] pypi: Bump certifi from 2025.11.12 to 2026.1.4
Bumps [certifi](https://github.com/certifi/python-certifi) from 2025.11.12 to 2026.1.4.
- [Commits](https://github.com/certifi/python-certifi/compare/2025.11.12...2026.01.04)

---
updated-dependencies:
- dependency-name: certifi
  dependency-version: 2026.1.4
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-01-09 10:37:06 +01:00
dependabot[bot]
3d88876a32 [upd] pypi: Bump types-lxml from 2025.11.25 to 2026.1.1 (#5622)
Bumps [types-lxml](https://github.com/abelcheung/types-lxml) from 2025.11.25 to 2026.1.1.

- [Release notes](https://github.com/abelcheung/types-lxml/releases)
- [Commits](https://github.com/abelcheung/types-lxml/compare/2025.11.25...2026.01.01)
2026-01-02 08:45:31 +01:00
github-actions[bot]
09bedef409 [l10n] update translations from Weblate (#5623)
0ebc2ba84 - 2025-12-30 - AndersNordh <andersnordh@noreply.codeberg.org>
012b6aa25 - 2025-12-26 - tace16 <tace16@noreply.codeberg.org>
2026-01-02 08:43:37 +01:00
github-actions[bot]
a5c946a321 [data] update searx.data - update_external_bangs.py (#5607) 2025-12-30 08:29:05 +01:00
Ivan Gabaldon
29042d8e5a [mod] docs: remove libera.chat channel (#5613)
Internal discussion (lack of time/moderation)
2025-12-30 08:21:39 +01:00
Tommaso Colella
c57db45672 [fix] 360search: fix engine by adding cookie caching
Co-authored-by: Bnyro <bnyro@tutanota.com>
2025-12-29 15:26:07 +01:00
searxng-bot
9491b514c9 [data] update searx.data - update_engine_descriptions.py 2025-12-29 15:24:06 +01:00
Tommaso Colella
320c317719 [mod] settings.yml: set engines that require an api key to inactive by default 2025-12-29 15:20:43 +01:00
Tommaso Colella
abae17e6fc [mod] docs: better explanation for search api usage and format support (#5574) 2025-12-29 15:04:33 +01:00
Austin-Olacsi
3baf5c38fc [fix] bilibili engine: send referer header 2025-12-29 14:59:08 +01:00
searxng-bot
ce46f30739 [data] update searx.data - update_currencies.py 2025-12-29 13:48:16 +01:00
searxng-bot
65a95539f1 [data] update searx.data - update_ahmia_blacklist.py 2025-12-29 13:47:12 +01:00
searxng-bot
874dc3f5ea [data] update searx.data - update_firefox_version.py 2025-12-29 13:46:57 +01:00
searxng-bot
7941719371 [data] update searx.data - update_wikidata_units.py 2025-12-29 13:46:46 +01:00
Aadniz
fa9729226b [fix] ahmia engine: increase timeout to 20 seconds 2025-12-26 18:22:15 +01:00
Aadniz
9df177af85 [fix] ahmia engine: Remove comment for EngineCache 2025-12-26 18:22:15 +01:00
Aadniz
f45123356b [fix] ahmia engine: requires rotating tokens to work
Ahmia recently implemented a 60 minute rotating token system when searching.

This fix uses the cache and updates the tokens on every request.
2025-12-26 18:22:15 +01:00
Aadniz
8851f4d6b1 [fix] searx.network: fix string concatenation of proxy error message 2025-12-26 18:07:51 +01:00
searxng-bot
f954423101 [l10n] update translations from Weblate
3a4b5f36f - 2025-12-24 - Stzyxh <stzyxh@noreply.codeberg.org>
e72be22b9 - 2025-12-23 - gallegonovato <gallegonovato@noreply.codeberg.org>
18a59dd67 - 2025-12-22 - Outbreak2096 <outbreak2096@noreply.codeberg.org>
bf212eb3c - 2025-12-22 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
3525b547a - 2025-12-19 - MaiuZ <maiuz@noreply.codeberg.org>
2025-12-26 11:51:22 +01:00
dependabot[bot]
95e63ac32d [upd] web-client (simple): Bump vite in /client/simple
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.3 to 8.0.0-beta.5.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.5/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-26 11:47:23 +01:00
dependabot[bot]
fc6e59d3ec [upd] pypi: Bump the minor group with 2 updates (#5598)
Bumps the minor group with 2 updates: [typer-slim](https://github.com/fastapi/typer) and [basedpyright](https://github.com/detachhead/basedpyright).


Updates `typer-slim` from 0.20.0 to 0.21.0
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.20.0...0.21.0)

Updates `basedpyright` from 1.36.1 to 1.36.2
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.36.1...v1.36.2)

---
updated-dependencies:
- dependency-name: typer-slim
  dependency-version: 0.21.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: basedpyright
  dependency-version: 1.36.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
2025-12-26 10:03:42 +01:00
dependabot[bot]
da45859f32 [upd] pypi: Bump the minor group with 2 updates
Bumps the minor group with 2 updates: [selenium](https://github.com/SeleniumHQ/Selenium) and [basedpyright](https://github.com/detachhead/basedpyright).


Updates `selenium` from 4.38.0 to 4.39.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.38.0...selenium-4.39.0)

Updates `basedpyright` from 1.35.0 to 1.36.1
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.35.0...v1.36.1)

---
updated-dependencies:
- dependency-name: selenium
  dependency-version: 4.39.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: basedpyright
  dependency-version: 1.36.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-25 19:55:01 +01:00
Ivan Gabaldon
8bf600cc62 [fix] themes: rebuild static 2025-12-19 17:50:23 +00:00
dependabot[bot]
aa607a379a [upd] web-client (simple): Bump the minor group
Bumps the minor group in /client/simple with 6 updates:

| Package | From | To |
| --- | --- | --- |
| [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) | `2.3.8` | `2.3.10` |
| [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) | `25.0.1` | `25.0.3` |
| [edge.js](https://github.com/edge-js/edge) | `6.3.0` | `6.4.0` |
| [less](https://github.com/less/less.js) | `4.4.2` | `4.5.1` |
| [sort-package-json](https://github.com/keithamus/sort-package-json) | `3.5.1` | `3.6.0` |
| [vite-bundle-analyzer](https://github.com/nonzzz/vite-bundle-analyzer) | `1.3.1` | `1.3.2` |

Updates `@biomejs/biome` from 2.3.8 to 2.3.10
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.3.10/packages/@biomejs/biome)

Updates `@types/node` from 25.0.1 to 25.0.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `edge.js` from 6.3.0 to 6.4.0
- [Release notes](https://github.com/edge-js/edge/releases)
- [Changelog](https://github.com/edge-js/edge/blob/6.x/CHANGELOG.md)
- [Commits](https://github.com/edge-js/edge/compare/v6.3.0...v6.4.0)

Updates `less` from 4.4.2 to 4.5.1
- [Release notes](https://github.com/less/less.js/releases)
- [Changelog](https://github.com/less/less.js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/less/less.js/commits)

Updates `sort-package-json` from 3.5.1 to 3.6.0
- [Release notes](https://github.com/keithamus/sort-package-json/releases)
- [Commits](https://github.com/keithamus/sort-package-json/compare/v3.5.1...v3.6.0)

Updates `vite-bundle-analyzer` from 1.3.1 to 1.3.2
- [Release notes](https://github.com/nonzzz/vite-bundle-analyzer/releases)
- [Changelog](https://github.com/nonzzz/vite-bundle-analyzer/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nonzzz/vite-bundle-analyzer/compare/v1.3.1...v1.3.2)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.3.10
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 25.0.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: edge.js
  dependency-version: 6.4.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: less
  dependency-version: 4.5.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: sort-package-json
  dependency-version: 3.6.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: vite-bundle-analyzer
  dependency-version: 1.3.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-19 17:50:23 +00:00
dependabot[bot]
6ebd3f4d35 [upd] web-client (simple): Bump vite in /client/simple
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.2 to 8.0.0-beta.3.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.3/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-19 17:30:19 +00:00
searxng-bot
9072c77aea [l10n] update translations from Weblate
6fd00e66a - 2025-12-18 - dtalens <dtalens@noreply.codeberg.org>
037518f3b - 2025-12-17 - dtalens <dtalens@noreply.codeberg.org>
2025-12-19 08:37:40 +00:00
dependabot[bot]
c32b8100c3 [upd] github-actions: Bump actions/cache from 5.0.0 to 5.0.1
Bumps [actions/cache](https://github.com/actions/cache) from 5.0.0 to 5.0.1.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](a783357455...9255dc7a25)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: 5.0.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-19 08:35:15 +00:00
dependabot[bot]
f93257941e [upd] github-actions: Bump github/codeql-action from 4.31.7 to 4.31.9
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.7 to 4.31.9.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](cf1bb45a27...5d4e8d1aca)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.9
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-19 08:34:32 +00:00
Guanzhong Chen
896863802e [fix] engine: brave - BrotliDecoderDecompressStream encoding issue (#5572)
For some reason, I keep getting this error from the brave engine:

    httpx.DecodingError: BrotliDecoderDecompressStream failed while processing the stream

Forcing the server to use either gzip or deflate fixes this issue.

This makes the brave engine work when the server seems to be encoding brotli incorrectly, or at least in a way incompatible with certain installs.

Related:

- https://github.com/searxng/searxng/pull/1787
- https://github.com/searxng/searxng/pull/5536
2025-12-17 09:39:03 +01:00
searxng-bot
920b40253c [l10n] update translations from Weblate
e23dc20f7 - 2025-12-11 - SomeTr <sometr@noreply.codeberg.org>
eb67f948f - 2025-12-11 - artnay <artnay@noreply.codeberg.org>
d4fdfc449 - 2025-12-10 - SomeTr <sometr@noreply.codeberg.org>
0f02ac7cd - 2025-12-10 - IcewindX <icewindx@noreply.codeberg.org>
533ae3947 - 2025-12-11 - return42 <return42@noreply.codeberg.org>
19fe65dc7 - 2025-12-11 - return42 <return42@noreply.codeberg.org>
bca557cea - 2025-12-09 - Hangry-Studios <hangry-studios@noreply.codeberg.org>
e43e9a299 - 2025-12-10 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
c98083cef - 2025-12-09 - eudemo <eudemo@noreply.codeberg.org>
316225017 - 2025-12-08 - aindriu80 <aindriu80@noreply.codeberg.org>
1b827e5a4 - 2025-12-08 - Aadniz <aadniz@noreply.codeberg.org>
68e760f9b - 2025-12-09 - kratos <makesocialfoss32@keemail.me>
99945ac31 - 2025-12-07 - lucasmz.dev <lucasmz.dev@noreply.codeberg.org>
56602eb75 - 2025-12-07 - Fjuro <fjuro@alius.cz>
df092e811 - 2025-12-06 - c2qd <c2qd@noreply.codeberg.org>
12c25cd85 - 2025-12-06 - Outbreak2096 <outbreak2096@noreply.codeberg.org>
081243428 - 2025-12-05 - SomeTr <sometr@noreply.codeberg.org>
66362c02d - 2025-12-06 - ghose <ghose@noreply.codeberg.org>
2025-12-12 20:23:43 +00:00
dependabot[bot]
07440e3332 [upd] web-client (simple): Bump the minor group
Bumps the minor group in /client/simple with 2 updates: [sort-package-json](https://github.com/keithamus/sort-package-json) and [vite-bundle-analyzer](https://github.com/nonzzz/vite-bundle-analyzer).

Updates `sort-package-json` from 3.5.0 to 3.5.1
- [Release notes](https://github.com/keithamus/sort-package-json/releases)
- [Commits](https://github.com/keithamus/sort-package-json/compare/v3.5.0...v3.5.1)

Updates `vite-bundle-analyzer` from 1.2.3 to 1.3.1
- [Release notes](https://github.com/nonzzz/vite-bundle-analyzer/releases)
- [Changelog](https://github.com/nonzzz/vite-bundle-analyzer/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nonzzz/vite-bundle-analyzer/compare/v1.2.3...v1.3.1)

---
updated-dependencies:
- dependency-name: sort-package-json
  dependency-version: 3.5.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: vite-bundle-analyzer
  dependency-version: 1.3.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-12 20:22:48 +00:00
dependabot[bot]
1827dfc071 [upd] web-client (simple): Bump @types/node in /client/simple
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 24.10.1 to 25.0.1.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-version: 25.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-12 20:13:11 +00:00
dependabot[bot]
c46aecd4e3 [upd] web-client (simple): Bump vite in /client/simple
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 8.0.0-beta.0 to 8.0.0-beta.2.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.0-beta.2/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 8.0.0-beta.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-12 19:59:31 +00:00
dependabot[bot]
21bf8a6973 [upd] github-actions: Bump peter-evans/create-pull-request
Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 7.0.9 to 8.0.0.
- [Release notes](https://github.com/peter-evans/create-pull-request/releases)
- [Commits](84ae59a2cd...98357b18bf)

---
updated-dependencies:
- dependency-name: peter-evans/create-pull-request
  dependency-version: 8.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-12 19:56:18 +00:00
dependabot[bot]
f5475ba782 [upd] github-actions: Bump JamesIves/github-pages-deploy-action
Bumps [JamesIves/github-pages-deploy-action](https://github.com/jamesives/github-pages-deploy-action) from 4.7.4 to 4.7.6.
- [Release notes](https://github.com/jamesives/github-pages-deploy-action/releases)
- [Commits](4a3abc783e...9d877eea73)

---
updated-dependencies:
- dependency-name: JamesIves/github-pages-deploy-action
  dependency-version: 4.7.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-12 19:52:52 +00:00
dependabot[bot]
265f15498c [upd] github-actions: Bump github/codeql-action from 4.31.6 to 4.31.7
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.6 to 4.31.7.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](fe4161a26a...cf1bb45a27)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.7
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-12 19:51:40 +00:00
dependabot[bot]
666409ec7e [upd] github-actions: Bump actions/cache from 4.3.0 to 5.0.0
Bumps [actions/cache](https://github.com/actions/cache) from 4.3.0 to 5.0.0.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](0057852bfa...a783357455)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-12 19:51:17 +00:00
Viktor
b719d559b6 [feat] marginalia: switch to the new, improved API version 2025-12-09 18:18:37 +01:00
Austin-Olacsi
9d3ec9a2a2 [feat] pixiv engine: add filter for AI generated images 2025-12-07 23:34:16 +01:00
Ivan Gabaldon
74ec225ad1 [fix] themes: clear search input (#5540)
* [fix] themes: clear search input

Closes https://github.com/searxng/searxng/issues/5539

* [fix] themes: rebuild static
2025-12-07 13:26:01 +00:00
Markus Heiser
b5a1a092f1 [debug] partial revert of 5e0e1c6b3 (#5535)
Issue #5490 was caused by a regression of GH action in v6.0.0, updating to
v6.0.1 [2] fixed our workflow and debug messages are no longer needed.

[1] https://github.com/searxng/searxng/issues/5490#issuecomment-3616230451
[2] https://github.com/searxng/searxng/pull/5530

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-12-06 09:15:56 +01:00
dependabot[bot]
ddc6d68114 [upd] pypi: Bump the minor group with 2 updates (#5527)
Bumps the minor group with 2 updates: [pylint](https://github.com/pylint-dev/pylint) and [basedpyright](https://github.com/detachhead/basedpyright).


Updates `pylint` from 4.0.3 to 4.0.4
- [Release notes](https://github.com/pylint-dev/pylint/releases)
- [Commits](https://github.com/pylint-dev/pylint/compare/v4.0.3...v4.0.4)

Updates `basedpyright` from 1.34.0 to 1.35.0
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.34.0...v1.35.0)
2025-12-05 15:39:35 +01:00
github-actions[bot]
32eb84d6d3 [l10n] update translations from Weblate (#5532) 2025-12-05 15:38:35 +01:00
Ivan Gabaldon
da6c635ea2 [upd] themes: update vite 2025-12-05 11:14:26 +00:00
dependabot[bot]
e34c356e64 [upd] web-client (simple): Bump the minor group
Bumps the minor group in /client/simple with 2 updates: [browserslist](https://github.com/browserslist/browserslist) and [mathjs](https://github.com/josdejong/mathjs).

Updates `browserslist` from 4.28.0 to 4.28.1
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.28.0...4.28.1)

Updates `mathjs` from 15.0.0 to 15.1.0
- [Changelog](https://github.com/josdejong/mathjs/blob/develop/HISTORY.md)
- [Commits](https://github.com/josdejong/mathjs/compare/v15.0.0...v15.1.0)

---
updated-dependencies:
- dependency-name: browserslist
  dependency-version: 4.28.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: mathjs
  dependency-version: 15.1.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-05 10:42:18 +00:00
dependabot[bot]
7017393647 [upd] github-actions: Bump actions/setup-node from 6.0.0 to 6.1.0
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 6.0.0 to 6.1.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](2028fbc5c2...395ad32622)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 6.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-05 10:26:25 +00:00
dependabot[bot]
aa49f5b933 [upd] github-actions: Bump github/codeql-action from 4.31.5 to 4.31.6
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.5 to 4.31.6.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](fdbfb4d275...fe4161a26a)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-05 10:25:37 +00:00
dependabot[bot]
3f91ac47e6 [upd] github-actions: Bump actions/checkout from 6.0.0 to 6.0.1
Bumps [actions/checkout](https://github.com/actions/checkout) from 6.0.0 to 6.0.1.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](1af3b93b68...8e8c483db8)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 6.0.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-05 10:14:41 +00:00
Markus Heiser
8c631b92ce [mod] setup.py package_data - use recursive globs for package_data
To test this patch build a python wheel::

    $ make clean py.build

and llok out if you are missing any files in the wheel::

    $ unzip -l dist/searxng-*-py3-none-any.whl

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-12-04 15:04:36 +01:00
leaty
0ebac144f5 [fix] py: sxng wheel build still broken
Directories chunk and img were not included

Signed-off-by: leaty <dev@leaty.net>
2025-12-04 15:04:36 +01:00
Markus Heiser
5e0e1c6b31 [debug] CI - add debug to trace issue #5490 (#5519)
The error only occurs in the CI action, which is why we need to commit the coded
debug.  As soon as the bug is identified and fixed, this commit can be reverted
/ the ``set -x`` can be removed from the code.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-12-04 14:07:22 +01:00
Markus Heiser
3c7545c6ce [fix] plugin unit-converter - remove leftovers (#5517)
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-12-04 07:51:48 +01:00
Austin-Olacsi
aba839195b [fix] findthatmeme: hardening the response against KeyErrors (#5516) 2025-12-04 07:13:05 +01:00
Bnyro
1f6ea41272 [fix] mojeek: first search page is rate-limited
Mojeek blocks all requests where the page offset parameter `s`
is set to 0, hence we may not set it for fetching the first results page.
2025-12-03 17:03:27 +01:00
Ivan Gabaldon
5450d22796 [fix] py: sxng wheel build broken (#5510)
Include everything inside `static/themes/` on SearXNG wheel creation.

```
2025-12-03 10:40:43,509 INFO🛞 adding
'searx/static/themes/simple/manifest.json' 2025-12-03 10:40:43,509
INFO🛞 adding 'searx/static/themes/simple/sxng-core.min.js'
2025-12-03 10:40:43,509 INFO🛞 adding
'searx/static/themes/simple/sxng-core.min.js.map' 2025-12-03
10:40:43,510 INFO🛞 adding
'searx/static/themes/simple/sxng-ltr.min.css' 2025-12-03 10:40:43,510
INFO🛞 adding 'searx/static/themes/simple/sxng-rss.min.css'
2025-12-03 10:40:43,511 INFO🛞 adding
'searx/static/themes/simple/sxng-rtl.min.css' 2025-12-03 10:40:43,511
INFO🛞 adding 'searx/static/themes/simple/chunk/13gvpunf.min.js'
2025-12-03 10:40:43,511 INFO🛞 adding
'searx/static/themes/simple/chunk/13gvpunf.min.js.map' 2025-12-03
10:40:43,516 INFO🛞 adding
'searx/static/themes/simple/chunk/BAcZkB_P.min.js' 2025-12-03
10:40:43,548 INFO🛞 adding
'searx/static/themes/simple/chunk/BAcZkB_P.min.js.map' 2025-12-03
10:40:43,551 INFO🛞 adding
'searx/static/themes/simple/chunk/CHkLfdMs.min.js' 2025-12-03
10:40:43,561 INFO🛞 adding
'searx/static/themes/simple/chunk/CHkLfdMs.min.js.map' 2025-12-03
10:40:43,562 INFO🛞 adding
'searx/static/themes/simple/chunk/CyyZ9XJS.min.js' 2025-12-03
10:40:43,562 INFO🛞 adding
'searx/static/themes/simple/chunk/CyyZ9XJS.min.js.map' 2025-12-03
10:40:43,562 INFO🛞 adding
'searx/static/themes/simple/chunk/DBO1tjH7.min.js' 2025-12-03
10:40:43,562 INFO🛞 adding
'searx/static/themes/simple/chunk/DBO1tjH7.min.js.map' 2025-12-03
10:40:43,562 INFO🛞 adding
'searx/static/themes/simple/chunk/Db5v-hxx.min.js' 2025-12-03
10:40:43,563 INFO🛞 adding
'searx/static/themes/simple/chunk/Db5v-hxx.min.js.map' 2025-12-03
10:40:43,563 INFO🛞 adding
'searx/static/themes/simple/chunk/DxJxX49r.min.js' 2025-12-03
10:40:43,563 INFO🛞 adding
'searx/static/themes/simple/chunk/DxJxX49r.min.js.map' 2025-12-03
10:40:43,563 INFO🛞 adding
'searx/static/themes/simple/chunk/KPZlR0ib.min.js' 2025-12-03
10:40:43,563 INFO🛞 adding
'searx/static/themes/simple/chunk/KPZlR0ib.min.js.map' 2025-12-03
10:40:43,563 INFO🛞 adding
'searx/static/themes/simple/chunk/Q2SRo2ED.min.js' 2025-12-03
10:40:43,563 INFO🛞 adding
'searx/static/themes/simple/chunk/Q2SRo2ED.min.js.map' 2025-12-03
10:40:43,563 INFO🛞 adding
'searx/static/themes/simple/chunk/gZqIRpW1.min.js' 2025-12-03
10:40:43,563 INFO🛞 adding
'searx/static/themes/simple/chunk/gZqIRpW1.min.js.map' 2025-12-03
10:40:43,564 INFO🛞 adding
'searx/static/themes/simple/img/empty_favicon.svg' 2025-12-03
10:40:43,564 INFO🛞 adding
'searx/static/themes/simple/img/favicon.png' 2025-12-03 10:40:43,564
INFO🛞 adding 'searx/static/themes/simple/img/favicon.svg'
2025-12-03 10:40:43,564 INFO🛞 adding
'searx/static/themes/simple/img/img_load_error.svg' 2025-12-03
10:40:43,564 INFO🛞 adding
'searx/static/themes/simple/img/searxng.png' 2025-12-03 10:40:43,564
INFO🛞 adding 'searx/static/themes/simple/img/searxng.svg'
2025-12-03 10:40:43,564 INFO🛞 adding
'searx/static/themes/simple/img/select-dark.svg' 2025-12-03 10:40:43,564
INFO🛞 adding 'searx/static/themes/simple/img/select-light.svg'
```
2025-12-03 11:21:18 +00:00
Bnyro
1174fde1f3 [feat] engines: add lucide icons (#5503) 2025-12-03 09:57:42 +01:00
Ivan Gabaldon
fb089ae297 [mod] client/simple: client plugins (#5406)
* [mod] client/simple: client plugins

Defines a new interface for client side *"plugins"* that coexist with server
side plugin system. Each plugin (e.g., `InfiniteScroll`) extends the base
`ts Plugin`. Client side plugins are independent and lazy‑loaded via `router.ts`
when their `load()` conditions are met. On each navigation request, all
applicable plugins are instanced.

Since these are client side plugins, we can only invoke them once DOM is fully
loaded. E.g. `Calculator` will not render a new `answer` block until fully
loaded and executed.

For some plugins, we might want to handle its availability in `settings.yml`
and toggle in UI, like we do for server side plugins. In that case, we extend
`py Plugin` instancing only the information and then checking client side if
[`settings.plugins`](1ad832b1dc/client/simple/src/js/toolkit.ts (L134))
array has the plugin id.

* [mod] client/simple: rebuild static
2025-12-02 10:18:00 +00:00
Bnyro
ab8224c939 [fix] brave: content description also contains website URL (#5502)
there are other classes like 'site-name-content' we don't want to match,
however only using contains(@class, 'content') would e.g. also match `site-name-content`
thus, we explicitly also require the spaces as class separator
2025-12-01 15:19:06 +01:00
github-actions[bot]
c954e71f87 [data] update searx.data - update_engine_descriptions.py (#5496) 2025-11-29 16:04:34 +01:00
Ivan Gabaldon
cbc04a839a [fix] py: missing module sniffio 2025-11-29 14:56:30 +00:00
searxng-bot
cb4a5abc8c [data] update searx.data - update_currencies.py 2025-11-29 14:54:09 +00:00
searxng-bot
07ff6e3ccc [data] update searx.data - update_wikidata_units.py 2025-11-29 09:00:05 +00:00
searxng-bot
cdaab944b4 [data] update searx.data - update_firefox_version.py 2025-11-29 08:58:56 +00:00
searxng-bot
6ecf32fd4a [data] update searx.data - update_ahmia_blacklist.py 2025-11-29 08:58:26 +00:00
Markus Heiser
20de10df4e Revert "[fix:py3.14] Struct fields aren't discovered in Python 3.14"
This reverts commit 8fdc59a760.
2025-11-28 13:38:37 +01:00
dependabot[bot]
673c29efeb [upd] pypi: Bump the minor group with 2 updates
Bumps the minor group with 2 updates: [msgspec](https://github.com/jcrist/msgspec) and [types-lxml](https://github.com/abelcheung/types-lxml).


Updates `msgspec` from 0.19.0 to 0.20.0
- [Release notes](https://github.com/jcrist/msgspec/releases)
- [Changelog](https://github.com/jcrist/msgspec/blob/main/docs/changelog.md)
- [Commits](https://github.com/jcrist/msgspec/compare/0.19.0...0.20.0)

Updates `types-lxml` from 2025.8.25 to 2025.11.25
- [Release notes](https://github.com/abelcheung/types-lxml/releases)
- [Commits](https://github.com/abelcheung/types-lxml/compare/2025.08.25...2025.11.25)

---
updated-dependencies:
- dependency-name: msgspec
  dependency-version: 0.20.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: types-lxml
  dependency-version: 2025.11.25
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-28 13:38:37 +01:00
dependabot[bot]
c4abf40e6e [upd] web-client (simple): Bump the minor group
Bumps the minor group in /client/simple with 3 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [sort-package-json](https://github.com/keithamus/sort-package-json) and [stylelint](https://github.com/stylelint/stylelint).

Updates `@biomejs/biome` from 2.3.7 to 2.3.8
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.3.8/packages/@biomejs/biome)

Updates `sort-package-json` from 3.4.0 to 3.5.0
- [Release notes](https://github.com/keithamus/sort-package-json/releases)
- [Commits](https://github.com/keithamus/sort-package-json/compare/v3.4.0...v3.5.0)

Updates `stylelint` from 16.25.0 to 16.26.0
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/16.25.0...16.26.0)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.3.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: sort-package-json
  dependency-version: 3.5.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: stylelint
  dependency-version: 16.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-28 10:13:02 +00:00
dependabot[bot]
39b9922609 [upd] github-actions: Bump actions/setup-python from 6.0.0 to 6.1.0
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 6.0.0 to 6.1.0.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](e797f83bcb...83679a892e)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-version: 6.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-28 09:28:12 +00:00
dependabot[bot]
7018e6583b [upd] github-actions: Bump peter-evans/create-pull-request
Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 7.0.8 to 7.0.9.
- [Release notes](https://github.com/peter-evans/create-pull-request/releases)
- [Commits](271a8d0340...84ae59a2cd)

---
updated-dependencies:
- dependency-name: peter-evans/create-pull-request
  dependency-version: 7.0.9
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-28 09:27:25 +00:00
dependabot[bot]
b957e587da [upd] github-actions: Bump github/codeql-action from 4.31.4 to 4.31.5
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.4 to 4.31.5.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](e12f017898...fdbfb4d275)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-28 09:25:18 +00:00
Markus Heiser
ebb9ea4571 [fix] brave engines - web, images & videos (#5478)
brave web:
  xpath selectors needed to be justified

brave images & videos:
  The JS code with the JS object was read incorrectly; not always, but quite
  often, it led to exceptions when the Python data structure was created from it.

BTW: A complete review was conducted and corrections or additions were made to
the type definitions.

To test all brave engines in once::

    !br !brimg !brvid !brnews weather

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-25 13:28:47 +01:00
Markus Heiser
54a97e1043 [mod] replace js_variable_to_python by js_obj_str_to_python (#2792) (#5477)
This patch is based on PR #2792 (old PR from 2023)

- js_obj_str_to_python handle more cases
- bring tests from chompjs ..
- comment out tests do not pass

The tests from chompjs give some overview of what is not implemented.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-25 12:51:08 +01:00
Markus Heiser
0ee78c19dd [mod] yandex engines: all egine should use one network
- The three Yandex engines should use the same network context.
- There is no reason to set these engines inactive

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-25 11:50:18 +01:00
Aadniz
bcc7a5eb2e [mod] yandex engine: add supported languages
Add support for Yandex's supported languages; Russian, English, Belarusian,
French, German, Indonesian, Kazakh, Tatar, Turkish and Ukrainian.
2025-11-25 11:50:18 +01:00
Markus Heiser
2313b972a3 [fix] engines: base URL can be a list or a string, but its not None!
The code injection and monkey patching examine the names in the module of the
engine; if a variable there starts without an underscore and has the value None,
then this variable needs to be configured. This outdated concept does not fit
engines that may have multiple URLs. At least not as long as the value of the
base URL (list) is None.

The default is now an empty list instead of None

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-25 06:25:45 +01:00
Markus Heiser
989b49335c [fix] engines initialization - if engine load fails, set to inactive
- if engine load fails, set the engine to inactive
- dont' load a engine, when the config says its inactive

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-25 06:25:45 +01:00
Markus Heiser
3f30831640 [fix] don't raise fatal exception when engine isn't available
When wikidata or any other engine with a init method (is active!)  raises an
exception in it's init method, the engine is never registered.

[1] https://github.com/searxng/searxng/issues/5456#issuecomment-3567790287

Closes: https://github.com/searxng/searxng/issues/5456
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-25 06:25:45 +01:00
Hermógenes Oliveira
5fcee9bc30 [fix] recoll engine: remove HTML markup from result snippets (#5472)
Recoll inserts markup tags in snippets to indicate matching terms in a
search query.  We remove them so that they don't show to users.
2025-11-24 06:54:45 +01:00
Ivan Gabaldon
2f0e52d6eb [upd] ci: docker secret maintenance
I've narrowed the permissions and rotated the token for the deploy account on
DockerHub registry. I replaced the secret ref in GitHub so that it's available
organization wide. No further actions are necessary.
2025-11-23 12:26:40 +00:00
Grant
c0d69cec4e [fix] drop mullvad-leta engine (#5428)
On 2025 November 27th, Mullvad will be shutting down the Leta servers.
For this reason, we also need to remove this engine from SearXNG.

[1] https://mullvad.net/en/blog/shutting-down-our-search-proxy-leta
2025-11-22 10:02:51 +01:00
Austin-Olacsi
c852b9a90a [feat] engine: add grokipedia (#5396) 2025-11-22 09:59:38 +01:00
Ivan Gabaldon
b876d0bed0 [upd] theme/simple: bump rolldown
(no static changes...)
2025-11-21 11:03:04 +00:00
Léon Tiekötter
e245cade25 [fix] engines: typo (#5466)
Fix typo in engine timeout definition: 'timout' -> 'timeout'
2025-11-21 11:20:10 +01:00
dependabot[bot]
7c223b32a7 [upd] web-client (simple): Bump @biomejs/biome
Bumps the minor group in /client/simple with 1 update: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome).

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-21 10:15:49 +00:00
dependabot[bot]
33a176813d [upd] github-actions: Bump actions/checkout from 5.0.0 to 6.0.0
Bumps [actions/checkout](https://github.com/actions/checkout) from 5.0.0 to 6.0.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](08c6903cd8...1af3b93b68)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-21 09:38:50 +00:00
dependabot[bot]
20ec01c5f7 [upd] github-actions: Bump github/codeql-action from 4.31.3 to 4.31.4
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.3 to 4.31.4.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](014f16e7ab...e12f017898)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-21 09:21:20 +00:00
dependabot[bot]
6376601ba1 [upd] pypi: Bump the minor group with 4 updates (#5462)
Bumps the minor group with 4 updates: [granian](https://github.com/emmett-framework/granian), [granian[pname]](https://github.com/emmett-framework/granian), [granian[reload]](https://github.com/emmett-framework/granian) and [basedpyright](https://github.com/detachhead/basedpyright).


Updates `granian` from 2.5.7 to 2.6.0
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.7...v2.6.0)

Updates `granian[pname]` from 2.5.7 to 2.6.0
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.7...v2.6.0)

Updates `granian[reload]` from 2.5.7 to 2.6.0
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.7...v2.6.0)

Updates `basedpyright` from 1.33.0 to 1.34.0
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.33.0...v1.34.0)
2025-11-21 08:31:16 +01:00
Markus Heiser
ca441f419c [fix] engines - set hard timouts in *sub-request* (#5460)
The requests changed here all run outside of the network context timeout,
thereby preventing the engine's timeout from being applied (the engine's timeout
can become longer than it was configured).

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-21 08:16:24 +01:00
searxng-bot
04e66a2bb4 [l10n] update translations from Weblate 2025-11-20 21:22:43 +00:00
Markus Heiser
b299386d3e [fix] minor type hint issues (#5459)
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-20 18:35:43 +01:00
Markus Heiser
21a4622f23 [fix] utils.js_variable_to_python - partial revert of 156d1eb8c (#5458)
The JS string, whose encoding will be corrupted if all single quotes (followed
by a comma) are replaced with double quotes. Bug was introduced in PR #4573.

Here is a simple example in which the list get corrupted::

    >>> s = r"""[ 'foo\'', 'bar']"""
    >>> print(s)
    [ 'foo\'', 'bar']
    >>> print(s.replace("',", "\","))
    [ 'foo\'", 'bar']

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-20 18:32:27 +01:00
Bnyro
041f457dfa [fix] presearch engine: blocked by captcha on every request
Presearch responds with a Cloudflare captcha on each request when using HTTP2.
Using HTTP1.1, everything seems to work fine.

- other engines with the same issue: pixabay, uxwing
- closes https://github.com/searxng/searxng/issues/5438
2025-11-20 13:48:13 +01:00
Hermógenes Oliveira
af111e413c [fix] recoll engine: fix media preview
The results from the recoll engine were not displaying the usual
toggle for showing media previews. After the changes described bellow,
the toggle is displayed and works as expected.

In the JSON returned by recoll-webui, the field containing the
mimetype is actually `mtype`, not `mime`.

Furthermore, according to the documentation for the `File` class in
`searx/result_types/file.py`, `embedded` should contain the URL to the
media itself. The embedding of the media into the page for preview is
done in `searx/templates/simple/result_templates/file.html`.
2025-11-20 13:24:17 +01:00
Ivan Gabaldon
431bf5d235 [mod] docs: add acknowledgements section (#5449)
* [mod] docs: add acknowledgements section

Moves all images into a `assets/` folder.

* [fix] docs: normalize brands svg
2025-11-20 10:31:53 +00:00
Edge-Seven
576c8ca99c [fix] client/simple: docs typo in plg.ts (#5450) 2025-11-18 09:44:41 +00:00
dependabot[bot]
45a4b8ad1c [upd] pypi: Bump the minor group with 3 updates (#5443)
Bumps the minor group with 3 updates: [certifi](https://github.com/certifi/python-certifi), [pylint](https://github.com/pylint-dev/pylint) and [basedpyright](https://github.com/detachhead/basedpyright).


Updates `certifi` from 2025.10.5 to 2025.11.12
- [Commits](https://github.com/certifi/python-certifi/compare/2025.10.05...2025.11.12)

Updates `pylint` from 4.0.2 to 4.0.3
- [Release notes](https://github.com/pylint-dev/pylint/releases)
- [Commits](https://github.com/pylint-dev/pylint/compare/v4.0.2...v4.0.3)

Updates `basedpyright` from 1.32.1 to 1.33.0
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.32.1...v1.33.0)
2025-11-15 09:04:50 +01:00
Austin-Olacsi
d14d695966 [fix] drop alexandria.org (#5446) 2025-11-15 07:38:17 +01:00
dependabot[bot]
a2a47337cb [upd] web-client (simple): Bump the minor group (#5444)
Bumps the minor group in /client/simple with 3 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [browserslist](https://github.com/browserslist/browserslist).

Updates `@biomejs/biome` from 2.3.4 to 2.3.5
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.3.5/packages/@biomejs/biome)

Updates `@types/node` from 24.10.0 to 24.10.1
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `browserslist` from 4.27.0 to 4.28.0
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.27.0...4.28.0)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.3.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 24.10.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: browserslist
  dependency-version: 4.28.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-14 21:50:02 +00:00
Bnyro
ba98030438 [feat] engines: add devicons engine
- official website: https://devicon.dev/
- the engine contains a lot of icons of popular software frameworks (e.g. pytest),
so they could for example be useful for visualizing a diagram of the tech stack used in an app
2025-11-14 20:26:43 +01:00
dependabot[bot]
1e200a1107 [upd] github-actions: Bump github/codeql-action from 4.31.2 to 4.31.3 (#5445)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.2 to 4.31.3.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](0499de31b9...014f16e7ab)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-14 08:33:14 +00:00
Austin-Olacsi
7a1b959646 [fix] hackernews contains HTML escape codes 2025-11-10 20:37:01 +01:00
dependabot[bot]
b9b46431be [upd] web-client (simple): Bump the minor group in /client/simple with 4 updates (#5423)
* [upd] web-client (simple): Bump the minor group

Bumps the minor group in /client/simple with 4 updates: [ol](https://github.com/openlayers/openlayers), [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [sharp](https://github.com/lovell/sharp).

Updates `ol` from 10.6.1 to 10.7.0
- [Release notes](https://github.com/openlayers/openlayers/releases)
- [Commits](https://github.com/openlayers/openlayers/compare/v10.6.1...v10.7.0)

Updates `@biomejs/biome` from 2.3.2 to 2.3.4
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.3.4/packages/@biomejs/biome)

Updates `@types/node` from 24.9.2 to 24.10.0
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `sharp` from 0.34.4 to 0.34.5
- [Release notes](https://github.com/lovell/sharp/releases)
- [Commits](https://github.com/lovell/sharp/compare/v0.34.4...v0.34.5)

---
updated-dependencies:
- dependency-name: ol
  dependency-version: 10.7.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: "@biomejs/biome"
  dependency-version: 2.3.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 24.10.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: sharp
  dependency-version: 0.34.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* [upd] web-client (simple): rebuild static

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-11-07 10:48:05 +01:00
dependabot[bot]
3f18c0f40f [upd] pypi: Bump the minor group with 3 updates (#5422)
Bumps the minor group with 3 updates: [granian](https://github.com/emmett-framework/granian), [granian[pname]](https://github.com/emmett-framework/granian) and [granian[reload]](https://github.com/emmett-framework/granian).


Updates `granian` from 2.5.6 to 2.5.7
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.6...v2.5.7)

Updates `granian[pname]` from 2.5.6 to 2.5.7
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.6...v2.5.7)

Updates `granian[reload]` from 2.5.6 to 2.5.7
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.6...v2.5.7)

---
updated-dependencies:
- dependency-name: granian
  dependency-version: 2.5.7
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: granian[pname]
  dependency-version: 2.5.7
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: granian[reload]
  dependency-version: 2.5.7
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-07 10:46:18 +01:00
dependabot[bot]
1cfbd32a1d [upd] github-actions: Bump JamesIves/github-pages-deploy-action (#5425)
Bumps [JamesIves/github-pages-deploy-action](https://github.com/jamesives/github-pages-deploy-action) from 4.7.3 to 4.7.4.
- [Release notes](https://github.com/jamesives/github-pages-deploy-action/releases)
- [Commits](6c2d9db40f...4a3abc783e)

---
updated-dependencies:
- dependency-name: JamesIves/github-pages-deploy-action
  dependency-version: 4.7.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-07 10:01:43 +01:00
dependabot[bot]
a15b594003 [upd] github-actions: Bump docker/setup-qemu-action from 3.6.0 to 3.7.0 (#5424)
Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action) from 3.6.0 to 3.7.0.
- [Release notes](https://github.com/docker/setup-qemu-action/releases)
- [Commits](29109295f8...c7c5346462)

---
updated-dependencies:
- dependency-name: docker/setup-qemu-action
  dependency-version: 3.7.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-07 09:56:18 +01:00
Aadniz
24d27a7a21 [fix] drop goo engine 2025-11-07 08:34:05 +01:00
Ivan Gabaldon
7af922c9df [enh] py: drop deps (#5407)
The difference between decompression with brotli or gzip in HTML files is
negligible for 3 MB of compiled binary package.

Introduced in eaa694fb7d

Closes https://github.com/searxng/searxng/security/code-scanning/276
Closes https://github.com/searxng/searxng/security/dependabot/37
2025-11-06 10:09:10 +01:00
Aadniz
b1918dd121 [fix] yandex engine: capture captcha from header instead of url path (#5417)
Yandex engine will return parsing error instead of informing that a CAPTCHA was found. It is confusing for the admin and the users (#5415).


This patch fixes an issue where the CAPTCHA response from Yandex wouldn't be detected, resulting in `ParserError` when trying to parse the response to DOM.

In this fix, I replaced the url condition and instead is checking if the `x-yandex-captcha` header is set, and is equal to `captcha`.

Alternatively, maybe something like `resp.headers.get('Location', '').startswith("https://yandex.com/showcaptcha")` could be done instead. Lastly, setting `params['allow_redirects'] = True` can also work, but this will waste an extra request. Just let me know.

Closes: https://github.com/searxng/searxng/issues/5415
2025-11-06 07:00:48 +01:00
Bnyro
1be19f8b58 [feat] sourcehut engine: implement as custom module, fix user agent
SourceHut uses a foss bot protection tool called `go-away` (which I can
recommend BTW).  It blocks common crawler user agents, such as the standard
Firefox user agent.  Hence, we're now using our custom SearXNG user agent to
clarify we're not a crawler.

Closes: https://github.com/searxng/searxng/issues/5270
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-05 17:56:13 +01:00
Bnyro
3763b4bff4 [fix] engine ahmia blacklist, arch linux: use proper searxng user agent including version (#5414) 2025-11-05 09:19:42 +01:00
Aadniz
52ffc4c7f4 [fix] qwant engine: order query parameters to prevent 403 forbidden (#5410) 2025-11-03 22:53:50 +01:00
Markus Heiser
0245327fc5 Revert "[fix] !weather crashes - cls.TURN .. (#5309)"
This reverts HOTFIX from commit fc7d8b8b [1]

[1] https://github.com/searxng/searxng/pull/5309

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-01 09:46:47 +01:00
Markus Heiser
b155e66fe5 [fix] msgspec.Struct: alias name t.ClassVar not properly detected
Reported in [1], HOTFIX in [2], this patch here is now the final solution.

Note that if using PEP 563 postponed evaluation of annotations" (e.g. ``from
__future__ import annotations``) only the following spellings will work:

    ClassVar or ClassVar[<type>]
    typing.ClassVar or typing.ClassVar[<type>]

Importing ClassVar or typing under an aliased name (e.g. ``import typing as t``)
will not be properly detected. [3]

[1] https://github.com/searxng/searxng/issues/5304#issuecomment-3394140820
[2] https://github.com/searxng/searxng/pull/5309
[3] https://jcristharif.com/msgspec/structs.html#class-variables

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-11-01 09:46:47 +01:00
dependabot[bot]
5712827703 [upd] web-client (simple): Bump the minor group (#5402)
Bumps the minor group in /client/simple with 2 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) and [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node).

Updates `@biomejs/biome` from 2.2.7 to 2.3.2
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.3.2/packages/@biomejs/biome)

Updates `@types/node` from 24.9.1 to 24.9.2
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 24.9.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
2025-11-01 09:45:54 +01:00
dependabot[bot]
7ba53d302d [upd] pypi: Bump the minor group with 3 updates (#5401)
Bumps the minor group with 3 updates: [granian](https://github.com/emmett-framework/granian), [selenium](https://github.com/SeleniumHQ/Selenium) and [granian[reload]](https://github.com/emmett-framework/granian).


Updates `granian` from 2.5.5 to 2.5.6
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.5...v2.5.6)

Updates `selenium` from 4.37.0 to 4.38.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.37.0...selenium-4.38.0)

Updates `granian[reload]` from 2.5.5 to 2.5.6
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.5...v2.5.6)

---
updated-dependencies:
- dependency-name: granian
  dependency-version: 2.5.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: selenium
  dependency-version: 4.38.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: granian[reload]
  dependency-version: 2.5.6
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
2025-11-01 09:44:12 +01:00
dependabot[bot]
b8e4ebdc0c [upd] github-actions: Bump github/codeql-action from 4.30.9 to 4.31.2 (#5403)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.30.9 to 4.31.2.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](16140ae1a1...0499de31b9)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-31 11:31:10 +01:00
github-actions[bot]
b37d09557a [l10n] update translations from Weblate (#5404)
0bdbdde2e - 2025-10-26 - 0ko <0ko@noreply.codeberg.org>
7b0abb9aa - 2025-10-27 - artens <artens@noreply.codeberg.org>
882a28944 - 2025-10-27 - langckx <langckx@noreply.codeberg.org>
c2d025563 - 2025-10-25 - Flyingfufu <flyingfufu@noreply.codeberg.org>
2025-10-31 08:27:05 +01:00
Markus Heiser
aa28af772c [fix] ./manage dev.env - nvm is not installed by nvm.env (#5399)
To complete a SearXNG developer environment, nvm needs to be
installed (ensured).  Without this patch::

    $ LANG=C ./manage dev.env
    ...
    ./utils/lib_nvm.sh: line 27: .nvm/nvm.sh: No such file or directory
    ./utils/lib_nvm.sh: line 28: .nvm/bash_completion: No such file or directory
    ...
    (dev.env)$

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-30 17:46:05 +01:00
Markus Heiser
9c2b8f2f93 [data] update searx.data - update_ahmia_blacklist.py
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-30 07:40:20 +01:00
Markus Heiser
c48993452f [fix] update_ahmia_blacklist.py - User-Agent become required
The User-Agent header recently become required to fetch blacklist from URL

  https://ahmia.fi/blacklist/

[1] https://github.com/searxng/searxng/actions/runs/18892940199/job/53924400294

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-30 07:40:20 +01:00
Markus Heiser
6a2196c03d [fix] simple theme: fix *play* icon in the "show media" button (#5395)
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-30 07:39:48 +01:00
github-actions[bot]
dce383881d [data] update searx.data - update_firefox_version.py (#5388) 2025-10-29 07:15:11 +01:00
github-actions[bot]
1ebedcbc17 [data] update searx.data - update_wikidata_units.py (#5389) 2025-10-29 07:14:31 +01:00
github-actions[bot]
5d99877d8d [data] update searx.data - update_currencies.py (#5390)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-10-29 07:13:53 +01:00
github-actions[bot]
adc1a2a1ea [data] update searx.data - update_engine_descriptions.py (#5391)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-10-29 07:13:19 +01:00
Aadniz
43065c5026 [fix] deviantart engine: pagination match change (#5384)
Pagination currently does not work for deviantart, resulting in the same page
being shown when going to the next page in SearXNG.
2025-10-28 06:21:40 +01:00
Aadniz
ea4a55fa57 [fix] qwant engine: set header Accept-Language to bypass bot detection (#5382)
Set HTTP header Accept-Language [1] for the Qwant engine.

Qwant does not seem to work on any SearXNG instance right now, and this is a fix
for this issue.

During testing, it seems like setting the Accept-Language gives more success for
bypassing bot detection (tested with a few ~20 searches).

[1] https://docs.searxng.org/dev/engines/enginelib.html#searx.enginelib.Engine.send_accept_language_header
2025-10-27 08:33:07 +01:00
Aadniz
d514dea5cc [fix] deviantart engine: does not return any results (#5383) 2025-10-27 08:02:01 +01:00
Aadniz
22e1d30017 [fix] startpage engine: properly display CAPTCHA if redirect page is seen (#5380)
Fixes an issue where startpage engine would display parsing error
(`json.decoder.JSONDecodeError`) when returning CAPTCHA redirect page.

The fix simply checks if response header has `Location` set, and if it starts
with `https://www.startpage.com/sp/captcha`, it will raise a CAPTCHA exception
before trying to parse the data.
2025-10-26 11:32:45 +01:00
Aadniz
4ca75a0450 [fix] engine qwant - return forbidden instead of showing parse error (#5377) 2025-10-25 13:43:37 +02:00
Bnyro
50a4c653dc [build] /static 2025-10-25 10:00:28 +02:00
Bnyro
b7f9b489c9 [fix] search bar: cursor jumps to beginning when clicking text field
Apparently, setting padding on an input field and then clicking that
space created by the padding forces the seekbar cursor to jump to the
beginning of the input field instead of the actual text position.

By removing that padding, the search bar input automatically claims that
height for itself and thus clicking on the blank space moves the cursor to
the correct position.

closes https://github.com/searxng/searxng/issues/5371
2025-10-25 10:00:28 +02:00
dependabot[bot]
2cdbbb249a [upd] web-client (simple): Bump the minor group (#5368)
Bumps the minor group in /client/simple with 3 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [browserslist](https://github.com/browserslist/browserslist).

Updates `@biomejs/biome` from 2.2.6 to 2.2.7
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.2.7/packages/@biomejs/biome)

Updates `@types/node` from 24.8.1 to 24.9.1
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `browserslist` from 4.26.3 to 4.27.0
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.26.3...4.27.0)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.2.7
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 24.9.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: browserslist
  dependency-version: 4.27.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-24 16:34:09 +02:00
Ivan Gabaldon
edfa71cdea [mod] rebuild static 2025-10-24 12:32:43 +02:00
Ivan Gabaldon
8dacbbbb15 [fix] client/simple: insecure ctx clipboard copy
Uses the deprecated [`execCommand()`](https://developer.mozilla.org/en-US/docs/Web/API/Document/execCommand)
to copy content to clipboard if accessing the instance through HTTP, this method
isn't going away soon.

Closes https://github.com/searxng/searxng/issues/5359
2025-10-24 12:32:43 +02:00
dependabot[bot]
b770a46e1f [upd] pypi: Bump the minor group across 1 directory with 5 updates (#5372)
Bumps the minor group with 5 updates in the / directory:

| Package | From | To |
| --- | --- | --- |
| [typer-slim](https://github.com/fastapi/typer) | `0.19.2` | `0.20.0` |
| [typing-extensions](https://github.com/python/typing_extensions) | `4.14.1` | `4.15.0` |
| [pylint](https://github.com/pylint-dev/pylint) | `4.0.1` | `4.0.2` |
| [selenium](https://github.com/SeleniumHQ/Selenium) | `4.36.0` | `4.37.0` |
| [basedpyright](https://github.com/detachhead/basedpyright) | `1.31.7` | `1.32.1` |



Updates `typer-slim` from 0.19.2 to 0.20.0
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.19.2...0.20.0)

Updates `typing-extensions` from 4.14.1 to 4.15.0
- [Release notes](https://github.com/python/typing_extensions/releases)
- [Changelog](https://github.com/python/typing_extensions/blob/main/CHANGELOG.md)
- [Commits](https://github.com/python/typing_extensions/compare/4.14.1...4.15.0)

Updates `pylint` from 4.0.1 to 4.0.2
- [Release notes](https://github.com/pylint-dev/pylint/releases)
- [Commits](https://github.com/pylint-dev/pylint/compare/v4.0.1...v4.0.2)

Updates `selenium` from 4.36.0 to 4.37.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.36.0...selenium-4.37.0)

Updates `basedpyright` from 1.31.7 to 1.32.1
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.31.7...v1.32.1)
2025-10-24 11:11:34 +02:00
github-actions[bot]
2c880f6084 [l10n] update translations from Weblate (#5370)
55c0cab85 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
7705bba80 - 2025-10-21 - Outbreak2096 <outbreak2096@noreply.codeberg.org>
d2ee86058 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
8c4478ca3 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
147ba039a - 2025-10-21 - return42 <return42@noreply.codeberg.org>
2d9a206e8 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
024e2f1c7 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
8059378af - 2025-10-21 - return42 <return42@noreply.codeberg.org>
4b4359eea - 2025-10-21 - return42 <return42@noreply.codeberg.org>
05af879c9 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
0ea9d6393 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
e2e0907ff - 2025-10-21 - return42 <return42@noreply.codeberg.org>
9a7cfc1c1 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
06b7d62f0 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
a3bc054a5 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
34e56b171 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
8cc444358 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
55afa16d1 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
a336dd1ae - 2025-10-21 - return42 <return42@noreply.codeberg.org>
ec68a405a - 2025-10-21 - return42 <return42@noreply.codeberg.org>
beeab8c25 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
44a5c9e04 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
aef218710 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
42923cf46 - 2025-10-21 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
3cab50a73 - 2025-10-22 - jperegrinm <jperegrinm@noreply.codeberg.org>
410e760d5 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
bb5e921c3 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
eece61f04 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
1f18156d5 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
20026535d - 2025-10-21 - return42 <return42@noreply.codeberg.org>
fcc563bf8 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
ec02a81da - 2025-10-21 - return42 <return42@noreply.codeberg.org>
78125c9e6 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
7a4b89369 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
d02406831 - 2025-10-21 - return42 <return42@noreply.codeberg.org>
8fe4022cb - 2025-10-21 - return42 <return42@noreply.codeberg.org>
0e8cdcaa8 - 2025-10-20 - SomeTr <sometr@noreply.codeberg.org>
4b138b0dc - 2025-10-20 - Juno Takano <jutty@noreply.codeberg.org>
d20e2c9c1 - 2025-10-20 - ghose <ghose@noreply.codeberg.org>
2025-10-24 10:34:09 +02:00
dependabot[bot]
c41b769f97 [upd] github-actions: Bump github/codeql-action from 4.30.8 to 4.30.9 (#5369)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.30.8 to 4.30.9.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](f443b600d9...16140ae1a1)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.30.9
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-24 10:04:49 +02:00
Markus Heiser
e363db970c [fix] Installation Script install fails (msgspec) (#5358)
Since #5280 has been merged, msgspec, like yaml, is a fixed part of the SearXNG
*settings framework* and therefore, like yaml, must be installed in the virtual
environment before installing SearXNG (``searx``).

The actual reason is that in SearXNG we store settings in the configuration that
are required for the installation of the ``searx`` package.  This means that
these settings (from settings.yml) are read in during the installation, and all the
necessary tools for this (pyyaml, msgspec, setuptools, etc.) must be installed
beforehand (chicken or the egg dilemma).

Related:

- https://github.com/searxng/searxng/pull/5353
- https://github.com/searxng/searxng/pull/5346
- https://github.com/searxng/searxng/pull/5280
- https://github.com/searxng/searxng/pull/5254

Closes: https://github.com/searxng/searxng/issues/5357

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-23 09:27:14 +02:00
Ivan Gabaldon
16293132e3 [mod] ci: use custom static podman (#5354)
We only need updated podman on `build`. `test` and `release` can use image
provided container engine binaries.
2025-10-22 14:38:59 +02:00
Markus Heiser
f70120b0b9 [fix] Installation Script install fails (msgspec) (#5353)
Since #5280 has been merged, msgspec, like yaml, is a fixed part of the SearXNG
*settings framework* and therefore, like yaml, must be installed in the virtual
environment before installing SearXNG (``searx``).

The actual reason is that in SearXNG we store settings in the configuration that
are required for the installation of the ``searx`` package.  This means that
these settings (from settings.yml) are read in during the installation, and all the
necessary tools for this (pyyaml, msgspec, setuptools, etc.) must be installed
beforehand (chicken or the egg dilemma).

Related:

- https://github.com/searxng/searxng/pull/5346
- https://github.com/searxng/searxng/pull/5280
- https://github.com/searxng/searxng/pull/5254

Closes: https://github.com/searxng/searxng/issues/5352
2025-10-22 09:34:09 +02:00
Ivan Gabaldon
a8f3644cdc [upd] themes/simple: Bump rolldown-vite from 7.1.17 to 7.1.19 (#5351)
This security update does nothing but creating a new commit to build a container
with the new `base` image.
2025-10-21 20:16:19 +02:00
Markus Heiser
4295e758c0 [fix] Installation Script install fails (msgspec) (#5346)
Since #5280 has been merged, msgspec, like yaml, is a fixed part of the SearXNG
*settings framework* and therefore, like yaml, must be installed in the virtual
environment before installing SearXNG (``searx``).

The actual reason is that in SearXNG we store settings in the configuration that
are required for the installation of the ``searx`` package.  This means that
these settings (from settings.yml) are read in during the installation, and all the
necessary tools for this (pyyaml, msgspec, setuptools, etc.) must be installed
beforehand (chicken or the egg dilemma).

Related:

- https://github.com/searxng/searxng/pull/5280
- https://github.com/searxng/searxng/pull/5254

Closes: https://github.com/searxng/searxng/issues/5343

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-20 11:21:48 +02:00
Markus Heiser
33e798b01b [fix] TrackerPatternsDB.clean_url: don't delete query argument from new_url (#5339)
The query argument for URLs like:

- 'http://example.org?q='       --> query_str is 'q='
- 'http://example.org?/foo/bar' --> query_str is 'foo/bar'

is a *simple string* and not a key/value dict.  This string may only be removed
from the URL if one of the patterns matches.

BTW get_pretty_url(): keep such a *simple string* in the path element.

Closes: https://github.com/searxng/searxng/issues/5299

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-20 11:20:33 +02:00
Markus Heiser
d84ae96cf9 [build] /static 2025-10-20 10:18:33 +02:00
Markus Heiser
9371658531 [mod] typification of SearXNG: add new result type File
This PR adds a new result type: File

    Python class: searx/result_types/file.py
    Jinja template: searx/templates/simple/result_templates/file.html
    CSS (less) client/simple/src/less/result_types/file.less

Class 'File' (singular) replaces template 'files.html' (plural).  The renaming
was carried out because there is only one file (singular) in a result. Not to be
confused with the category 'files' where in multiple results can exist.

As mentioned in issue [1], the class '.category-files' was removed from the CSS
and the stylesheet was adopted in result_types/file.less (there based on the
templates and no longer based on the category).

[1] https://github.com/searxng/searxng/issues/5198

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-20 10:18:33 +02:00
Markus Heiser
ee6d4f322f [mod] engine: reuters - REST-API for Reuter's thumbnail, height:80
The size of the full-size images from ``thumbnail.url`` is usually several
MB. By reducing the full-size image to 80 pixels, the data size for a thumb is
reduced from MB to a few KB.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-18 14:43:35 +02:00
Bnyro
3725aef6f3 [fix] reuters: crash on empty results pages & date parsing
1. On empty result list, return empty EngineResults (#5330)

2. Use ``dateutil.parser`` to avoid ``ValueError``:

    ERROR   searx.engines.reuters : exception : Invalid isoformat string: '2022-06-08T16:07:54Z'
      File "searx/engines/reuters.py", line 91, in response
        publishedDate=datetime.fromisoformat(result["display_time"]),
    ValueError: Invalid isoformat string: '2022-06-08T16:07:54Z'

Closes: https://github.com/searxng/searxng/issues/5330
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-18 14:43:35 +02:00
Markus Heiser
e840e3f960 [fix] engine mullvadleta - ignore HTTP 403 & 429 response
It doesn't matter if you're using Mullvad's VPN and a proper browser, you'll
still get blocked for specific searches [1] with a 403 or 429 HTTP status code.
Mullvad only blocks the search request and doesn't prevent you from doing more
searches.

The logic should handle the blocked requests (403, 429), but not put the engine
on a cooldown.

[1] https://leta.mullvad.net/search?q=site%3Afoo+bar&engine=brave

Closes: https://github.com/searxng/searxng/issues/5328
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-18 09:05:54 +02:00
Bnyro
a6bb1ecf87 [build] /static 2025-10-17 15:59:53 +02:00
Bnyro
636738779e [feat] video results: display video length on video thumbnail 2025-10-17 15:59:53 +02:00
Bnyro
1d138c5968 [mod] bing engine: follow redirects (#5324)
Apparently, in China, Bing redirects from `www.bing.com` to `cn.bing.com`.
So in order to make Bing work for chinese users by default, we have to follow that redirect.

related: https://github.com/searxng/searxng/issues/5243
2025-10-17 15:43:49 +02:00
Markus Heiser
3e7e404fda [fix] issues reported by Pylint 4.0
Last major update of Pylint brings some breaking changes [1], fixed in this
patch.

[1] https://pylint.readthedocs.io/en/latest/whatsnew/4/4.0/index.html#breaking-changes
2025-10-17 15:42:22 +02:00
dependabot[bot]
602a73df9a [upd] pypi: Bump pylint from 3.3.9 to 4.0.1
Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.3.9 to 4.0.1.
- [Release notes](https://github.com/pylint-dev/pylint/releases)
- [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.9...v4.0.1)

---
updated-dependencies:
- dependency-name: pylint
  dependency-version: 4.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-17 15:42:22 +02:00
dependabot[bot]
57622793bf [upd] web-client (simple): Bump the minor group in /client/simple (#5333)
* [upd] web-client (simple): Bump the minor group

Bumps the minor group in /client/simple with 2 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) and [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node).

Updates `@biomejs/biome` from 2.2.5 to 2.2.6
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.2.6/packages/@biomejs/biome)

Updates `@types/node` from 24.7.1 to 24.8.1
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.2.6
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 24.8.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* [build] /static

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-10-17 10:29:16 +02:00
dependabot[bot]
080f3a5f87 [upd] github-actions: Bump actions/setup-node from 5.0.0 to 6.0.0 (#5334)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 5.0.0 to 6.0.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](a0853c2454...2028fbc5c2)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-17 10:03:07 +02:00
dependabot[bot]
f54cf643b2 [upd] github-actions: Bump github/codeql-action from 4.30.7 to 4.30.8 (#5335)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.30.7 to 4.30.8.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](e296a93559...f443b600d9)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.30.8
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-17 10:02:59 +02:00
dependabot[bot]
dd82d785ce [upd] pypi: Bump basedpyright from 1.31.6 to 1.31.7 in the minor group (#5331)
Bumps the minor group with 1 update: [basedpyright](https://github.com/detachhead/basedpyright).

Updates `basedpyright` from 1.31.6 to 1.31.7
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.31.6...v1.31.7)
2025-10-17 09:43:36 +02:00
github-actions[bot]
f6cdd16449 [l10n] update translations from Weblate (#5336)
e23460caa - 2025-10-13 - aindriu80 <aindriu80@noreply.codeberg.org>
bb7d1cc0e - 2025-10-13 - Juno Takano <jutty@noreply.codeberg.org>
8b8bc1461 - 2025-10-13 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
f4bec8c6a - 2025-10-13 - Raithlin <raithlin@noreply.codeberg.org>
609efd4e6 - 2025-10-13 - AndersNordh <andersnordh@noreply.codeberg.org>
6c709f898 - 2025-10-13 - return42 <return42@noreply.codeberg.org>
a2b608da4 - 2025-10-13 - AndersNordh <andersnordh@noreply.codeberg.org>
4f0cd2119 - 2025-10-12 - kratos <makesocialfoss32@keemail.me>
8d049e1cb - 2025-10-11 - Outbreak2096 <outbreak2096@noreply.codeberg.org>
4bf5fc5fe - 2025-10-11 - Linerly <linerly@noreply.codeberg.org>
c80cf6e92 - 2025-10-11 - ghose <ghose@noreply.codeberg.org>
92427655d - 2025-10-11 - Fjuro <fjuro@alius.cz>
8efe1bb12 - 2025-10-10 - SomeTr <sometr@noreply.codeberg.org>
2025-10-17 09:41:21 +02:00
benpiano800
576d30ffcd [chore] theme_args.simple_style - mention the black theme style in settings.yml (#5325) 2025-10-15 09:16:19 +02:00
Tommaso Colella
c34bb61284 [feat] engines: add Azure resources engine (#5235)
Adds a new engine `searx/engines/azure.py` to search cloud resources on Azure.

A lot of enterprise users have to deal with Azure Public Cloud.  This helps them
easily search for cloud resources without logging in to the Portal first

How to test this PR locally?

You should create an App Registration on Azure Entra Id with Reader access on
the resources you want to search for.  You should create a Secret for the App
Registration.  After that, you should set up appropriate values in the
`settings.yml` file [1]::

   - name: azure
     engine: azure
     ...
     azure_tenant_id: "your_tenant_id"
     azure_client_id: "your_client_id"
     azure_client_secret: "your_client_secret"
     azure_token_expiration_seconds: 5000

[1] https://github.com/searxng/searxng/pull/5235#issuecomment-3397664928

Co-authored-by: Bnyro <bnyro@tutanota.com>
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-13 16:33:08 +02:00
Bnyro
8baefcc21e [fix] pinterest: crash when there's no link & show image resolution + uploader name (#5314)
closes #5231
2025-10-13 07:43:36 +02:00
Markus Heiser
fc7d8b8be2 [fix] !weather crashes - cls.TURN 'member_descriptor' isn't a float (#5309)
The class method ``Compass.point`` is converted into an instance method to
circumvent the problem described in [1] (without understanding the cause).

[1] https://github.com/searxng/searxng/issues/5304#issuecomment-3394140820

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-13 07:37:42 +02:00
Ivan Gabaldon
5492de15bb [mod] container: move base to own repository (#5310)
The base images will be now built in
[another repository](https://github.com/searxng/base).
2025-10-12 16:30:57 +02:00
Ivan Gabaldon
ced08e12aa [enh] ci: bump to cp3.14 (#5302) 2025-10-11 16:59:40 +02:00
Mehmet Sait Cubukcu
613c1aa8eb docs: remove unsupported --replace flag from Docker command (#5288) 2025-10-10 20:31:48 +02:00
Bnyro
899cf7e08a [build] /static 2025-10-10 18:08:33 +02:00
Bnyro
362cc13aeb [feat] preferences hash: show applied settings in pref page when searching with 'search url of the currently saved preferences'
Previously, when using a search url copied from the cookies tab, clicking
at the settings icon at the top right would show the browser preferences
and not the preferences that were set and used with the search url.
Please see https://github.com/searxng/searxng/issues/5227 for more information.

To test:
- change some preferences
- copy the preferences search url in the settings' cookies tab
- reset the preferences or clear cookies
- paste the copied search url into the search bar to search for something
- press the settings icon
- you can now see/preview the actual settings that were used for the search
- by pressing 'save', you can keep these preferences

closes #5227
2025-10-10 18:08:33 +02:00
Bnyro
d28a1c434f [fix] no results error dialog: link to preferences doesn't work if searxng is hosted as subdirectory 2025-10-10 18:05:54 +02:00
Markus Heiser
21d0428cf2 [mod] brand - partial migration of settings to msgspec.Struct (#5280)
The settings are currently an untyped key/value structure, whose types are
dynamically built at runtime.  The construction process of this structure
is *hand-crafted*.

In the long term, we want a static typing of this structure, based on a standard
tool.  The ``msgspec.Struct`` structures are suitable as a standard tool.

This patch makes a first step towards static typing and implements the "brand"
section using ``msgspec.Struct`` structures.

BTW: searx/settings_defaults.py - ``git_url`` and ``git_branch`` had been
removed in aee613d256, this is a leftover.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-10 16:14:29 +02:00
github-actions[bot]
f0dfe3cc0e [l10n] update translations from Weblate (#5296)
bb1f7a851 - 2025-10-04 - 0ko <0ko@noreply.codeberg.org>
2025-10-10 11:27:35 +02:00
dependabot[bot]
0559b9bfcf [upd] web-client (simple): bump dependencies (#5294)
* [upd] web-client (simple): bump dependencies

* [build] /static

---------

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-10-10 11:14:54 +02:00
dependabot[bot]
37f7960266 [upd] github-actions: Bump github/codeql-action from 3.30.6 to 4.30.7 (#5295)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.30.6 to 4.30.7.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](64d10c1313...e296a93559)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.30.7
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-10 10:55:50 +02:00
dependabot[bot]
02d5166a3b [upd] pypi: Bump the minor group with 6 updates (#5293)
Bumps the minor group with 6 updates:

| Package | From | To |
| --- | --- | --- |
| [granian](https://github.com/emmett-framework/granian) | `2.5.4` | `2.5.5` |
| [certifi](https://github.com/certifi/python-certifi) | `2025.8.3` | `2025.10.5` |
| [tomli](https://github.com/hukkin/tomli) | `2.2.1` | `2.3.0` |
| [pylint](https://github.com/pylint-dev/pylint) | `3.3.8` | `3.3.9` |
| [wlc](https://github.com/WeblateOrg/wlc) | `1.15` | `1.16.1` |
| [granian[reload]](https://github.com/emmett-framework/granian) | `2.5.4` | `2.5.5` |


Updates `granian` from 2.5.4 to 2.5.5
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.4...v2.5.5)

Updates `certifi` from 2025.8.3 to 2025.10.5
- [Commits](https://github.com/certifi/python-certifi/compare/2025.08.03...2025.10.05)

Updates `tomli` from 2.2.1 to 2.3.0
- [Changelog](https://github.com/hukkin/tomli/blob/master/CHANGELOG.md)
- [Commits](https://github.com/hukkin/tomli/compare/2.2.1...2.3.0)

Updates `pylint` from 3.3.8 to 3.3.9
- [Release notes](https://github.com/pylint-dev/pylint/releases)
- [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.8...v3.3.9)

Updates `wlc` from 1.15 to 1.16.1
- [Release notes](https://github.com/WeblateOrg/wlc/releases)
- [Changelog](https://github.com/WeblateOrg/wlc/blob/main/CHANGES.rst)
- [Commits](https://github.com/WeblateOrg/wlc/compare/1.15...1.16.1)

Updates `granian[reload]` from 2.5.4 to 2.5.5
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.4...v2.5.5)

---
updated-dependencies:
- dependency-name: granian
  dependency-version: 2.5.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: certifi
  dependency-version: 2025.10.5
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: tomli
  dependency-version: 2.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: pylint
  dependency-version: 3.3.9
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: wlc
  dependency-version: 1.16.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: granian[reload]
  dependency-version: 2.5.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
2025-10-10 09:09:57 +02:00
Markus Heiser
954f0f62b4 [fix] startpage engine - SafeSearch works in reverse (#5290)
The Name of the option is *disable_family_filter* ->  we have to reverse the
meaning of the ascending safe-search filter level.

Closes: https://github.com/searxng/searxng/issues/5287

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-09 16:06:46 +02:00
Markus Heiser
898fbe7bc2 [mod] ci: add cp3.14 (part 2)
Use stable version (remove `-dev` suffix).
Stop CI on error [1] / Don't ignore when 3.14 ends with ERROR.

[1] https://github.com/searxng/searxng/pull/5217

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-08 13:47:22 +02:00
Markus Heiser
d16283d93a [fix:py3.14] using a non-empty mutable collection as default is unsafe
Starting with Python 3.14 msgspec reports::

    File "/share/searxng/searx/weather.py", line 261, in <module>
        class Temperature(msgspec.Struct, kw_only=True):
        ...<60 lines>...
                return template.format(value=val_str, unit=unit)
    TypeError: Using a non-empty mutable collection (['°C', '°F', 'K']) \
               as a default value is unsafe.\
               Instead configure a `default_factory` for this field.

The problem is solved by the fact that there are now global constants for the
units (BTW singular/plural names of the type definitions are fixed):

- TEMPERATURE_UNITS
- PRESSURE_UNITS
- WIND_SPEED_UNITS
- RELATIVE_HUMIDITY_UNITS
- COMPASS_POINTS
- COMPASS_UNITS

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-08 13:47:22 +02:00
Markus Heiser
8fdc59a760 [fix:py3.14] Struct fields aren't discovered in Python 3.14
This is a temporary workaround for #5284 [1].  However, the problem must be
solved at a different level, in msgspec [2].

[1] https://github.com/searxng/searxng/issues/5284
[2] https://github.com/jcrist/msgspec/issues/847

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-08 13:47:22 +02:00
Markus Heiser
d8d5de4d47 [fix] google scholar - detect CAPTCHA (HTTP redirects) (#5268)
In the case of .. response, for example, an HTTP 302 is returned by Google
Scholar::

    Our systems have detected unusual traffic from your computer
    network. Please try again later.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-06 10:12:38 +02:00
Markus Heiser
34eb32f418 [fix] ModuleNotFoundError: No module named 'lxml' (#5254)
When installing SearXNG (e.g.):

    pip install --use-pep517 --no-build-isolation -e .

An import exception is raised:

    ModuleNotFoundError: No module named 'lxml'

The ``setup.py`` file imports ``searx``, which in turn triggers various other
imports.  However, the name XPath is only needed for type checking.

Closes: https://github.com/searxng/searxng/issues/5177

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-05 11:44:13 +02:00
dependabot[bot]
7bf65d68c2 [upd] pypi: Bump the minor group with 2 updates (#5274)
Bumps the minor group with 2 updates: [selenium](https://github.com/SeleniumHQ/Selenium) and [basedpyright](https://github.com/detachhead/basedpyright).


Updates `selenium` from 4.35.0 to 4.36.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.35.0...selenium-4.36.0)

Updates `basedpyright` from 1.31.5 to 1.31.6
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.31.5...v1.31.6)

---
updated-dependencies:
- dependency-name: selenium
  dependency-version: 4.36.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: basedpyright
  dependency-version: 1.31.6
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
2025-10-04 18:07:44 +02:00
dependabot[bot]
e0b680853d [upd] web-client (simple): Bump the minor group (#5277)
Bumps the minor group in /client/simple with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) | `2.2.4` | `2.2.5` |
| [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) | `24.5.2` | `24.6.2` |
| [browserslist](https://github.com/browserslist/browserslist) | `4.26.2` | `4.26.3` |
| [lightningcss](https://github.com/parcel-bundler/lightningcss) | `1.30.1` | `1.30.2` |
| [typescript](https://github.com/microsoft/TypeScript) | `5.9.2` | `5.9.3` |

Updates `@biomejs/biome` from 2.2.4 to 2.2.5
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.2.5/packages/@biomejs/biome)

Updates `@types/node` from 24.5.2 to 24.6.2
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `browserslist` from 4.26.2 to 4.26.3
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.26.2...4.26.3)

Updates `lightningcss` from 1.30.1 to 1.30.2
- [Release notes](https://github.com/parcel-bundler/lightningcss/releases)
- [Commits](https://github.com/parcel-bundler/lightningcss/compare/v1.30.1...v1.30.2)

Updates `typescript` from 5.9.2 to 5.9.3
- [Release notes](https://github.com/microsoft/TypeScript/releases)
- [Changelog](https://github.com/microsoft/TypeScript/blob/main/azure-pipelines.release-publish.yml)
- [Commits](https://github.com/microsoft/TypeScript/compare/v5.9.2...v5.9.3)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.2.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 24.6.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: browserslist
  dependency-version: 4.26.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: lightningcss
  dependency-version: 1.30.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: typescript
  dependency-version: 5.9.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-04 14:22:51 +02:00
github-actions[bot]
cdf5f4343a [l10n] update translations from Weblate (#5278)
9e090cc25 - 2025-10-01 - Ricky-Tigg <ricky-tigg@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-10-03 10:14:21 +02:00
dependabot[bot]
3c63d346d9 [upd] github-actions: Bump github/codeql-action from 3.30.4 to 3.30.6 (#5276)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.30.4 to 3.30.6.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](303c0aef88...64d10c1313)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.30.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-03 09:46:04 +02:00
dependabot[bot]
43a5129a1c [upd] github-actions: Bump docker/login-action from 3.5.0 to 3.6.0 (#5275)
Bumps [docker/login-action](https://github.com/docker/login-action) from 3.5.0 to 3.6.0.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](184bdaa072...5e57cd1181)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-version: 3.6.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-03 09:45:15 +02:00
Markus Heiser
c6f1ea12b1 [fix] engine - cppreference has no longer a search function (#5273)
cppreference has replaced its search (``mwiki/index.php?title=``) with a DDG
search.

The engine was first introduced in SearXNG with PR-3274 [1], and even back then
the mediawiki proved to be incompatible, which is why the API could not be used
at the time. Now there isn't even a dedicated search function anymore.. I think
the cppreference project suffers from a lack of maintenance.

[1] https://github.com/searxng/searxng/pull/3247

Closes: https://github.com/searxng/searxng/issues/5271

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-03 08:40:24 +02:00
Markus Heiser
06e4f4f758 [mod] drop searxng_extra/standalone_searx.py (#5256)
This is an old and grumpy hack / SearXNG is a Flask application with
client/server structure, which can't be turned into a command line tool the way
it was done here.

Maintaining this hack is becoming increasingly complex the more we try to
remodel the core code, which is why we should now remove the hack from SearXNG.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-01 07:34:53 +02:00
Markus Heiser
748b521ac6 [fix] searx/results.py - TypeError: object of type 'NoneType' has no len()
In some engines, under certain circumstances, the content field can also have
the value ``None``; in these cases, a length check results in an exception::

    File "/usr/local/searxng/searx/results.py", line 360, in merge_two_main_results
        if len(other.content) > len(origin.content):
           ^^^^^^^^^^^^^^^^^^
    TypeError: object of type 'NoneType' has no len()

[1] https://github.com/searxng/searxng/issues/5250#issuecomment-3352863488

Reported-by: @scross01 [1]
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-01 07:13:10 +02:00
Markus Heiser
e16b6cb148 [fix] JSON format: serialization of the result-types
The ``JSONEncoder`` (``format="json"``) must perform a conversion to the
built-in types for the ``msgspec.Struct``::

    if isinstance(o, msgspec.Struct):
        return msgspec.to_builtins(o)

The result types are already of type ``msgspec.Struct``, so they can be
converted into built-in types.

The field types (in the result type) that were not yet of type ``msgspec.Struct``
have been converted to::

    searx.weather.GeoLocation@dataclass -> msgspec.Struct
    searx.weather.DateTime              -> msgspec.Struct
    searx.weather.Temperature           -> msgspec.Struct
    searx.weather.PressureUnits         -> msgspec.Struct
    searx.weather.WindSpeed             -> msgspec.Struct
    searx.weather.RelativeHumidity      -> msgspec.Struct
    searx.weather.Compass               -> msgspec.Struct

BTW: Wherever it seemed sensible, the typing was also modernized in the modified
files.

Closes: https://github.com/searxng/searxng/issues/5250
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-01 07:13:10 +02:00
Ivan Gabaldon
41e0f2abf0 [doc] dev - cleanup asdf remnants and add a note about mise-en-place (#5264)
Notes on the developer environment with MISE have been added to the Quickstart
Guide.  We migrated `.tool-versions` to replace it with `mise` [1], so we can
now remove `asdf` related documentation.

[1] https://github.com/searxng/searxng/pull/5253

Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-10-01 06:29:07 +02:00
searxng-bot
0f3ef5da59 [data] update searx.data - update_engine_traits.py 2025-09-30 16:48:59 +02:00
Markus Heiser
defd4d87c4 [fix] fetch traits, even for inactive instances
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-30 16:48:59 +02:00
Ivan Gabaldon
ebc61debf9 [fix] ci: missing container (#5263)
This workflow is no longer needed.
2025-09-29 15:15:54 +02:00
github-actions[bot]
77fd3ee534 [data] update searx.data - update_currencies.py (#5261)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-09-29 07:37:30 +02:00
github-actions[bot]
b8e60542d9 [data] update searx.data - update_engine_descriptions.py (#5262)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-09-29 07:36:51 +02:00
github-actions[bot]
5513549adc [data] update searx.data - update_wikidata_units.py (#5259)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-09-29 07:35:10 +02:00
github-actions[bot]
cd2ea7c5f5 [data] update searx.data - update_ahmia_blacklist.py (#5257)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-09-29 07:34:38 +02:00
searxng-bot
38b80133f7 [data] update searx.data - update_firefox_version.py 2025-09-29 07:33:19 +02:00
Markus Heiser
2f0d96b8bc [fix] sqlitedb: DB connector -- unset isolation_level
A Connection object can be used as a context manager that automatically commits
or rolls back open transactions when leaving the body of the context manager.

If the connection attribute ``isolation_level`` is **not** ``None``, new
transactions are implicitly opened before ``execute()`` and ``executemany()``
executes SQL- INSERT, UPDATE, DELETE, or REPLACE statements [1].

The old implementation set ``isolation_level`` to ``None`` and thereby prevented
the context manager from opening and closing the transaction scopes.

[1] https://docs.python.org/3/library/sqlite3.html#sqlite3-transaction-control-isolation-level
[2] https://github.com/searxng/searxng/pull/5239#discussion_r2381416731

Reported-by: Ivan G <igabaldon@inetol.net> [2]
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-28 07:32:41 +02:00
Markus Heiser
18a58943cc [mod] ExpireCacheSQLite - implement .setmany() for bulk loading
[1] https://github.com/searxng/searxng/issues/5223#issuecomment-3328597147

Suggested-by: Ivan G <igabaldon@inetol.net> [1]
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-28 07:32:41 +02:00
Markus Heiser
4f4de3fc87 [fix] openstreetmap: fix CURRENCIES.iso4217_to_name
This patch is a leftover from PR-5204 [1].

[1] https://github.com/searxng/searxng/pull/5204

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-28 07:32:41 +02:00
Markus Heiser
4445f26f5a [mod] run bootload of the CURRENCIES cache on demand
In [1] it can be seen that the bootload of the CURRENCIES cache takes about 2/3
of the time required to initialize SearXNG.  Whatever the absolute durations may
be, an explicit bootload during the SearXNG initialization is not required, as
the bootload is already ensured by the API of the CACHE.

- ``CurrenciesDB.name_to_iso4217``
- ``CurrenciesDB.iso4217_to_name``

The fact that the bootload now occurs on-demand should improve the
initialization time of SearXNG.

[1] https://github.com/searxng/searxng/issues/5223#issuecomment-3323083411

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-28 07:32:41 +02:00
Markus Heiser
62b0b3f697 [mod] debug-log the bootload of the CURRENCIES caches (CurrenciesDB)
The time for the bootload is measured and recorded.  To have an eye on the
bootload time is motivated by: In [1] it can be seen that the bootload of the
CURRENCIES cache takes about 2/3 of the time required to initialize SearXNG::

    6.068 <module>  searx/webapp.py:1
    └─ 6.068 wrapper  pyinstrument/context_manager.py:52
       ├─ 5.538 init  searx/webapp.py:1373
       │  ├─ 4.822 initialize  searx/search/__init__.py:34
       │  │  ├─ 4.631 ProcessorMap.init  searx/search/processors/__init__.py:47
       │  │  │  ├─ 4.607 OnlineCurrencyProcessor.initialize  searx/search/processors/online_currency.py:55
       │  │  │  │  └─ 4.607 CurrenciesDB.init  searx/data/currencies.py:25
       │  │  │  │     ├─ 4.601 CurrenciesDB.load  searx/data/currencies.py:34
       │  │  │  │     │  ├─ 4.572 ExpireCacheSQLite.set  searx/cache.py:334

In the example, the CurrenciesDB.init call takes 4.6 seconds... on my laptop,
CurrenciesDB.init takes only 0.7 seconds.  The absolute numerical values depend
on external conditions, where I already find 4-5 seconds very long. Test::

    $ rm /tmp/sxng_cache_*.db*
    $ make run 2>&1 | grep "searx.data.CURRENCIES"
    DEBUG   searx.data : init searx.data.CURRENCIES
    DEBUG   searx.data : init searx.data.CURRENCIES added 9089 items in 0.7623255252838135 sec.

[1] https://github.com/searxng/searxng/issues/5223#issuecomment-3323083411

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-28 07:32:41 +02:00
Markus Heiser
87bc97776a [mod] pin external developer tools (mise en place) (#5253)
Mise en place config [1] does no longer support ``.tool-versions``
compatibility syntax, migrate to TOML ``mise.toml``.

In ``utils/lib_sxng_node.sh`` the node version was not updated, update to
24.3.0 (compare ``mise.toml``).

[1] https://mise.jdx.dev/configuration.html

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-27 07:18:50 +02:00
Markus Heiser
77068ce20b [upd] pypi: Bump sphinx from 7.4.7 to 8.2.3 (#5252)
- supersede: https://github.com/searxng/searxng/pull/4377

Sphinx 8.2 dropped Python 3.10 support, last versions supporting Python 3.10:

- Sphinx==8.1.3
- sphinx-autobuild==2024.10.3

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-26 16:57:01 +02:00
Markus Heiser
81cbe0befe [upd] pypi: Bump black from 24.3.0 to 25.9.0 (#5251)
In 25.1.0 [2] an old bug has been fixed: "Docstring formatting does not apply to
module docstrings" [3].

[1] https://github.com/psf/black/blob/main/CHANGES.md#2590
[2] https://github.com/psf/black/blob/main/CHANGES.md#2510
[3] https://github.com/psf/black/issues/4094

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-26 12:35:57 +02:00
dependabot[bot]
1091643f32 [upd] github-actions: Bump actions/cache from 4.2.4 to 4.3.0 (#5249)
Bumps [actions/cache](https://github.com/actions/cache) from 4.2.4 to 4.3.0.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](0400d5f644...0057852bfa)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: 4.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-26 10:46:19 +02:00
dependabot[bot]
899ae9a6e4 [upd] pypi: Bump myst-parser from 3.0.1 to 4.0.0 (#3719)
Bumps [myst-parser](https://github.com/executablebooks/MyST-Parser) from 3.0.1 to 4.0.0.
- [Release notes](https://github.com/executablebooks/MyST-Parser/releases)
- [Changelog](https://github.com/executablebooks/MyST-Parser/blob/master/CHANGELOG.md)
- [Commits](https://github.com/executablebooks/MyST-Parser/compare/v3.0.1...v4.0.0)

---
updated-dependencies:
- dependency-name: myst-parser
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-26 10:32:01 +02:00
dependabot[bot]
454f95a661 [upd] github-actions: Bump snok/container-retention-policy (#5248)
Bumps [snok/container-retention-policy](https://github.com/snok/container-retention-policy) from 3.0.0 to 3.0.1.
- [Release notes](https://github.com/snok/container-retention-policy/releases)
- [Commits](4f22ef8090...3b0972b227)

---
updated-dependencies:
- dependency-name: snok/container-retention-policy
  dependency-version: 3.0.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-26 10:03:19 +02:00
dependabot[bot]
a9ae0163ad [upd] github-actions: Bump github/codeql-action from 3.30.3 to 3.30.4 (#5247)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.30.3 to 3.30.4.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](192325c861...303c0aef88)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.30.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-26 10:01:01 +02:00
dependabot[bot]
2a759f18da [upd] pypi: Bump the minor group with 4 updates (#5246)
Bumps the minor group with 4 updates: [lxml](https://github.com/lxml/lxml), [pyyaml](https://github.com/yaml/pyyaml), [typer-slim](https://github.com/fastapi/typer) and [basedpyright](https://github.com/detachhead/basedpyright).


Updates `lxml` from 6.0.1 to 6.0.2
- [Release notes](https://github.com/lxml/lxml/releases)
- [Changelog](https://github.com/lxml/lxml/blob/master/CHANGES.txt)
- [Commits](https://github.com/lxml/lxml/compare/lxml-6.0.1...lxml-6.0.2)

Updates `pyyaml` from 6.0.2 to 6.0.3
- [Release notes](https://github.com/yaml/pyyaml/releases)
- [Changelog](https://github.com/yaml/pyyaml/blob/6.0.3/CHANGES)
- [Commits](https://github.com/yaml/pyyaml/compare/6.0.2...6.0.3)

Updates `typer-slim` from 0.17.4 to 0.19.2
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.17.4...0.19.2)

Updates `basedpyright` from 1.31.4 to 1.31.5
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.31.4...v1.31.5)
2025-09-26 09:56:32 +02:00
Markus Heiser
7322b07df6 [fix] ProcessorMap: fix error log, not enough arguments for format string (#5241)
Issue was introduced by PR-5204 [1]

reported issue::

    logger.error("init method of engine %s failed (%s).", eng_proc.engine.name)
    TypeError: not enough arguments for format string

[1] https://github.com/searxng/searxng/pull/5204

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-25 08:24:02 +02:00
Markus Heiser
4f4587650c [build] /static 2025-09-25 06:34:19 +02:00
Markus Heiser
8f854540a9 [fix] simple client: move code.less to result_types/code.less
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-25 06:34:19 +02:00
Ivan Gabaldon
3bf702447b [enh] container: custom certificates (#5238)
Let container instance administrators to add custom certificates:

  https://docs.searxng.org/admin/installation-docker.html#custom-certificates

Closes https://github.com/searxng/searxng/issues/5206
2025-09-23 21:57:29 +02:00
Ivan Gabaldon
d2e2802514 [fix] utils: variable expansion (#5237)
Docker buildx outputs the following error:

  variable expansion is not supported for --from, define a new stage with FROM
  using ARG from global scope as a workaround.

Also force BuildKit extension to be installed, legacy build is no longer
supported.

Closes https://github.com/searxng/searxng/issues/5219
2025-09-23 20:34:28 +02:00
Ivan Gabaldon
a57b29b009 [enh] container: compact venv (#5225)
We can leverage the immutable nature of containers to add additional
optimizations.

No debugging or tinkering inside containers, so stripping all unused symbols
inside `venv` should be fine. We are also going to compile the bytecode
ourselves to modify some parameters related to reproducibility.

With these small changes, we have reduced the `venv` layer size by 10MB~
2025-09-23 09:50:42 +02:00
Ivan Gabaldon
b7ecc1c240 [enh] container: reproducible layers (#5222)
* [enh] container: reproducible layers

We are not aiming for reproducibility compliance, but we look to make most
builder layers reproducible without caching at least for a short period of time
(until the builder's base image changes or the child dependencies of a
requirements.txt package are updated).

This feature is only available on Podman.

This targets https://github.com/searxng/searxng/pull/5086 main goal.

* [fix] misc: apply suggestions

Suggested: https://github.com/searxng/searxng/pull/5222#discussion_r2364630496
Suggested: https://github.com/searxng/searxng/pull/5222#discussion_r2364630511

* [enh] container: prevent useless layer
2025-09-20 11:33:23 +02:00
Ivan Gabaldon
164167dea0 [mod] py: remove uvloop (#5220)
We get some good stuff without uvloop, 13MB~ less of dependencies, 3
minutes of build time for armv7 saved, and we are one step closer to NT
compatibility. Although it's true that theoretically the raw performance
have worsened on network side (we only used uvloop for that), the latest
cpython versions have been improving on asyncio performance.
2025-09-20 11:12:34 +02:00
github-actions[bot]
b3eb7657b9 [l10n] update translations from Weblate (#5216)
a0783e1a1 - 2025-09-16 - recreationalprogamer <recreationalprogamer@noreply.codeberg.org>
130f66498 - 2025-09-13 - artnay <artnay@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-09-20 10:57:35 +02:00
Markus Heiser
d2b4bff856 [mod] demo engines: smaller improvement
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
1520a8d545 [mod] ADS engine: revision of the engine (Paper result)
Revision of the Astrophysics Data System (ADS) engine / use of the result type
Paper as well as other typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
f8f7adce6b [mod] Z-Library engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

The engine has been placed on inactive because no service is currently
available, or at least not known in the SearXNG community [1]

[1] https://github.com/searxng/searxng/issues/3610

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
4c42704c80 [mod] Springer Nature engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
4b4bf0ecaf [mod] Semantic Scholar engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
bb22bb1831 [mod] PubMed engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
96e63df8ca [mod] Open Library engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
0691e50e13 [mod] OpenAlex engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
599d9488c5 [mod] Google Scholar engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
078c9fcb68 [mod] Crossref engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
3ec6d65f9b [mod] CORE engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
22e73727c0 [mod] Anna's Archive engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
6c3fb9e42b [mod] arXiv engine: revision of the engine (Paper result)
Revision of the engine / use of the result type Paper as well as other
typifications.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Markus Heiser
f9b4869426 [build] /static 2025-09-20 10:56:46 +02:00
Markus Heiser
7eedd44f5f [mod] typification of SearXNG: add new result type Paper
This patch adds a new result type: Paper

- Python class:   searx/result_types/paper.py
- Jinja template: searx/templates/simple/result_templates/paper.html
- CSS (less)      client/simple/src/less/result_types/paper.less

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-20 10:56:46 +02:00
Léon Tiekötter
57ef342ad1 [fix] image proxy: object has no attribute 'status_code' (#5212)
Commit 8f8343d [1] introduced a bug in the network logic of SearXNG where stream
requests (such as the one from the image proxy) would fail because a wrapper was
returned instead of a response object with the correct attribute.

This is just a quick in place fix I implemented to get it working again. It
would be better to implement corresponding logic to give stream requests the
correct object.

[1] https://github.com/searxng/searxng/pull/5204
2025-09-20 07:54:58 +02:00
Ivan Gabaldon
0ce0d957b1 [mod] ci: add cp3.14 (#5217) 2025-09-19 19:41:32 +02:00
dependabot[bot]
a54b862f00 [upd] pypi: Bump the minor group with 3 updates (#5213)
Bumps the minor group with 3 updates: [whitenoise](https://github.com/evansd/whitenoise), [granian[reload]](https://github.com/emmett-framework/granian) and [granian](https://github.com/emmett-framework/granian).


Updates `whitenoise` from 6.10.0 to 6.11.0
- [Changelog](https://github.com/evansd/whitenoise/blob/main/docs/changelog.rst)
- [Commits](https://github.com/evansd/whitenoise/compare/6.10.0...6.11.0)

Updates `granian[reload]` from 2.5.3 to 2.5.4
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.3...v2.5.4)

Updates `granian` from 2.5.3 to 2.5.4
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.3...v2.5.4)

---
updated-dependencies:
- dependency-name: whitenoise
  dependency-version: 6.11.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: granian[reload]
  dependency-version: 2.5.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: granian
  dependency-version: 2.5.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-19 11:20:05 +02:00
dependabot[bot]
aeab5ac546 [upd] web-client (simple): Bump the minor group in /client/simple with 3 updates (#5215)
* [upd] web-client (simple): Bump the minor group

Bumps the minor group in /client/simple with 3 updates: [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node), [browserslist](https://github.com/browserslist/browserslist) and [sharp](https://github.com/lovell/sharp).


Updates `@types/node` from 24.3.1 to 24.5.2
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `browserslist` from 4.25.4 to 4.26.2
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.25.4...4.26.2)

Updates `sharp` from 0.34.3 to 0.34.4
- [Release notes](https://github.com/lovell/sharp/releases)
- [Commits](https://github.com/lovell/sharp/compare/v0.34.3...v0.34.4)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-version: 24.5.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: browserslist
  dependency-version: 4.26.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: sharp
  dependency-version: 0.34.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* update rolldown-vite

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-09-19 10:44:59 +02:00
Markus Heiser
09fddfde24 [mod] demo engines: smaller corrections and improvements
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-18 19:40:03 +02:00
Markus Heiser
8f8343dc0d [mod] addition of various type hints / engine processors
Continuation of #5147 .. typification of the engine processors.

BTW:

- removed obsolete engine property https_support
- fixed & improved currency_convert
- engine instances can now implement a engine.setup method

[#5147] https://github.com/searxng/searxng/pull/5147

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-18 19:40:03 +02:00
dependabot[bot]
23257bddce [upd] pypi: Bump the minor group with 5 updates (#5200)
Bumps the minor group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [setproctitle](https://github.com/dvarrazzo/py-setproctitle) | `1.3.6` | `1.3.7` |
| [typer-slim](https://github.com/fastapi/typer) | `0.17.3` | `0.17.4` |
| [whitenoise](https://github.com/evansd/whitenoise) | `6.9.0` | `6.10.0` |
| [granian[reload]](https://github.com/emmett-framework/granian) | `2.5.2` | `2.5.3` |
| [granian](https://github.com/emmett-framework/granian) | `2.5.2` | `2.5.3` |


Updates `setproctitle` from 1.3.6 to 1.3.7
- [Changelog](https://github.com/dvarrazzo/py-setproctitle/blob/master/HISTORY.rst)
- [Commits](https://github.com/dvarrazzo/py-setproctitle/compare/version-1.3.6...version-1.3.7)

Updates `typer-slim` from 0.17.3 to 0.17.4
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.17.3...0.17.4)

Updates `whitenoise` from 6.9.0 to 6.10.0
- [Changelog](https://github.com/evansd/whitenoise/blob/main/docs/changelog.rst)
- [Commits](https://github.com/evansd/whitenoise/compare/6.9.0...6.10.0)

Updates `granian[reload]` from 2.5.2 to 2.5.3
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.2...v2.5.3)

Updates `granian` from 2.5.2 to 2.5.3
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.2...v2.5.3)
2025-09-14 10:48:04 +02:00
Ivan Gabaldon
a0d2ecf434 [enh] container: build with uv (#5199)
This commit replaces `pip` in container builds with `uv` pip compat
with a 1:1 parity. The only thing that changes is the installation speed of the
wheels, which seems to be considerably faster, although I haven't been able to
properly quantify this yet.

uv also gives us more tools to manage the cache. We can revert the prior cache
changes in `container.yml` as we won't have duplicated wheels anymore.
2025-09-14 10:36:21 +02:00
dependabot[bot]
687121d584 [upd] web-client (simple): Bump the minor group in /client/simple with 2 updates (#5202)
* [upd] web-client (simple): Bump the minor group

Bumps the minor group in /client/simple with 2 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) and [stylelint](https://github.com/stylelint/stylelint).


Updates `@biomejs/biome` from 2.2.2 to 2.2.4
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.2.4/packages/@biomejs/biome)

Updates `stylelint` from 16.23.1 to 16.24.0
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/16.23.1...16.24.0)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.2.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: stylelint
  dependency-version: 16.24.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* update biome schema

* update rolldown

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-09-12 10:59:25 +02:00
dependabot[bot]
4694ba202a [upd] github-actions: Bump github/codeql-action from 3.30.0 to 3.30.3 (#5201)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.30.0 to 3.30.3.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](2d92b76c45...192325c861)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.30.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-12 10:15:21 +02:00
github-actions[bot]
d79ad7457f [l10n] update translations from Weblate (#5203)
2ea8fc600 - 2025-09-11 - eudemo <eudemo@noreply.codeberg.org>
169797e8b - 2025-09-10 - alexgabi <alexgabi@noreply.codeberg.org>
822f66416 - 2025-09-11 - grumpyoldtechie <grumpyoldtechie@noreply.codeberg.org>
daba8370d - 2025-09-07 - EmilyOrSomething <emilyorsomething@noreply.codeberg.org>
2025-09-12 09:53:37 +02:00
Ivan Gabaldon
7c1ebc0148 [fix] container: add musl-locales packages 2025-09-11 06:38:45 +02:00
Ivan Gabaldon
7b02369a12 [fix] container: add tzdata package
https://github.com/searxng/searxng/pull/5192
2025-09-11 06:38:45 +02:00
Markus Heiser
a9b088d832 [feat] engines yacy & piped: enable individual configuration of URLs (#5195)
With this change it is possible with individual engines (yacy & piped)
to configure individual URLs.

Related:

- https://github.com/searxng/searxng/issues/4869#issuecomment-327335928
- https://github.com/searxng/searxng/pull/3472/files#r1595586019
- https://github.com/searxng/searxng/issues/3428#issuecomment-2102142530

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-10 12:57:36 +02:00
Markus Heiser
97ed5ef9f1 [fix] links in the README (link file in GH-UI / not the raw file) 2025-09-09 21:00:36 +02:00
Ivan Gabaldon
57b74beeea [enh] docs: update information (#5185)
README should be concise, everything else goes to CONTRIBUTING, docs
page ...
2025-09-09 20:51:22 +02:00
Austin-Olacsi
905b13aa7e [feat] naver engine: add video embeds 2025-09-09 17:04:21 +02:00
Brock Vojkovic
314924bc0e [upd] disable public domain image archive engine by default 2025-09-09 16:58:27 +08:00
dependabot[bot]
e7501eaedf [upd] pypi: Bump the minor group across 1 directory with 5 updates (#5184)
Bumps the minor group with 5 updates in the / directory:

| Package | From | To |
| --- | --- | --- |
| [typer-slim](https://github.com/fastapi/typer) | `0.16.1` | `0.17.3` |
| [granian[reload]](https://github.com/emmett-framework/granian) | `2.5.1` | `2.5.2` |
| [basedpyright](https://github.com/detachhead/basedpyright) | `1.31.3` | `1.31.4` |
| [types-lxml](https://github.com/abelcheung/types-lxml) | `2025.3.30` | `2025.8.25` |
| [granian](https://github.com/emmett-framework/granian) | `2.5.1` | `2.5.2` |



Updates `typer-slim` from 0.16.1 to 0.17.3
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.16.1...0.17.3)

Updates `granian[reload]` from 2.5.1 to 2.5.2
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.1...v2.5.2)

Updates `basedpyright` from 1.31.3 to 1.31.4
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.31.3...v1.31.4)

Updates `types-lxml` from 2025.3.30 to 2025.8.25
- [Release notes](https://github.com/abelcheung/types-lxml/releases)
- [Commits](https://github.com/abelcheung/types-lxml/compare/2025.03.30...2025.08.25)

Updates `granian` from 2.5.1 to 2.5.2
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.1...v2.5.2)
2025-09-05 13:23:01 +02:00
dependabot[bot]
25953fa32e [upd] github-actions: Bump actions/setup-python from 5.6.0 to 6.0.0 (#5181)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5.6.0 to 6.0.0.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](a26af69be9...e797f83bcb)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-05 11:42:40 +02:00
dependabot[bot]
a966e10bf5 [upd] web-client (simple): Bump the minor group in /client/simple with 2 updates (#5179)
* [upd] web-client (simple): Bump the minor group

Bumps the minor group in /client/simple with 2 updates: [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) and [vite-bundle-analyzer](https://github.com/nonzzz/vite-bundle-analyzer).


Updates `@types/node` from 24.3.0 to 24.3.1
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `vite-bundle-analyzer` from 1.2.2 to 1.2.3
- [Release notes](https://github.com/nonzzz/vite-bundle-analyzer/releases)
- [Changelog](https://github.com/nonzzz/vite-bundle-analyzer/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nonzzz/vite-bundle-analyzer/compare/v1.2.2...v1.2.3)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-version: 24.3.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: vite-bundle-analyzer
  dependency-version: 1.2.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* update rolldown-vite

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-09-05 11:38:54 +02:00
dependabot[bot]
d4173f129f [upd] github-actions: Bump actions/setup-node from 4.4.0 to 5.0.0 (#5180)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4.4.0 to 5.0.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](49933ea528...a0853c2454)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-05 11:13:40 +02:00
dependabot[bot]
02473b68df [upd] github-actions: Bump github/codeql-action from 3.29.11 to 3.30.0 (#5182)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.29.11 to 3.30.0.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](3c3833e0f8...2d92b76c45)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.30.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-05 11:11:04 +02:00
github-actions[bot]
5a0caf2663 [l10n] update translations from Weblate (#5183)
8b8b8007b - 2025-09-03 - choonarine <choonarine@noreply.codeberg.org>
2853b3d20 - 2025-09-03 - pywc <pywc@noreply.codeberg.org>
d5a641cda - 2025-09-02 - choonarine <choonarine@noreply.codeberg.org>
270a2efa1 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
356889a32 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
8623e089f - 2025-09-01 - Outbreak2096 <outbreak2096@noreply.codeberg.org>
ea0f92a74 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
864f485f8 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
b3a8ada39 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
2f322377d - 2025-09-01 - return42 <return42@noreply.codeberg.org>
5a4e08e13 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
2099c05fb - 2025-09-01 - return42 <return42@noreply.codeberg.org>
0d4dbe2e8 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
a85407137 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
8631fa640 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
bb9d32a1a - 2025-09-01 - return42 <return42@noreply.codeberg.org>
cd7998051 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
b1cc25fdc - 2025-09-01 - return42 <return42@noreply.codeberg.org>
a822989a3 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
6820b338b - 2025-09-01 - return42 <return42@noreply.codeberg.org>
f06ff0b86 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
17c0a4870 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
e74406e3d - 2025-09-01 - return42 <return42@noreply.codeberg.org>
fb8f1077b - 2025-09-01 - return42 <return42@noreply.codeberg.org>
d14309568 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
a24a3b03a - 2025-09-01 - return42 <return42@noreply.codeberg.org>
080a57782 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
1623f6626 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
fb5177b4d - 2025-09-01 - return42 <return42@noreply.codeberg.org>
f3df8b069 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
9f317f05b - 2025-09-01 - return42 <return42@noreply.codeberg.org>
55161e8ac - 2025-09-01 - return42 <return42@noreply.codeberg.org>
0ac1c3f8f - 2025-09-01 - return42 <return42@noreply.codeberg.org>
c905ec37d - 2025-09-01 - return42 <return42@noreply.codeberg.org>
176dc7ea3 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
b2760ff5f - 2025-09-01 - return42 <return42@noreply.codeberg.org>
9759e2dc2 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
0e5d0c729 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
3ac66987f - 2025-09-01 - return42 <return42@noreply.codeberg.org>
e3d7caf59 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
48b2f1261 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
17d1a44bd - 2025-09-01 - return42 <return42@noreply.codeberg.org>
ed29ae1a3 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
a385f79e8 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
e1bb2681a - 2025-09-01 - return42 <return42@noreply.codeberg.org>
be70384be - 2025-09-01 - return42 <return42@noreply.codeberg.org>
87770e507 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
9d31b74f7 - 2025-09-01 - return42 <return42@noreply.codeberg.org>
2025-09-05 11:09:02 +02:00
Markus Heiser
f91c998aa0 [docs] fix some typos in the description of result class Code (#5174)
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-03 14:53:01 +02:00
Markus Heiser
f24d85bc4b [mod] drop: from __future__ import annotations
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-03 13:37:36 +02:00
Markus Heiser
57b9673efb [mod] addition of various type hints / tbc
- pyright configuration [1]_
- stub files: types-lxml [2]_
- addition of various type hints
- enable use of new type system features on older Python versions [3]_
- ``.tool-versions`` - set python to lowest version we support (3.10.18) [4]_:
  Older versions typically lack some typing features found in newer Python
  versions.  Therefore, for local type checking (before commit), it is necessary
  to use the older Python interpreter.

.. [1] https://docs.basedpyright.com/v1.20.0/configuration/config-files/
.. [2] https://pypi.org/project/types-lxml/
.. [3] https://typing-extensions.readthedocs.io/en/latest/#
.. [4] https://mise.jdx.dev/configuration.html#tool-versions

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Format: reST
2025-09-03 13:37:36 +02:00
Butui Hu
09500459fe [fix} engine chinaso - parse_images ImageInfo key error (#5175)
Signed-off-by: Butui Hu <hot123tea123@gmail.com>
2025-09-03 05:59:18 +02:00
Bnyro
b93cc2f9f8 [feat] engines: add repology.org engine for linux packages (#5103)
Repology_ monitors a huge number of package repositories and other sources
comparing packages versions across them and gathering other information.

Repology_ shows you in which repositories a given project is packaged, which
version is the latest and which needs updating, who maintains the package, and
other related information.

.. _Repology: https://repology.org/docs/about

Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
Format: reST
2025-09-01 16:33:31 +02:00
Markus Heiser
501327ddf1 [fix] engine: searchcode.com is offline (inactive) (#5170)
Searchcode.com is offline, and its future is still uncertain [1], so the engine
will be deactivated for the time being. If Searchcode.com doesn't come back
online soon, we can remove the engine entirely.

[1] https://boyter.org/posts/searchcode-is-being-rebooted/
[2] https://github.com/searxng/searxng/pull/5131#issuecomment-3239156555


Reported-by: Bnyro <bnyro@tutanota.com> [2]

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-01 15:35:55 +02:00
Butui Hu
932fb22c80 [fix] chinaoso: add random uid to cookie (#5173)
Signed-off-by: Butui Hu <hot123tea123@gmail.com>
2025-09-01 15:34:17 +02:00
Markus Heiser
e5d2685d8d [build] /static 2025-09-01 14:51:15 +02:00
Markus Heiser
fb5fd8c819 [mod] simple client: pygments.less - switched dark theme to monokai
Compared to ``lightbulb`` theme we used in the past for the dark theme, the
``monokai`` has a better contrast [1].

BTW, the result list of SearXNG should not act as a code-checker: The border &
color of class ``.err`` (used for syntax errors) has been removed / code
snippets are often not well formed nor valid code and the rendering of such code
fragments as errors obscures the view on the code snippet.

[1] https://pygments.org/styles/

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-09-01 14:51:15 +02:00
Markus Heiser
9ac9c8c4f5 [mod] typification of SearXNG: add new result type Code
This patch adds a new result type: Code

- Python class:   searx/result_types/code.py
- Jinja template: searx/templates/simple/result_templates/code.html
- CSS (less)      client/simple/src/less/result_types/code.less

Signed-of-by: Markus Heiser <markus.heiser@darmarIT.de>
2025-09-01 14:51:15 +02:00
dependabot[bot]
b8085d27ac [upd] web-client (simple): Bump the minor group in /client/simple with 3 updates (#5165)
* [upd] web-client (simple): Bump the minor group

Bumps the minor group in /client/simple with 3 updates: [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome), [browserslist](https://github.com/browserslist/browserslist) and [vite-bundle-analyzer](https://github.com/nonzzz/vite-bundle-analyzer).


Updates `@biomejs/biome` from 2.2.0 to 2.2.2
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.2.2/packages/@biomejs/biome)

Updates `browserslist` from 4.25.3 to 4.25.4
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.25.3...4.25.4)

Updates `vite-bundle-analyzer` from 1.2.1 to 1.2.2
- [Release notes](https://github.com/nonzzz/vite-bundle-analyzer/releases)
- [Changelog](https://github.com/nonzzz/vite-bundle-analyzer/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nonzzz/vite-bundle-analyzer/compare/v1.2.1...v1.2.2)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.2.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: browserslist
  dependency-version: 4.25.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: vite-bundle-analyzer
  dependency-version: 1.2.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* [upd] simple client: lift biomejs schemas up to version 2.2.2

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-08-29 10:22:25 +02:00
dependabot[bot]
31322a49b6 [upd] pypi: Bump the minor group with 3 updates (#5166)
Bumps the minor group with 3 updates: [lxml](https://github.com/lxml/lxml), [granian[reload]](https://github.com/emmett-framework/granian) and [granian](https://github.com/emmett-framework/granian).


Updates `lxml` from 6.0.0 to 6.0.1
- [Release notes](https://github.com/lxml/lxml/releases)
- [Changelog](https://github.com/lxml/lxml/blob/master/CHANGES.txt)
- [Commits](https://github.com/lxml/lxml/compare/lxml-6.0.0...lxml-6.0.1)

Updates `granian[reload]` from 2.5.0 to 2.5.1
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.0...v2.5.1)

Updates `granian` from 2.5.0 to 2.5.1
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.5.0...v2.5.1)
2025-08-29 09:13:44 +02:00
github-actions[bot]
7e353f74f7 [l10n] update translations from Weblate (#5168)
87a404001 - 2025-08-28 - hhadi34 <hhadi34@noreply.codeberg.org>
86cd8cd7a - 2025-08-29 - lucasmz.dev <lucasmz.dev@noreply.codeberg.org>
7488333e6 - 2025-08-29 - ghose <ghose@noreply.codeberg.org>
d03da377c - 2025-08-29 - return42 <return42@noreply.codeberg.org>
c63fa5248 - 2025-08-28 - kratos <makesocialfoss32@keemail.me>
db35c0bfe - 2025-08-28 - Artiman <artiman@noreply.codeberg.org>
13028fa72 - 2025-08-28 - return42 <return42@noreply.codeberg.org>
d984f1cef - 2025-08-28 - return42 <return42@noreply.codeberg.org>
4ec477015 - 2025-08-28 - SomeTr <sometr@noreply.codeberg.org>
a74603ff8 - 2025-08-28 - sprinklerillicitly <sprinklerillicitly@noreply.codeberg.org>
2025-08-29 09:12:35 +02:00
github-actions[bot]
fde4fac3ca [data] update searx.data - update_external_bangs.py (#5158) 2025-08-29 07:07:46 +02:00
github-actions[bot]
a9263fd063 [data] update searx.data - update_wikidata_units.py (#5159) 2025-08-29 07:07:00 +02:00
github-actions[bot]
146cefe7fa [data] update searx.data - update_firefox_version.py (#5160) 2025-08-29 07:05:08 +02:00
github-actions[bot]
2a7d26b714 [data] update searx.data - update_ahmia_blacklist.py (#5161) 2025-08-29 07:04:41 +02:00
github-actions[bot]
480914d736 [data] update searx.data - update_currencies.py (#5162) 2025-08-29 07:04:12 +02:00
github-actions[bot]
edc50768cc [data] update searx.data - update_engine_traits.py (#5163) 2025-08-29 07:03:29 +02:00
github-actions[bot]
a519a13bfa [data] update searx.data - update_engine_descriptions.py (#5164) 2025-08-29 07:02:31 +02:00
Bnyro
f971774773 [fix] annas archive: engine broken due to site HTML changes
Apparently the layout of https://annas-archive.org has changed, making changes necessary.

The issue has been reported in #5146, see there for more details.

- closes #5146
2025-08-28 19:24:37 +02:00
Bnyro
5ca08c1813 [feat] plugins: add new time/timezone search plugin
The plugin uses the ``GeoLocation`` class, which is already implemented in the
context of weather forecasts, to determine the time zone. The ``DateTime`` class
is used for the localized display of date and time.

Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-08-28 10:49:50 +02:00
Markus Heiser
90e602b349 [fix] typo in the docs about HTML method POST versus GET 2025-08-27 10:17:24 +02:00
Markus Heiser
71f90755c4 [doc] fix missing link in `default_http_headers` description
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Format: reST
2025-08-26 08:20:56 +02:00
Markus Heiser
92463ce6a7 [doc] adds the missing documentation of the server.method settings.
TL;DR; For all the issues that comes with HTTP POST I recommend instance
maintainers to switch to GET and lock the property in the preferences:

```yaml
server:
  method: GET

preferences:
  lock:
    - method
```

We don't want this in the defaults of the SearXNG distributions for the pros vs
cons listed in this discussion:

- https://github.com/searxng/searxng/pull/3619
2025-08-26 08:20:56 +02:00
Markus Heiser
a369fe8f29 [mod] py3.9 EOL (#5148)
[1] https://devguide.python.org/versions/
[2] https://peps.python.org/pep-0596/

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-08-26 07:46:20 +02:00
muthukumaran R
a0ff173799 [feat] engines: add OpenAlex Works engine (#5102)
- Adds a new engine `searx/engines/openalex.py` that integrates the OpenAlex
  Works API to return scientific paper results using the `paper.html` template.
- Uses the official API (no auth required); supports OpenAlex polite pool via `mailto`.
- Adds developer docs at `docs/dev/engines/online/openalex.rst`.

OpenAlex API reference: https://docs.openalex.org/how-to-use-the-api/api-overview
2025-08-24 14:17:30 +02:00
dependabot[bot]
11ea1a8134 [upd] web-client (simple): Bump the minor group (#5144)
Bumps the minor group in /client/simple with 2 updates: [browserslist](https://github.com/browserslist/browserslist) and [less](https://github.com/less/less.js).


Updates `browserslist` from 4.25.2 to 4.25.3
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.25.2...4.25.3)

Updates `less` from 4.4.0 to 4.4.1
- [Release notes](https://github.com/less/less.js/releases)
- [Changelog](https://github.com/less/less.js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/less/less.js/commits)

---
updated-dependencies:
- dependency-name: browserslist
  dependency-version: 4.25.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: less
  dependency-version: 4.4.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-22 10:04:37 +02:00
dependabot[bot]
e22ebd8817 [upd] github-actions: Bump github/codeql-action from 3.29.9 to 3.29.11 (#5143)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.29.9 to 3.29.11.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](df559355d5...3c3833e0f8)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.29.11
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-22 10:01:53 +02:00
dependabot[bot]
d8048dc75b [upd] pypi: Bump the minor group with 4 updates (#5142)
Bumps the minor group with 4 updates: [flask](https://github.com/pallets/flask), [typer-slim](https://github.com/fastapi/typer), [pylint](https://github.com/pylint-dev/pylint) and [basedpyright](https://github.com/detachhead/basedpyright).


Updates `flask` from 3.1.1 to 3.1.2
- [Release notes](https://github.com/pallets/flask/releases)
- [Changelog](https://github.com/pallets/flask/blob/main/CHANGES.rst)
- [Commits](https://github.com/pallets/flask/compare/3.1.1...3.1.2)

Updates `typer-slim` from 0.16.0 to 0.16.1
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.16.0...0.16.1)

Updates `pylint` from 3.3.7 to 3.3.8
- [Release notes](https://github.com/pylint-dev/pylint/releases)
- [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.7...v3.3.8)

Updates `basedpyright` from 1.31.0 to 1.31.3
- [Release notes](https://github.com/detachhead/basedpyright/releases)
- [Commits](https://github.com/detachhead/basedpyright/compare/v1.31.0...v1.31.3)
2025-08-22 09:53:26 +02:00
github-actions[bot]
b1e461eb4b [l10n] update translations from Weblate (#5141)
a4922b114 - 2025-08-21 - KOUSTAV <koustav@noreply.codeberg.org>
3f61bddd1 - 2025-08-18 - reis2724 <reis2724@noreply.codeberg.org>
7313a683d - 2025-08-19 - Kemystra <kemystra@noreply.codeberg.org>
92e1bce48 - 2025-08-19 - Artiman <artiman@noreply.codeberg.org>
0f27c1bc2 - 2025-08-18 - youtherthyf <youtherthyf@noreply.codeberg.org>
60496bc76 - 2025-08-16 - alexgabi <alexgabi@noreply.codeberg.org>
742982d00 - 2025-08-15 - lucasmz.dev <lucasmz.dev@noreply.codeberg.org>
2025-08-22 09:51:03 +02:00
Markus Heiser
cfb6649b90 [build] /static 2025-08-21 14:04:13 +02:00
Amit Katyal
5ca70ca17e [feat] client/simple: move cursor to end of search input on mobile
On mobile devices, when the search input is focused, move the cursor
to the end of the existing text. This improves the user experience by
making it easier to edit or append to the current query without
manually moving the cursor first.

Closes: https://github.com/searxng/searxng/issues/5112
2025-08-21 14:04:13 +02:00
Markus Heiser
22c2c93274 [build] /static 2025-08-21 09:07:08 +02:00
Markus Heiser
d2b3c92e81 [fix] move initial "JS is enabled?" (no-js) to client side
To avoid an `unsafe-inline` in the CSP header, the JS code must be moved to the
client side [1].

The `<script>` tag at the end of the HTML originates from the old implementation
of the JS client. Since PR-5073 [2] was merged, the `type` is now `module`, and
the tag must be moved to the beginning of the HTML.

> We need to inline this "JS is enabled?" thing to prevent layout shifts and
> temporary "no JS enabled" visuals as ESM scripts loads and evals everything
> deferred from initial DOM render [3]

That's true in theory, but in practice, this effect is unnoticeable because it's
masked by another effect (which we can't avoid): If we load the page with a
severely throttled connection, the HTML (result list) takes a long time to
load. Then the CSS is loaded, which also takes longer. Until the CSS has loaded,
there's no layout. A layout shift is therefore largely determined by the loading
of the HTML and CSS itself.

The running times of the ESM script can be neglected compared to the loading
times of HTML & CSS.

[1] https://github.com/searxng/searxng-docker/pull/424#issuecomment-3199494256
[2] https://github.com/searxng/searxng/pull/5073
[3] https://github.com/searxng/searxng-docker/pull/424#issuecomment-3199622504
2025-08-21 09:07:08 +02:00
Ivan Gabaldon
41a4a3e224 [fix] template: safesearch uses the wrong type (#5136)
This fixes a regression from
60bd8b9#diff-1b714182564ef1fa942ff81b28f9ba3365ab76f75346f4255398bf9d6064b4cc

Closes https://github.com/searxng/searxng/issues/5135
2025-08-20 18:04:13 +02:00
Bnyro
3649917ce6 [fix] webapp: safesearch uses wrong default value (#5134)
- this fixes a regression from 60bd8b90f0 (diff-1b714182564ef1fa942ff81b28f9ba3365ab76f75346f4255398bf9d6064b4cc)
- closes https://github.com/searxng/searxng/issues/5130
2025-08-20 14:39:05 +02:00
Bnyro
0369682690 [fix] selfhst icons: icon list url invalid, set to active
- the previous CDN icon list url no longer works
- a list of all icons is mirrored to the JSDelivr CDN however
- there's no reason to set the engine to inactive now that we use public CDNs
2025-08-20 14:27:17 +02:00
Filip Mikina
6b57705e50 [feat] engines: add GitHub Code Search engine (#5074)
This patch adds GitHub Code Search [1] engine to allow querying the codebases.

Template code.html is changed to allow passthrough of strip and highlighting
options.

Engine Searchcode is adjusted to pass filename and not rely on hardcoded
extensions.

GitHub search code API does not return the exact code line indices, this
implementation assigns the code arbitrary numbers starting from 1
(effectively relabeling the code).

The API allows for unauth calls, and the default engine settings default to
that, although the calls are heavily rate limited.

The 'text' lexer is the default pygments lexer when parsing fails.

[1] https://docs.github.com/en/rest/search/search?apiVersion=2022-11-28#search-code

Co-authored-by: Markus Heiser <markus.heiser@darmarIT.de>
2025-08-20 07:35:31 +02:00
Markus Heiser
25647c20d1 [mod] switching from pyright to basedpyright (plus first rules)
pyrightconfig.json :

  for the paths searx, searxng_extra and tests, individual rules were
  defined (for example, in test fewer / different rules are needed than in the
  searx package

searx/engines/__builtins__.pyi :

  The builtin types that are added to the global namespace of a module by the
  intended monkey patching of the engine modules / replaces the previous
  filtering of the stdout using grep.

test.pyright_modified (utils/lib_sxng_test.sh) :

  static type check of local modified files not yet commited

make test :

  prerequisite 'test.pyright' has been replaced by 'test.pyright_modified'

searx/engines/__init__.py, searx/enginelib/__init__.py :

  First, minimal typifications that were considered necessary.
2025-08-19 12:04:35 +02:00
dependabot[bot]
9bb04e288d [upd] web-client (simple): Bump the minor group across 1 directory with 6 updates (#5128)
* [upd] web-client (simple): Bump the minor group across 1 directory with 6 updates

Bumps the minor group with 6 updates in the /client/simple directory:

| Package | From | To |
| --- | --- | --- |
| [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) | `2.1.3` | `2.2.0` |
| [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) | `24.2.0` | `24.3.0` |
| [browserslist](https://github.com/browserslist/browserslist) | `4.25.1` | `4.25.2` |
| [edge.js](https://github.com/edge-js/edge) | `6.2.1` | `6.3.0` |
| [stylelint](https://github.com/stylelint/stylelint) | `16.23.0` | `16.23.1` |
| [vite-bundle-analyzer](https://github.com/nonzzz/vite-bundle-analyzer) | `1.1.0` | `1.2.1` |



Updates `@biomejs/biome` from 2.1.3 to 2.2.0
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md)
- [Commits](https://github.com/biomejs/biome/commits/@biomejs/biome@2.2.0/packages/@biomejs/biome)

Updates `@types/node` from 24.2.0 to 24.3.0
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

Updates `browserslist` from 4.25.1 to 4.25.2
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.25.1...4.25.2)

Updates `edge.js` from 6.2.1 to 6.3.0
- [Release notes](https://github.com/edge-js/edge/releases)
- [Changelog](https://github.com/edge-js/edge/blob/6.x/CHANGELOG.md)
- [Commits](https://github.com/edge-js/edge/compare/v6.2.1...v6.3.0)

Updates `stylelint` from 16.23.0 to 16.23.1
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/16.23.0...16.23.1)

Updates `vite-bundle-analyzer` from 1.1.0 to 1.2.1
- [Release notes](https://github.com/nonzzz/vite-bundle-analyzer/releases)
- [Changelog](https://github.com/nonzzz/vite-bundle-analyzer/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nonzzz/vite-bundle-analyzer/compare/v1.1.0...v1.2.1)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 2.2.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: "@types/node"
  dependency-version: 24.3.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: browserslist
  dependency-version: 4.25.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: edge.js
  dependency-version: 6.3.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: stylelint
  dependency-version: 16.23.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: vite-bundle-analyzer
  dependency-version: 1.2.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* [fix] themes/simple: recreate lock

* [fix] themes/simple: promote from nursery

- noAwaitInLoop
- noBitwiseOperators
- noConstantBinaryExpression
- noGlobalDirnameFilename
- noImplicitCoercion
- noUnassignedVariables
- noUselessBackrefInRegex
- noUselessEscapeInString
- useAdjacentGetterSetter
- useConsistentObjectDefinition
- useConsistentResponse
- useIndexOf
- useIterableCallbackReturn
- useJsonImportAttribute
- useNumericSeparators
- useObjectSpread
- useParseIntRadix
- useReadonlyClassProperties
- useSingleJsDocAsterisk
- useUnifiedTypeSignature

* [fix] themes/simple: build static

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-08-18 23:17:50 +02:00
Ivan Gabaldon
5f364ad999 [fix] container: change mirror (#5127)
`mirrors.edge.kernel.org` has weird issues, use the official mirror and avoid
future issues.
2025-08-18 21:33:27 +02:00
dependabot[bot]
547d9dcee7 [upd] pypi: Bump the minor group across 1 directory with 2 updates (#5126)
Bumps the minor group with 2 updates in the / directory: [valkey](https://github.com/valkey-io/valkey-py) and [selenium](https://github.com/SeleniumHQ/Selenium).


Updates `valkey` from 6.1.0 to 6.1.1
- [Release notes](https://github.com/valkey-io/valkey-py/releases)
- [Commits](https://github.com/valkey-io/valkey-py/compare/v6.1.0...v6.1.1)

Updates `selenium` from 4.34.2 to 4.35.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/commits/selenium-4.35.0)

---
updated-dependencies:
- dependency-name: valkey
  dependency-version: 6.1.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: selenium
  dependency-version: 4.35.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-18 20:00:37 +02:00
github-actions[bot]
4304150d7f [l10n] update translations from Weblate (#5117)
b0a695592 - 2025-08-14 - zymurge <zymurge@noreply.codeberg.org>
17c30fdae - 2025-08-14 - c2qd <c2qd@noreply.codeberg.org>
a1dc25ec1 - 2025-08-12 - Kemystra <kemystra@noreply.codeberg.org>
a6c4a30e3 - 2025-08-12 - ijxp <ijxp@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-08-18 19:42:38 +02:00
Markus Heiser
9b4ea64429 [build] /static 2025-08-18 16:38:32 +02:00
Markus Heiser
4e586a7eca [fix] add missing nvm environment to the "./manage dev.env" command 2025-08-18 16:38:32 +02:00
Markus Heiser
48cec1fff6 [fix] drop obsolte client/simple/static/ 2025-08-18 16:38:32 +02:00
Markus Heiser
34e993a854 [license] client/simple: SPDX-License-Identifier: AGPL-3.0-or-later
SPDX short-form identifiers to communicate license information in a simple,
efficient, portable and machine-readable manner [1]

[1] https://spdx.dev/learn/handling-license-info/
2025-08-18 16:38:32 +02:00
Ivan Gabaldon
60bd8b90f0 [enh] theme/simple: custom router
Lay the foundation for loading scripts granularly depending on the endpoint it's
on.

Remove vendor specific prefixes as there are now managed by browserslist and
LightningCSS.

Enabled quite a few rules in Biome that don't come in recommended to better
catch issues and improve consistency.

Related:

- https://github.com/searxng/searxng/pull/5073#discussion_r2256037965
- https://github.com/searxng/searxng/pull/5073#discussion_r2256057100
2025-08-18 16:38:32 +02:00
Ivan Gabaldon
adc4361eb9 [fix] theme/simple: broken highlightResult
From `mod-simple-strict`
2025-08-18 16:38:32 +02:00
Ivan Gabaldon
7e1c7096ce [enh] theme/simple: package.json revision
Set minor versioning for most of the packages that iterate fast or we know won't
cause problems, and fixed versioning for the rest.

Packages going into bundles should be placed in "dependencies".

The inspection of prod bundles is necessary. Although it does not make a lot of
sense right now, it will be useful in later PR and will give us a reference to
start with.
2025-08-18 16:38:32 +02:00
Ivan Gabaldon
0b913053a7 [mod] theme/simple: migrate codebase to TypeScript
TypeScript is a superset of JavaScript, converting the entire theme to
TypeScript allows us to receive much more feedback on possible issues made in
package updates or our own typos, furthermore, it allows to transpile properly
to lower specs. This PR couldn't be done in smaller commits, a lot of work
needed to make everything *work properly*:

- A browser baseline has been set that requires minimum **Chromium 93, Firefox
  92 and Safari 15** (proper visuals/operation on older browser versions is not
  guaranteed)
- LightningCSS now handles minification and prefix creation for CSS.
- All hardcoded polyfills and support for previous browser baseline versions
  have been removed.
- Convert codebase to TypeScript.
- Convert IIFE to ESM, handling globals with IIFE is cumbersome, ESM is the
  standard for virtually any use of JS nowadays.
- Vite now builds the theme without the need for `vite-plugin-static-copy`.
- `searxng.ready` now accepts an array of conditions for the callback to be
  executed.
- Replace `leaflet` with `ol` as there were some issues with proper Vite
  bundling.
- Merged `head` with `main` script, as head was too small now.
- Add `assertElement` to properly check the existence of critical DOM elements.
- `searxng.on` renamed to `searxng.listen` with some handling improvements.
2025-08-18 16:38:32 +02:00
Markus Heiser
4fb6105d69 [fix] revision of utils.HTMLTextExtractor (#5125)
Related:

- https://github.com/searxng/searxng/pull/5073#issuecomment-3196282632
2025-08-18 16:30:51 +02:00
Ishbir Singh
b606103352 [fix] reuters: published date not parsed correctly in some cases
FIxes publishedDate format in reuters engine to encompass ISO 8601 times both with and without milliseconds.
Why is this change important?

Previously, the engine would sometimes fail saying:

2025-08-12 21:13:23,091 ERROR:searx.engines.reuters: exception : time data '2024-04-15T19:08:30.833Z' does not match format '%Y-%m-%dT%H:%M:%SZ'

Traceback (most recent call last):

...
  File "/usr/local/searxng/searx/engines/reuters.py", line 87, in response

    publishedDate=datetime.strptime(result["display_time"], "%Y-%m-%dT%H:%M:%SZ"),

                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...

Note that most queries seem to work with Reuters, but there are some results that have the additional milliseconds and fail. Regardless, the change is backwards compatible as both the formats (with and without the ms) should now parse correctly.
2025-08-16 15:50:38 +00:00
dependabot[bot]
792ec2afea [upd] github-actions: Bump actions/checkout from 4.2.2 to 5.0.0 (#5118)
Bumps [actions/checkout](https://github.com/actions/checkout) from 4.2.2 to 5.0.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](11bd71901b...08c6903cd8)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-15 18:06:22 +02:00
dependabot[bot]
90f997c181 [upd] github-actions: Bump github/codeql-action from 3.29.6 to 3.29.9 (#5119)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.29.6 to 3.29.9.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](a4e1a019f5...df559355d5)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.29.9
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-15 18:05:43 +02:00
Zhijie He
6b1516d6ad [fix] baidu captcha detection (#5111)
Add Baidu Captcha detection to reduce `JSONDecodeError` error

Baidu will redirect to `wappass.baidu.com` and return a captcha challenge.
Current behavior will get the data from `wappass.baidu.com` then return a
`json.decoder.JSONDecodeError` error.
2025-08-12 15:18:46 +02:00
Markus Heiser
6cccb46f2b [fix] replace X-Scheme by X-Forwarded-Proto header (#5107)
The HTTP X-Forwarded-Proto (XFP) request header is a *de-facto* standard header
for identifying the protocol (HTTP or HTTPS) that a client used to connect to a
proxy or load balancer.[1]

The ``X-Scheme`` header was added 10 years ago, why ``X-Scheme`` was used back
then and not ``X-Forwarded-Proto``, nobody knows today / possibly because
``X-Forwarded-Proto`` wasn't a *de-facto* standard back then.

[1] https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/X-Forwarded-Proto
[2] https://github.com/searx/searx/commit/6ef7c3276
2025-08-10 13:05:40 +02:00
Markus Heiser
a0dd416e8a [fix] use X-Forwarded-Proto header if the URL scheme is unknown (#5106)
The HTTP X-Forwarded-Proto (XFP) request header is a de-facto standard header
for identifying the protocol (HTTP or HTTPS) that a client used to connect to a
proxy or load balancer.[1]

In our documentation[2] we recommend to set the `X-Scheme` header. This header
is not required if the `server.base_url` is set correctly.[3]

If none of these URL scheme details exist, then the header X-Forwarded-Proto is
evaluated as a third alternative.

[1] https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/X-Forwarded-Proto
[2] https://docs.searxng.org/admin/installation-apache.html#apache-s-searxng-site
[3] https://docs.searxng.org/admin/settings/settings_server.html

Closes: https://github.com/searxng/searxng/issues/5105
2025-08-10 11:08:57 +02:00
Markus Heiser
935f3fe332 [fix] limiter: trusted proxies doc-string (#5104) 2025-08-09 23:30:48 +02:00
Ivan Gabaldon
ce8929cabe [mod] limiter: trusted proxies (#4911)
Replaces `x_for` functionality with `trusted_proxies`. This allows defining
which IP / ranges to trust extracting the client IP address from X-Forwarded-For
and X-Real-IP headers.

We don't know if the proxy chain will give us the proper client
address (REMOTE_ADDR in the WSGI environment), so we rely on reading the headers
of the proxy before SearXNG (if there is one, in that case it must be added to
trusted_proxies) hoping it has done the proper checks. In case a proxy in the
chain does not check the client address correctly, integrity is compromised and
this should be fixed by whoever manages the proxy, not us.

Closes:

- https://github.com/searxng/searxng/issues/4940
- https://github.com/searxng/searxng/issues/4939
- https://github.com/searxng/searxng/issues/4907
- https://github.com/searxng/searxng/issues/3632
- https://github.com/searxng/searxng/issues/3191
- https://github.com/searxng/searxng/issues/1237

Related:

- https://github.com/searxng/searxng-docker/issues/386
- https://github.com/inetol-infrastructure/searxng-container/issues/81
2025-08-09 23:03:30 +02:00
Markus Heiser
341d718c7f [fix] duckduckgo weather: add type hints and fix WEATHERKIT_TO_CONDITION (#5101) 2025-08-09 12:24:19 +02:00
Markus Heiser
6172beba1a [doc] Development Quickstart: debug with the Python Debugger pdb (#5100)
Related:

- https://github.com/searxng/searxng/pull/5037#issuecomment-3166851578
2025-08-09 12:16:19 +02:00
Austin-Olacsi
cf5061dc70 [feat] engines: add Marginalia (#5087)
To get an API key follow instructions at [1].

[1] https://about.marginalia-search.com/article/api/

Related (historical ordered):
- https://github.com/searxng/searxng/issues/1620
- https://github.com/searxng/searxng/issues/1673
- https://github.com/searxng/searxng/pull/1627
- https://github.com/searxng/searxng/pull/2489

Closes:
- https://github.com/searxng/searxng/issues/3034

Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-08-09 08:38:11 +02:00
github-actions[bot]
5e7109cd26 [l10n] update translations from Weblate (#5096)
0fbf5aa2d - 2025-08-07 - alexgabi <alexgabi@noreply.codeberg.org>
d18d3ed1c - 2025-08-07 - return42 <return42@noreply.codeberg.org>
7927a63a0 - 2025-08-06 - pikzim <pikzim@noreply.codeberg.org>
27c8b4013 - 2025-08-05 - nhthinh <nhthinh@noreply.codeberg.org>
83262e748 - 2025-08-04 - IcewindX <icewindx@noreply.codeberg.org>
2025-08-08 17:19:22 +02:00
Bnyro
761b74e8c9 [fix] legacy results: published date missing (#5093)
The `publishedDate` has always been `None` before that change, which
causes that there are no `publishedDate`s visible for any result.
2025-08-08 12:22:00 +02:00
Ivan Gabaldon
dd170964c7 [mod] ci: strict(er) exec (#5099)
All actions are pulled using the version hash, versions are handled by
dependabot, and we'll have control over which actions get updated.

Replaces Trivy scanner with Docker Scout, we have recently begun analyzing the
images there, and the action will keep us in sync about the problems on GHCS
dashboard.
2025-08-08 11:26:45 +02:00
Ivan Gabaldon
1f619248b6 [mod] ci: docker task unused (#5098)
We always use the latest versions of our base images, so this dependabot task
is unneeded.
2025-08-08 10:07:14 +02:00
dependabot[bot]
77f10f09f9 [upd] pypi: Bump certifi from 2025.7.14 to 2025.8.3 in the minor group (#5097)
Bumps the minor group with 1 update: [certifi](https://github.com/certifi/python-certifi).


Updates `certifi` from 2025.7.14 to 2025.8.3
- [Commits](https://github.com/certifi/python-certifi/compare/2025.07.14...2025.08.03)

---
updated-dependencies:
- dependency-name: certifi
  dependency-version: 2025.8.3
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-08 09:36:24 +02:00
Bnyro
25c327904a [fix] tagesschau: crash if there's no video stream available
Sometimes, there's only an `adaptivestreaming` field in `streams`, which
is usually an m3u8 file. That's however not supported by the video player
of any browser, so we can't use and must build a different url instead.
2025-08-08 07:19:12 +00:00
Bnyro
612b76b75e [fix] webapp.py: default_http_headers not parsed as strings (#5094)
WhiteNoise requires all headers to be strings, however it's common to use
other primitive types (e.g. numbers) in the header, e.g. `X-XSS-Protection: 0`.
Thus, we must convert all types of values (i.e. numbers) to strings.

- closes https://github.com/searxng/searxng/issues/5091
2025-08-07 20:50:31 +02:00
Ivan Gabaldon
4942c9b914 [fix] ci: cache is not overwritten (#5089)
Due to current limitations of `actions/cache`, the cache cannot be overwritten.
In our case, we need to accumulate cached wheels from different architectures.
To solve this, we simply delete the key before storing the cache again.
2025-08-07 16:53:37 +02:00
Ivan Gabaldon
3de7a6da2d [enh] container: tidy builds (#5086)
Building the container currently does not work properly.
When rebuilding several times with `make container`, `version_frozen.py`
is recreated, which wouldn't be an issue if the file’s timestamp was constant.
Now, when creating `version_frozen.py`, it will have the same timestamp as the
commit when it was created. (`version_frozen.py` is moved to a dedicated layer).

Reusing "builder" cache when building "dist" could be slow
(CD reports 2 seconds, but locally I've seen it take up to 10 seconds),
so the Dockerfile is now split and we save a couple steps
by importing the "builder" image directly.

The last changes made it possible to remove the layer cache in "builder",
since the overhead is now greater than building the layers from scratch.

Until now, all "dist" layers were squashed into a single layer,
which in most cases is a good idea
(except for storage/delivery pricing/overhead), but in our case,
since we manage the entire pipeline, we can ignore this
and share layers between builds.
This means (for example) that if we change files unrelated to the container
in several consecutive commits (documentation changes), we don't have to push
the entire image to registry, but only the different layers
(`version_frozen.py` in this example).
The same applies when pulling, as only the layers that have changed
compared to the local layers will be downloaded (that's the theory,
we'll see if this works as expected or if we need to tweak something else).
2025-08-07 10:46:26 +02:00
Bnyro
94256e3383 [feat] duckduckgo weather: migrate to new weather engine template
- not 100% sure about the condition code mapping, there are no real matches for most of the codes from Apple WeatherKit to the weather codes we have in SearXNG
- related: https://github.com/searxng/searxng/issues/4885
2025-08-06 14:09:23 +02:00
Markus Heiser
2e62eb5d68 [fix] engine yummly: website were taken offline in December 2024 (#5080)
The app and website were taken offline in December 2024, with the latter
pointing to KitchenAid's US website. [1]

[1] https://en.wikipedia.org/wiki/Yummly

Closes: https://github.com/searxng/searxng/issues/5079
2025-08-03 10:49:14 +02:00
Ivan Gabaldon
3d96414482 [enh] container: latest tag should be last (#5078)
With this change, the "latest" tag will be visually higher (on registry tag list). Right now, it appears under the "DOCKER_TAG" manifest tag, which can be confusing.
2025-08-01 14:51:28 +02:00
Markus Heiser
664aab0ec9 [fix] CI task "update_engine_traits.py" fails (#5069)
* [fix] CI task "update_engine_traits.py" fails

To catch all problems with an HTTP request, the more general class
``httpx.HTTPError`` must be caught, for your test use::

    $ ./manage dev.env
    $ python ./searxng_extra/update/update_engine_traits.py

Closes: https://github.com/searxng/searxng/issues/5068

* [data] update searx.data - update_engine_traits.py
2025-08-01 12:08:27 +02:00
dependabot[bot]
dcb1e20007 [upd] pypi: Bump the minor group with 2 updates (#5077)
* [upd] pypi: Bump the minor group with 2 updates

Bumps the minor group with 2 updates: [granian[reload]](https://github.com/emmett-framework/granian) and [granian](https://github.com/emmett-framework/granian).


Updates `granian[reload]` from 2.4.2 to 2.5.0
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.4.2...v2.5.0)

Updates `granian` from 2.4.2 to 2.5.0
- [Release notes](https://github.com/emmett-framework/granian/releases)
- [Commits](https://github.com/emmett-framework/granian/compare/v2.4.2...v2.5.0)

---
updated-dependencies:
- dependency-name: granian[reload]
  dependency-version: 2.5.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: granian
  dependency-version: 2.5.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* [enh] py: use humanized duration

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-08-01 10:55:45 +02:00
github-actions[bot]
c2d4e3c49a [l10n] update translations from Weblate (#5076)
17e9fcd68 - 2025-07-29 - musabustun <musabustun@noreply.codeberg.org>
90b302e3e - 2025-07-29 - return42 <return42@noreply.codeberg.org>
023a22292 - 2025-07-29 - return42 <return42@noreply.codeberg.org>
17d37ede6 - 2025-07-30 - gkalathas <gkalathas@noreply.codeberg.org>
3c64c165f - 2025-07-29 - return42 <return42@noreply.codeberg.org>
d8f65cdc7 - 2025-07-26 - IcewindX <icewindx@noreply.codeberg.org>
2025-08-01 10:02:49 +02:00
benpiano800
46f41d2138 [feat] statistics answerer: add the ability to calculate the range of a set 2025-07-31 20:13:24 +02:00
Markus Heiser
6b9e12e4c1 [test] calculator plugin: report the DeprecationWarning once (#5070)
Reporting the DeprecationWarning once should be sufficient when running tests.
2025-07-29 16:31:28 +02:00
github-actions[bot]
40b78ad06c [data] update searx.data - update_wikidata_units.py (#5062) 2025-07-29 07:26:01 +02:00
github-actions[bot]
db83a39544 [data] update searx.data - update_external_bangs.py (#5061) 2025-07-29 07:25:26 +02:00
github-actions[bot]
bb3bea829d [data] update searx.data - update_ahmia_blacklist.py (#5064) 2025-07-29 07:24:09 +02:00
github-actions[bot]
dc9ad0a493 [data] update searx.data - update_currencies.py (#5065) 2025-07-29 07:23:38 +02:00
github-actions[bot]
5db7b70dc7 [data] update searx.data - update_engine_descriptions.py (#5066) 2025-07-29 07:22:58 +02:00
github-actions[bot]
2ad35421d7 [data] update searx.data - update_firefox_version.py (#5063)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-07-29 07:22:21 +02:00
Markus Heiser
f32e91e51a [fix] duckduckgo engine: logger.error / missing argument (#5057)
The error message in case the vqd value could not be determined was incorrect
and triggered an exception::

     File "/usr/local/searxng/searxng-src/searx/engines/duckduckgo.py", line 132, in get_vqd
       logger.error("vqd value from duckduckgo.com ", resp.status_code)
     Message: 'vqd value from duckduckgo.com '
     Arguments: (202,)
2025-07-28 15:36:52 +02:00
Markus Heiser
17f2027c4f [fix] NotImplementedError raised by ResultContainer (#5058)
If the ``on_result`` handle returns False, then the ``else`` was always jumped
to, which throws the NotImplementedError exception::

    File "/usr/local/searxng/searxng-src/searx/results.py", line 99, in extend
      raise NotImplementedError(f"no handler implemented to process the result of type {result}")
    NotImplementedError: no handler implemented to process the result of type MainResult(title=...
2025-07-28 15:36:26 +02:00
Markus Heiser
8084a86784 [upd] update to gecko driver v36
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-28 12:53:26 +02:00
Markus Heiser
8c2c3430da [fix] apply shell formating / shfmt (make format.shell)
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-28 12:53:26 +02:00
Markus Heiser
cd062d7349 [fix] don't install pyright twice and do some clean up
Pyright has been installed twice so far, once via `package.json` and once in the
test script via `npx --no-install`. Separating the type checks in the CI and on
the developer desktop is also not necessary.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-28 12:53:26 +02:00
Markus Heiser
67e423edb2 [enh] CI - add shell script formatter
Implement rules and functions to format shell scripts:

    $ make format.shell

or alternatively to format all source code:

    $ make format

The formatter `shfmt` reads the rules from the editorconfig[1]

  If any EditorConfig files are found, they will be used to apply formatting
  options.  If any parser or printer flags are given to the tool, no
  EditorConfig files will be used.

[1] https://github.com/patrickvane/shfmt?tab=readme-ov-file#description

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-28 12:53:26 +02:00
Markus Heiser
7ee3dc9d74 [mod] dependabot: add searxng.org/devtools from Go and Node.js
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-28 12:53:26 +02:00
Markus Heiser
cf2cc87594 [mod] create a Go project with the developer tools from Go
The `go.mod` was created by::

   $ ./manage dev.env
   (dev.env)$ go mod init searxng.org/devtools
   (dev.env)$ go get -tool mvdan.cc/sh/v3/cmd/shfmt@v3.12.0

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-28 12:53:26 +02:00
Markus Heiser
20a193f04c [mod] add Golang ecosystem to the SearXNG toolchain
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-28 12:53:26 +02:00
Markus Heiser
ae0fcf3a42 [chore] overdue maintenance of shell scripts
Removes obsolete scripts and fix various leftovers.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-28 12:53:26 +02:00
mggh0139
54a2b553f4 [fix] tracker pattern: let startup continue if url fetch fails (#5055)
Use Python exception to prevent startup crash in case of fetch ClearURL
failure. Also add some logs.

Closes: https://github.com/searxng/searxng/issues/5054
2025-07-28 07:03:01 +02:00
Fjara
f04c273732 [fix] correct comment in settings.yml for value to disable scheduling (#5052)
settings.yml correct value to disable scheduling
2025-07-27 17:36:39 +02:00
Bnyro
1baf3dcd1c [fix] webapp.py: info (and other) page(s) don't load properly (#5051) 2025-07-26 17:58:53 +02:00
Markus Heiser
649a8dd577 [fix] cleanup: rename searx leftovers to SearXNG (#5049)
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-26 06:22:46 +02:00
SeriousConcept1134
02cbdf468b [fix] google video: refactor broken engine to work again
The current google_videos.py in the master branch is completely non functional, due to it not parsing the returned video search results correctly. The result is searxng saying that no results were found. This commit is a new updated google_videos.py that's designed to fix that and is confirmed to be working.

Implementing the suggestions by Bnyro.

Re-formatted with `black` for compatibility. After failing automated checks, ran the command:
black --line-length 120 --skip-string-normalization --target-version py311 google_videos.py
2025-07-25 21:40:53 +02:00
Markus Heiser
168fa9b09b [mod] make run: start granian server and versioning by Dependabot (#5037)
The new ``requirements-server.txt`` (granian) is installed into the virtualenv
of Dockerfile.

When ``make run`` is called, a granian server is started with auto reload on
application's files changes / requires granian[reload] extra, see
``requirements-dev.txt``.

Dependabot supports updates to any ``.txt`` file [1].

[1] https://docs.github.com/en/code-security/dependabot/ecosystems-supported-by-dependabot/supported-ecosystems-and-repositories#pip-and-pip-compile

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-25 17:40:33 +02:00
github-actions[bot]
83adda8567 [l10n] update translations from Weblate (#5047)
19de4a735 - 2025-07-23 - eudemo <eudemo@noreply.codeberg.org>
4504f8600 - 2025-07-22 - IcewindX <icewindx@noreply.codeberg.org>
2b4ec6d2c - 2025-07-22 - lucasmz.dev <lucasmz.dev@noreply.codeberg.org>
69b3590de - 2025-07-22 - Fjuro <fjuro@alius.cz>
f48c7b9ac - 2025-07-21 - alexgabi <alexgabi@noreply.codeberg.org>
f8bc97254 - 2025-07-21 - alexgabi <alexgabi@noreply.codeberg.org>
7bd4b6441 - 2025-07-21 - Juno Takano <jutty@noreply.codeberg.org>
527bc690c - 2025-07-20 - 0ko <0ko@noreply.codeberg.org>
dd242f579 - 2025-07-20 - IcewindX <icewindx@noreply.codeberg.org>
f2a3cdb26 - 2025-07-19 - ledjfou <ledjfou@noreply.codeberg.org>
6781d5611 - 2025-07-20 - alexgabi <alexgabi@noreply.codeberg.org>
df82ea943 - 2025-07-18 - zbbhzdaajc <zbbhzdaajc@noreply.codeberg.org>
7892aac02 - 2025-07-18 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
2025-07-25 12:20:58 +02:00
Markus Heiser
84c3a832a4 [fix] false is an invalid value for wiki_url in settings.yml (#5046)
Closes: https://github.com/searxng/searxng/issues/5045
2025-07-24 17:47:09 +02:00
Ivan Gabaldon
802bf4f9e7 [fix] py: absolute static path (#5043)
The path to static should be relative (If sxng is served under "/sxng", the static route passed to the client won't be "/sxng/static/..." as expected but "/static/...")

Closes https://github.com/searxng/searxng/issues/5042
2025-07-24 14:55:04 +02:00
Bnyro
6b16a04e7e [mod] wordnik: convert to answerer (#4980)
Wordnik is now an answerer and not in the infobox anymore: it uses the
translations answerer, because it provides all the features needed. By default,
only its first results is shown

Additionally a new "define" category is added - I know, it's the same as the
"dictionaries" category, but I don't think we can alias categories.  This allows
to search e.g. for `!define tree`, the idea is to allow easy searches for
definitions of words.

Related:

- https://github.com/searxng/searxng/issues/4111
2025-07-24 07:42:31 +02:00
Ivan Gabaldon
b01d32d69d [fix] py: restore application for uWSGI (#5040)
Was removed on https://github.com/searxng/searxng/pull/5032
2025-07-23 23:55:50 +02:00
Ivan Gabaldon
f7c8e4c353 [fix] py: overwrite version_frozen on explicit freeze (#5020)
Once version_frozen.py has been created, it will never be updated again unless the file is manually deleted.
2025-07-23 18:17:58 +02:00
Ivan Gabaldon
42f102ce1b [enh] py: whitenoise for static handling (#5032)
While looking at ways to better handle static files, I saw a package that replaces Flask `static_folder` functionality. Not only it's considerably faster, but already includes the capability to serve sidecars without having to intercept. This also replaces the uWSGI folder mapping functionality.

Closes https://github.com/searxng/searxng/issues/4977
2025-07-23 18:16:10 +02:00
Bnyro
5cbf422621 [fix] tracker url remover + external bangs: use standard network config
Using plain `httpx` directly doesn't use SearXNG's additional network config, including proxies, http2 config, ...

Related issues:
- https://github.com/searxng/searxng/issues/5027
2025-07-22 10:25:33 +02:00
Ivan Gabaldon
b95a3e905d [fix] container: remove static path mount (#5006)
I've seen that by default Granian sets a `Cache-Control` header for 1 day IF `GRANIAN_STATIC_PATH_MOUNT` is set. This option is not a hard requirement, but it's set because I found to be faster when serving the static files.

Another thing is that by removing `GRANIAN_STATIC_PATH_MOUNT`, the headers set by the application are present again in the static files, which was not the case before.

Related https://github.com/searxng/searxng/pull/5004
2025-07-19 10:18:50 +02:00
github-actions[bot]
be392a45fc [l10n] update translations from Weblate (#5023)
fce853a65 - 2025-07-16 - return42 <return42@noreply.codeberg.org>
234a91155 - 2025-07-16 - return42 <return42@noreply.codeberg.org>
162ff0369 - 2025-07-16 - return42 <return42@noreply.codeberg.org>
3307e81ab - 2025-07-16 - return42 <return42@noreply.codeberg.org>
7948181fb - 2025-07-15 - Juno Takano <jutty@noreply.codeberg.org>
e88a0b264 - 2025-07-15 - muha7a <muha7a@noreply.codeberg.org>
7b37b944e - 2025-07-14 - Cookie_Monster <cookie_monster@noreply.codeberg.org>
d6c61f1ff - 2025-07-14 - kolegacik <kolegacik@noreply.codeberg.org>
5bd662542 - 2025-07-15 - lucasmz.dev <lucasmz.dev@noreply.codeberg.org>
4ddad097c - 2025-07-14 - yoonhahwang <yoonhahwang@noreply.codeberg.org>
a8d319c18 - 2025-07-13 - norizou <norizou@noreply.codeberg.org>
e7e471f65 - 2025-07-13 - Hēphaistos <hephaistos@noreply.codeberg.org>
b6b198f0a - 2025-07-12 - return42 <return42@noreply.codeberg.org>
9da60d355 - 2025-07-11 - sourdragon <sourdragon@noreply.codeberg.org>
632b879ba - 2025-07-12 - return42 <return42@noreply.codeberg.org>
a543b2b87 - 2025-07-12 - return42 <return42@noreply.codeberg.org>
7e418d9cc - 2025-07-12 - return42 <return42@noreply.codeberg.org>
6e78fbd5c - 2025-07-12 - return42 <return42@noreply.codeberg.org>
917b27bad - 2025-07-12 - return42 <return42@noreply.codeberg.org>
82e69afbf - 2025-07-12 - return42 <return42@noreply.codeberg.org>
096c36ef7 - 2025-07-12 - return42 <return42@noreply.codeberg.org>
2048ef8e2 - 2025-07-12 - return42 <return42@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-07-19 07:14:26 +02:00
Ivan Gabaldon
ff2e0ea278 [mod] py: don't append "-dirty" to DOCKER_TAG (#5021)
We don't expect tags to have "-dirty", just the GIT_VERSION regardless of how the container is built.
2025-07-18 10:42:44 +02:00
dependabot[bot]
22c6cd4121 [upd] pypi: Bump certifi from 2025.7.9 to 2025.7.14 in the minor group (#5022)
Bumps the minor group with 1 update: [certifi](https://github.com/certifi/python-certifi).


Updates `certifi` from 2025.7.9 to 2025.7.14
- [Commits](https://github.com/certifi/python-certifi/compare/2025.07.09...2025.07.14)

---
updated-dependencies:
- dependency-name: certifi
  dependency-version: 2025.7.14
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-18 10:41:18 +02:00
Markus Heiser
e851bc1269 [fix] calculator plugin: filtering real calculation tasks (#5016)
Whether the query is a real calculation tasks is currently only detected in the
AST, resulting in unnecessary creatins of subprocesses. This problem is
mitigated with this patch: if the query contains letters, it is obviously not a
math problem, and the plugin can return without further action.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-17 19:50:02 +02:00
Markus Heiser
62fac1c6a9 [fix] custom plugins: settings must not be merged.
In customizing it should be decided which plugin modules should be loaded and
which should not.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-16 20:55:39 +02:00
mrpaulblack
a0a2f0fd42 [build] /static 2025-07-16 11:02:12 +02:00
mrpaulblack
23d6f59771 [fix] simple theme: display image detail view fullscreen on landscape phones 2025-07-16 11:02:12 +02:00
Ivan Gabaldon
d574339853 [mod] container: remove Cache-Control header (#5005)
Granian shouldn't actually handle the cache, we leave that to the upstream proxy.

Related https://github.com/searxng/searxng/pull/5004
2025-07-11 17:34:07 +02:00
Markus Heiser
574b285efa [mod] remove option ui.static_use_hash (cache busting) (#5004)
Cache busting has caused serious problems for users in the past, here are two
examples:

- https://github.com/searxng/searxng/issues/4419
- https://github.com/searxng/searxng/issues/4481

And it makes development and deployment significantly more complex because it
binds the client side to the server side:

- https://github.com/searxng/searxng/pull/4466

In the light of a decoupled development of the WEB clients from the server side:

- https://github.com/searxng/searxng/pull/4988

is it appropriate to abandon this feature. In fact,  it has been ineffective
since #4436 anyway.

However, the benefit has always been questionable, since at best only a few kB
of data are saved (at least in the context of an image_proxy, the effect is below
the detection limit). Ultimately, the client is responsible for caching.

Related: https://github.com/searxng/searxng/issues?q=label%3A%22clear%20browser%20cache%22

Closes: https://github.com/searxng/searxng/pull/4466
Closes: https://github.com/searxng/searxng/issues/1326
Closes: https://github.com/searxng/searxng/issues/964

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-11 16:53:36 +02:00
Ivan Gabaldon
9149175ff2 [fix] devcontainers: missing Valkey package (#4997)
Use specific branch as `valkey-server` package is only available in trixie and bookworm backports.

Reported https://github.com/searxng/searxng/discussions/4995
Closes https://github.com/searxng/searxng/issues/4996
2025-07-11 16:51:58 +02:00
dependabot[bot]
d8c74c830b [upd] pypi: Bump the minor group with 2 updates (#5000)
Bumps the minor group with 2 updates: [selenium](https://github.com/SeleniumHQ/Selenium) and [certifi](https://github.com/certifi/python-certifi).


Updates `selenium` from 4.34.0 to 4.34.2
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/commits)

Updates `certifi` from 2025.6.15 to 2025.7.9
- [Commits](https://github.com/certifi/python-certifi/compare/2025.06.15...2025.07.09)

---
updated-dependencies:
- dependency-name: selenium
  dependency-version: 4.34.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: certifi
  dependency-version: 2025.7.9
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
2025-07-11 11:16:22 +02:00
github-actions[bot]
b5ae3a047d [l10n] update translations from Weblate (#4998)
6c74fe951 - 2025-07-08 - janindu-t <janindu-t@noreply.codeberg.org>
a17afd1fd - 2025-07-06 - ajiou <ajiou@noreply.codeberg.org>
6424a07ea - 2025-07-05 - aindriu80 <aindriu80@noreply.codeberg.org>
e62b0059e - 2025-07-05 - kratos <makesocialfoss32@keemail.me>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-07-11 11:15:07 +02:00
Bnyro
a48ec8a4d5 [chore] engines: remove redundant usages of utils#gen_useragent (#4993)
These engines override the user agent manually using `gen_useragent`, although that's already done in the online preprocessor that runs before the actual `request(query, params)` method is called. Hence, this call is duplicated.

Related:
- https://github.com/searxng/searxng/pull/4990#discussion_r2195142838
2025-07-11 08:42:39 +02:00
Bnyro
4b9644eb27 [fix] public domain image archive: cloud provider changed angolia -> aws
- apparently, PDIA switched from Angolia to AWS :/
- we no longer require an API key, but the AWS node might change, so we still have to extract the API url of the node
- the response format is still the same, so no changes needed in that regard

- closes #4989
2025-07-10 15:12:26 +02:00
Markus Heiser
2fe8540903 [fix] prevent multiple, parallel initializations of tables in the cache DB (#4991)
Depending on the respective runtime behavior, it could happen that the initial
loading of the DB tables in the cache was performed multiple times and in
parallel. The concurrent accesses then led to the `sqlite3.OperationalError:
database is locked` exception as in #4951.

Since this problem depends significantly on the runtimes (e.g., how long it
takes to retrieve the content for a table), this error could not be observed in
all installations.

Closes: https://github.com/searxng/searxng/issues/4951

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-09 17:32:10 +02:00
Gaspard d'Hautefeuille
f798ddd492 [mod] migrate from Redis to Valkey (#4795)
This patch migrates from `redis==5.2.1` [1] to `valkey==6.1.0` [2].

The migration to valkey is necessary because the company behind Redis has decided
to abandon the open source license. After experiencing a drop in user numbers,
they now want to run it under a dual license again. But this move demonstrates
once again how unreliable the company is and how it treats open source
developers.

To review first, read the docs::

    $ make docs.live

Follow the instructions to remove redis:

- http://0.0.0.0:8000/admin/settings/settings_redis.html

Config and install a local valkey DB:

- http://0.0.0.0:8000/admin/settings/settings_valkey.html

[1] https://pypi.org/project/redis/
[2] https://pypi.org/project/valkey/

Co-authored-by: HLFH <gaspard@dhautefeuille.eu>
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-09 07:55:37 +02:00
Markus Heiser
bd593d0bad [fix] granian: enabling debug on searxng-docker causes server crash (#4985)
When debugging is enabled, the context in which the process is running (uWSGI or
`Flask.run` server) was previously checked [1]. This check has not yet taken the
granian server into account.

----

The check is actually only required for the developer environment (`make run`)
[2] and is intended to prevent double loading of modules when initializing a
Flask server [3].

In the long term, we should find a more robust solution that explicitly enables
the specific features of a development environment via switches. Further
information on this problematic code can be found in [4][5][6].

[1] https://github.com/searxng/searxng/issues/4973#issuecomment-3047890957
[2] https://flask.palletsprojects.com/en/stable/api/#flask.Flask.run
[3] https://github.com/pallets/flask/issues/5307#issuecomment-1774646119
[4] https://github.com/searxng/searxng/pull/1656#issuecomment-1214198941
[5] https://github.com/searxng/searxng/pull/1616#issuecomment-1206137468
[6] https://stackoverflow.com/a/25504196

- closes: https://github.com/searxng/searxng/issues/4973

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-08 13:46:39 +02:00
Markus Heiser
fe52290e65 [fix] calculator plugin: subrocess is not closed on timeout (#4983)
The issue was introduced in commit: edfbf1e

Problematic code::

    def timeout_func(timeout, func, *args, **kwargs):
        ...
        if not p.is_alive():
            ret_val = que.get()
        else:
            logger.debug("terminate function after timeout is exceeded")  # type: ignore
            p.terminate()
        p.join()
        p.close()

The `logger` function in the `else` path is not defined.  Was accidentally
removed in commit edfbf1e without providing an appropriate replacement.::

    File "/usr/local/searxng/searx/plugins/calculator.py", line 216, in timeout_func
      logger.debug("terminate function after timeout is exceeded")  # type: ignore
      ^^^^^^
    NameError: name 'logger' is not defined

The exception triggered by this prevents the `p.terminate()` from being
executed. As a result, the processes accumulate in memory (memory leak).

Related: https://github.com/searxng/searx-instances/discussions/708#discussioncomment-13688168

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-08 09:30:41 +02:00
Bnyro
6ff4035635 [feat] engines: add pixabay for royalty free images/videos
What's changed?
- this PR adds Pixabay, a collection of royalty free images
- additionaly it seems to have some videos, so there's an engine for it too

Author Notes
- when using SearXNG's transport, all our requests will get blocked, probably due to fingerprinting
- we should find an alternative solution because this is just a hacky change to make things work for now, but idk how ...
2025-07-05 13:45:19 +02:00
Bnyro
5926d737e3 [fix] calculator plugin: crash when trying to evaluate non-math query (#4975)
It's possible that `SyntaxError` or `TypeError` instances are thrown
when we can't evaluate a query, simply because it's not a math expression.
In this case, it should just be skipped, i.e. the calculator plugin doesn't
return any result instead of forwarding the exception.
2025-07-04 21:32:54 +02:00
Ivan Gabaldon
01be2612ab [mod] container: replace uWSGI with Granian (#4820)
* [mod] container: replace uWSGI with Granian

The configuration in Granian is handled with ENVs, much more convenient and practical for updating. The settings have been tested for over two months in a production instance, being usable on small to somewhat large instances without having to modify anything.

It also removes the patch functions and ENVs abstraction from the entrypoint, this makes it possible to run the container with immutable configuration.

In some setups, It may be desired to have the volumes/files under a specific uid/gid (other than searxng:searxng), if the entrypoint has root permissions it will chown automatically on every start, which may not be desired. Explicitly setting the new ENV `FORCE_OWNERSHIP=false` will prevent ownership from being modified.

No manual migration is necessary **unless** the user has changed the default uWSGI configuration or has a very specific setup.

Closes https://github.com/searxng/searxng/issues/4894
Closes https://github.com/searxng/searxng/issues/4818
Closes https://github.com/searxng/searxng/issues/4802

Supersedes https://github.com/searxng/searxng/pull/4596

Related https://github.com/searxng/searxng/discussions/4479

* [mod] docs: add container/granian

All container documentation has been recreated.

A new documentation page has been created for Granian.

* [enh] misc: apply suggestions

Minor documentation changes.

Suggested https://github.com/searxng/searxng/pull/4820#discussion_r2134539259
Suggested https://github.com/searxng/searxng/pull/4820#discussion_r2134538610
Suggested https://github.com/searxng/searxng/pull/4820#discussion_r2134827964
Suggested https://github.com/searxng/searxng/pull/4820#discussion_r2134544300
Suggested https://github.com/searxng/searxng/pull/4820#discussion_r2149387388

---------

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-07-04 14:35:28 +02:00
dependabot[bot]
6ca8db5e67 [upd] web-client (simple): Bump the minor group across 1 directory with 4 updates (#4970)
Bumps the minor group with 4 updates in the /client/simple directory: [ionicons](https://github.com/ionic-team/ionicons), [sort-package-json](https://github.com/keithamus/sort-package-json), [stylelint](https://github.com/stylelint/stylelint) and [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `ionicons` from 8.0.9 to 8.0.10
- [Release notes](https://github.com/ionic-team/ionicons/releases)
- [Commits](https://github.com/ionic-team/ionicons/compare/v8.0.9...v8.0.10)

Updates `sort-package-json` from 3.3.1 to 3.4.0
- [Release notes](https://github.com/keithamus/sort-package-json/releases)
- [Commits](https://github.com/keithamus/sort-package-json/compare/v3.3.1...v3.4.0)

Updates `stylelint` from 16.21.0 to 16.21.1
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/16.21.0...16.21.1)

Updates `vite` from 7.0.1 to 7.0.2
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v7.0.2/packages/vite)

---
updated-dependencies:
- dependency-name: ionicons
  dependency-version: 8.0.10
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: sort-package-json
  dependency-version: 3.4.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: stylelint
  dependency-version: 16.21.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: vite
  dependency-version: 7.0.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-04 12:17:51 +02:00
dependabot[bot]
b44a360947 [upd] pypi: Bump selenium from 4.33.0 to 4.34.0 in the minor group (#4968)
Bumps the minor group with 1 update: [selenium](https://github.com/SeleniumHQ/Selenium).


Updates `selenium` from 4.33.0 to 4.34.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.33.0...selenium-4.34.0)

---
updated-dependencies:
- dependency-name: selenium
  dependency-version: 4.34.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-04 12:02:21 +02:00
dependabot[bot]
db8d4d3877 [upd] web-client (simple): Bump vite from 6.3.5 to 7.0.0 in /client/simple (#4944)
* [upd] web-client (simple): Bump vite in /client/simple

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 7.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* [fix] theme/simple: api sync

CSS sourcemap generation doesn't work right now anyway.

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-07-04 11:04:22 +02:00
dependabot[bot]
08d8fb7146 [upd] github-actions: Bump aquasecurity/trivy-action (#4969)
Bumps [aquasecurity/trivy-action](https://github.com/aquasecurity/trivy-action) from 0.31.0 to 0.32.0.
- [Release notes](https://github.com/aquasecurity/trivy-action/releases)
- [Commits](https://github.com/aquasecurity/trivy-action/compare/0.31.0...0.32.0)

---
updated-dependencies:
- dependency-name: aquasecurity/trivy-action
  dependency-version: 0.32.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-04 11:01:23 +02:00
github-actions[bot]
eeed75b715 [l10n] update translations from Weblate (#4966) 2025-07-04 10:20:18 +02:00
Markus Heiser
34728ae097 [build] /static 2025-07-03 17:35:05 +02:00
Ivan Gabaldon
879ac4e60f [mod] theme/simple: fmt/lint major pass
*Not so safe* changes, no behaviour changes.

- More ES5 to ES2015+ conversion.
- Make Biome not cry anymore applying remaining changes.
2025-07-03 17:35:05 +02:00
Ivan Gabaldon
95172213f6 [mod] theme/simple: fmt/lint minor pass
*Safe* changes, no behaviour changes.

- Initial ES5 to ES2015+ conversion.
- Plenty of styling diff changes.
2025-07-03 17:35:05 +02:00
Ivan Gabaldon
a947d5b3cf [mod] theme/simple: improve fmt/lint tech
This is one of various PR to refactor the simple theme internally.

Replace eslint tool with Biome. I have been using this for quite some time, and
it will help us to have more consistent and valid code without extending on
other third party plugins.

Removes unused dependencies.
2025-07-03 17:35:05 +02:00
Bnyro
0cbb4f74cc [feat] wttr.in: migrate to new weather engine template (#4888)
Author Notes
- wttr.in provides 8 hourly time forecasts per day, I assumed that they're always describing the weather for 3 hours each, starting at 1 o'clock in the morning

related:
- https://github.com/searxng/searxng/pull/4663
- https://github.com/searxng/searxng/issues/4885
2025-07-03 16:42:13 +02:00
Bnyro
99033f548e [feat] calculator: add support for math constants (e, pi) 2025-07-03 13:57:31 +02:00
Bnyro
27466faadb [feat] calculator: add support for comparation operators (<, <=, ==, ...) 2025-07-03 13:57:31 +02:00
Bnyro
a0fca8c21b [feat] calculator: add some operations (mod, shifts, bitwise and/or) 2025-07-03 13:57:31 +02:00
Markus Heiser
39c50dc013 [fix] sec-fetch-* headers cannot be verified for non-secure requests (#4962)
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-06-30 13:31:45 +02:00
github-actions[bot]
60be0f453e [data] update searx.data - update_firefox_version.py (#4954)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-29 08:17:46 +02:00
github-actions[bot]
4fd3217786 [data] update searx.data - update_external_bangs.py (#4955)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-29 08:17:06 +02:00
github-actions[bot]
a8cc4ad877 [data] update searx.data - update_wikidata_units.py (#4956)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-29 08:16:07 +02:00
github-actions[bot]
c475508a1b [data] update searx.data - update_ahmia_blacklist.py (#4957)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-29 08:15:38 +02:00
github-actions[bot]
2c0bda729a [data] update searx.data - update_currencies.py (#4958)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-29 08:15:05 +02:00
github-actions[bot]
8de4119179 [data] update searx.data - update_engine_traits.py (#4959)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-29 08:14:42 +02:00
github-actions[bot]
6df862a4c7 [data] update searx.data - update_engine_descriptions.py (#4960)
Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-29 08:14:18 +02:00
dependabot[bot]
df76647c52 [upd] pypi: Bump lxml from 5.4.0 to 6.0.0 (#4948)
* [upd] pypi: Bump lxml from 5.4.0 to 6.0.0

Bumps [lxml](https://github.com/lxml/lxml) from 5.4.0 to 6.0.0.
- [Release notes](https://github.com/lxml/lxml/releases)
- [Changelog](https://github.com/lxml/lxml/blob/master/CHANGES.txt)
- [Commits](https://github.com/lxml/lxml/compare/lxml-5.4.0...lxml-6.0.0)

---
updated-dependencies:
- dependency-name: lxml
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* [enh] container: remove unneeded dependencies

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ivan Gabaldon <igabaldon@inetol.net>
2025-06-28 15:31:27 +02:00
dependabot[bot]
467536cc2d [upd] web-client (simple): Bump svgo from 3.3.2 to 4.0.0 in /client/simple (#4945)
* [upd] web-client (simple): Bump svgo in /client/simple

---
updated-dependencies:
- dependency-name: svgo
  dependency-version: 4.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* [build] /static

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-06-28 15:30:30 +02:00
Markus Heiser
657237dac4 [fix] leftover from PR #4947 - ./manage vite.simple.build (#4953)
PR #4947 upgraded the pygment, but forgot to apply the change to the static
files::

    $ ./manage vite.simple.build

Related:

- https://github.com/searxng/searxng/pull/4947
2025-06-28 13:34:36 +02:00
dependabot[bot]
9ee1ca89e7 [upd] pypi: Bump pygments from 2.19.1 to 2.19.2 in the minor group (#4947)
Bumps the minor group with 1 update: [pygments](https://github.com/pygments/pygments).


Updates `pygments` from 2.19.1 to 2.19.2
- [Release notes](https://github.com/pygments/pygments/releases)
- [Changelog](https://github.com/pygments/pygments/blob/master/CHANGES)
- [Commits](https://github.com/pygments/pygments/compare/2.19.1...2.19.2)

---
updated-dependencies:
- dependency-name: pygments
  dependency-version: 2.19.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-27 18:13:32 +02:00
Ivan Gabaldon
49fdf4edd9 [fix] utils: truncated result (#4949)
Make sure to prase everything before returning.

Related: \
```
FAIL: test_html_to_text (tests.unit.test_utils.TestUtils.test_html_to_text)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/searxng/searxng/tests/unit/test_utils.py", line 53, in test_html_to_text
    self.assertEqual(utils.html_to_text(r"regexp: (?<![a-zA-Z]"), "regexp: (?<![a-zA-Z]")
    ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: 'regexp: (?' != 'regexp: (?<![a-zA-Z]'
- regexp: (?
+ regexp: (?<![a-zA-Z]
```
2025-06-27 17:52:12 +02:00
dependabot[bot]
a76ccba9c5 [upd] web-client (simple): Bump vite-plugin-static-copy (#4943)
---
updated-dependencies:
- dependency-name: vite-plugin-static-copy
  dependency-version: 3.1.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-27 16:14:32 +02:00
github-actions[bot]
d47ff4d026 [l10n] update translations from Weblate (#4946)
66f385590 - 2025-06-26 - AndersNordh <andersnordh@noreply.codeberg.org>
2f0d725c7 - 2025-06-27 - MaheAlif <mahealif@noreply.codeberg.org>
3b8c842d2 - 2025-06-25 - SomeTr <sometr@noreply.codeberg.org>
88c5a918b - 2025-06-25 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
306e1f8a4 - 2025-06-25 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
f1314daea - 2025-06-25 - return42 <return42@noreply.codeberg.org>
f4d3905d2 - 2025-06-25 - Linerly <linerly@noreply.codeberg.org>
790dbb51c - 2025-06-25 - return42 <return42@noreply.codeberg.org>
4c59a2801 - 2025-06-24 - Outbreak2096 <outbreak2096@noreply.codeberg.org>
2b70aab75 - 2025-06-24 - ghose <ghose@noreply.codeberg.org>
dade2fbb2 - 2025-06-24 - SomeTr <sometr@noreply.codeberg.org>
930f76d9d - 2025-06-24 - AndersNordh <andersnordh@noreply.codeberg.org>
f2f5bfa28 - 2025-06-24 - SecularSteve <secularsteve@noreply.codeberg.org>
14bcf9a7b - 2025-06-24 - SecularSteve <secularsteve@noreply.codeberg.org>
ba266aa82 - 2025-06-24 - SecularSteve <secularsteve@noreply.codeberg.org>
c25b3788c - 2025-06-24 - SecularSteve <secularsteve@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-27 14:47:34 +02:00
Ivan Gabaldon
c6e0ad930d [fix] container: remove HEALTHCHECK (#4941)
This is a poorly designed instruction, which is hardcoded and cannot be easily modified or maintained on a rolling release sw like ours. This *should* be set in the SearXNG Docker Compose template, not in the image itself.

The OCI format is now used since we no longer have the HEALTHCHECK on the Dockerfile.

Closes https://github.com/searxng/searxng/issues/4906
Closes https://github.com/searxng/searxng/issues/4722
2025-06-26 14:46:59 +02:00
useralias
8757655644 [fix] restore startpage autocompleter
Changes:
- Undo deletions of the autocompleter in settings and logic
- Add fixed autocomplete function in autocomplete.py

Related:
- https://github.com/searxng/searxng/issues/4334
2025-06-25 17:38:31 +02:00
Markus Heiser
776ac0add8 [docs] Docker's entrypoint.sh does no longer have an help option -h
The new Docker entrypoint.sh script implemented in PR:

- https://github.com/searxng/searxng/pull/4793

does no longer have a `-h` option [1].  When building the `make docs` a warming
is shown::

  WARNING: Unexpected return code 2 from command Command(command=('../container/entrypoint.sh', '-h') .. (output='../container/entrypoint.sh: 152: SEARXNG_VERSION: parameter not set')

[1] https://github.com/searxng/searxng/pull/4793/files#diff-694a402a03e8de5aa227b1c0294ffdc072b6bac09b4dcbe144dc7d97d4e07159L35

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-06-25 09:32:01 +02:00
Markus Heiser
39474b392a [fix] debian: install apt package python-is-python3
On debian the 'python-is-python3' packages restores an appropriate
'/usr/bin/python' symlink for third-party scripts[1]

[1] https://github.com/searxng/searxng/issues/3235#issuecomment-1954459081

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-06-25 08:29:57 +02:00
benpiano800
b47ee0a4e3 [chore] docs: various grammatical fixes 2025-06-23 23:01:29 +02:00
Bnyro
cacfe54153 [chore] fix ci 2025-06-23 22:57:11 +02:00
Bnyro
b385f32098 [fix] uxwing: doesn't work / forbidden
the engine is currently broken because
- it requires a normal user agent (spoofed)
- it has some additional fingerprinting if using http2
2025-06-23 22:51:48 +02:00
Markus Heiser
2dd4f7b972 [mod] data: implement a simple tracker URL (SQL) database
On demand, the tracker data is loaded directly into the cache, so that the
maintenance of this data via PRs is no longer necessary.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-06-23 22:12:18 +02:00
Markus Heiser
58c10f758b [mod] plugins: activate tracker url plugin by default
With the new implementation for removing tracker arguments from URLs, we use the
tracker definitions of the ClearURLs project [1].  These definitions are
regularly updated and significantly improve data protection, which is why we
should now also enable this plugin by default.

[1] https://github.com/ClearURLs

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-06-23 22:12:18 +02:00
Bnyro
2001efbbab [data] update searx.data - add tracker_patterns.json 2025-06-23 22:12:18 +02:00
Bnyro
8f7eee2473 [feat] tracker url plugin: use ClearURL tracking param list 2025-06-23 22:12:18 +02:00
Bnyro
58df3e8e97 [build] /static 2025-06-22 09:41:16 +02:00
Bnyro
096fb74f4e [fix] weather template: text overflow on small screen devices
- this PR fixes that the columns of the weather table are overflowing on small screen devices
- therefore we now display "..." at the end of too long words and cut them off
- additionally I added some small gap between columns, otherwise it looks weird on small screens

- closes https://github.com/searxng/searxng/issues/4887
2025-06-22 09:41:16 +02:00
Robert M. Clabough
ec892d3836 [feat] engines: add Tube Archivist engine (#4889)
Tube Archivist [1] is a self-hosted project which archives youtube videos on
your own local server.  This engine connects with Tube Archivist's search API to
allow searching from SearXNG into your own hosted videos.

[1] https://www.tubearchivist.com/

Signed-off-by:  Robert M. Clabough <robert@claobugh.tech>
Co-authored-by: Bnyro <bnyro@tutanota.com>
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
2025-06-22 09:40:42 +02:00
useralias
cc61d0833c [refactor] yahoo engine: fix missing results and improve request code structure (#4923)
Changes:
- Add required iscqry, pz and bct search parameters
- Remove unused/optional search parameters (ei, fr2, age)
- Fix offset calculation
- Use new sB cookie for filters (time, safesearch, language)
- Group related parameter assignments together
- Restructure request parameter building to better match a real request
- Use f-strings for string formatting
- Add logging of domain and cookies used

Related:
- https://github.com/searxng/searxng/issues/4910
2025-06-22 08:56:25 +02:00
Nanashi
64f00bf5fd [fix] remove dissem.in due to its closure (#4930)
remove dissem.in due to its closure [1]

[1] https://association.dissem.in/dissemin-closure.html
2025-06-22 08:52:46 +02:00
dependabot[bot]
3c3f06aafe [upd] pypi: Bump certifi from 2025.4.26 to 2025.6.15 in the minor group (#4927)
Bumps the minor group with 1 update: [certifi](https://github.com/certifi/python-certifi).


Updates `certifi` from 2025.4.26 to 2025.6.15
- [Commits](https://github.com/certifi/python-certifi/compare/2025.04.26...2025.06.15)

---
updated-dependencies:
- dependency-name: certifi
  dependency-version: 2025.6.15
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-22 07:36:49 +02:00
dependabot[bot]
105dfad66d [upd] web-client (simple): Bump the minor group (#4926)
Bumps the minor group in /client/simple with 4 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js), [eslint](https://github.com/eslint/eslint), [stylelint](https://github.com/stylelint/stylelint) and [vite-plugin-static-copy](https://github.com/sapphi-red/vite-plugin-static-copy).


Updates `@eslint/js` from 9.28.0 to 9.29.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/commits/v9.29.0/packages/js)

Updates `eslint` from 9.28.0 to 9.29.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.28.0...v9.29.0)

Updates `stylelint` from 16.20.0 to 16.21.0
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/16.20.0...16.21.0)

Updates `vite-plugin-static-copy` from 3.0.0 to 3.0.2
- [Release notes](https://github.com/sapphi-red/vite-plugin-static-copy/releases)
- [Changelog](https://github.com/sapphi-red/vite-plugin-static-copy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sapphi-red/vite-plugin-static-copy/compare/vite-plugin-static-copy@3.0.0...vite-plugin-static-copy@3.0.2)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.29.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: eslint
  dependency-version: 9.29.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: stylelint
  dependency-version: 16.21.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: vite-plugin-static-copy
  dependency-version: 3.0.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-22 07:35:52 +02:00
github-actions[bot]
174faa342a [l10n] update translations from Weblate (#4925)
9c4f336a6 - 2025-06-19 - itsmrxyz <itsmrxyz@noreply.codeberg.org>
f639499e2 - 2025-06-18 - Adiker <adiker@noreply.codeberg.org>
67ddeb0b8 - 2025-06-19 - Fjuro <git@alius.cz>
2f37218d3 - 2025-06-17 - Linerly <linerly@noreply.codeberg.org>
b6b11a88e - 2025-06-16 - aindriu80 <aindriu80@noreply.codeberg.org>
23d4b17ed - 2025-06-16 - Shihfu Juan <xlion@xlion.tw>
b6e19a4a7 - 2025-06-16 - Juno Takano <jutty@noreply.codeberg.org>
9fe7bb4b4 - 2025-06-16 - artens <artens@noreply.codeberg.org>
a52c6a9ed - 2025-06-17 - radekjuthner <radekjuthner@noreply.codeberg.org>
91aafaa77 - 2025-06-16 - French <french@noreply.codeberg.org>
f00ea030c - 2025-06-15 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
0ff16bbad - 2025-06-14 - French <french@noreply.codeberg.org>
1785f8d3b - 2025-06-13 - SomeTr <sometr@noreply.codeberg.org>
2c394a6f4 - 2025-06-13 - AndersNordh <andersnordh@noreply.codeberg.org>
136e3016d - 2025-06-13 - ghose <ghose@noreply.codeberg.org>
c29cfab40 - 2025-06-13 - AndersNordh <andersnordh@noreply.codeberg.org>
cf982efb8 - 2025-06-13 - L33P <l33p@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-22 07:32:29 +02:00
github-actions[bot]
e52e9bb4b6 [l10n] update translations from Weblate (#4914)
0c960fb83 - 2025-06-13 - Outbreak2096 <outbreak2096@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-14 08:42:06 +02:00
benpiano800
0b877f1fb8 [mod] Hash plugin: List the available hash functions in the description
Co-authored-by: Bnyro <bnyro@tutanota.com>
2025-06-12 21:05:49 +02:00
benpiano800
a6d0333e30 [chore] Preferences: Make autocomplete description sound less casual (#4908) 2025-06-12 02:07:30 +02:00
benpiano800
e58ed0fdba [chore] Preferences: Fix grammatical error in results_on_new_tab.html (#4909) 2025-06-12 01:51:24 +02:00
Brock Vojkovic
8888d71ab9 [mod] disable wallhaven by default 2025-06-10 15:57:39 +00:00
Ivan Gabaldon
c081447d06 [fix] CI: prevent manifest removal (#4905)
The action does not take into account all cases of how an image is stored, causing errors like the ones below on image pull. I exclude `base` until I find a solution.

*Error: internal error: unable to copy from source ...: initializing source ...: reading manifest ... in ghcr.io/searxng/base: manifest unknown*
2025-06-10 13:49:36 +02:00
Markus Heiser
d0bb977c48 [fix] .editorconfig: correction of the settings from the realities (#4892)
The code formatter allows up to 120 characters per line, but for better
readability the editor should prefer 80 characters per line

In the HTML templates (jinja) we usually use an indentation of two and no tabs.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-06-09 07:19:50 +02:00
0xhtml
6a2cb45791 [feat] bing: raise error upon receiving wrong results page 2025-06-08 22:09:27 +02:00
benpiano800
49a1f08a17 [feat] engines: add Minecraft Wiki (#4896) 2025-06-06 17:05:30 +02:00
dependabot[bot]
33891e5367 [upd] github-actions: Bump aquasecurity/trivy-action (#4898)
Bumps [aquasecurity/trivy-action](https://github.com/aquasecurity/trivy-action) from 0.30.0 to 0.31.0.
- [Release notes](https://github.com/aquasecurity/trivy-action/releases)
- [Commits](https://github.com/aquasecurity/trivy-action/compare/0.30.0...0.31.0)

---
updated-dependencies:
- dependency-name: aquasecurity/trivy-action
  dependency-version: 0.31.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-06 10:34:07 +02:00
dependabot[bot]
13132c0769 [upd] web-client (simple): Bump the minor group (#4899)
Bumps the minor group in /client/simple with 3 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js), [eslint](https://github.com/eslint/eslint) and [ionicons](https://github.com/ionic-team/ionicons).


Updates `@eslint/js` from 9.27.0 to 9.28.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/commits/v9.28.0/packages/js)

Updates `eslint` from 9.27.0 to 9.28.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.27.0...v9.28.0)

Updates `ionicons` from 8.0.8 to 8.0.9
- [Release notes](https://github.com/ionic-team/ionicons/releases)
- [Commits](https://github.com/ionic-team/ionicons/compare/v8.0.8...v8.0.9)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.28.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: eslint
  dependency-version: 9.28.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: ionicons
  dependency-version: 8.0.9
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-06 10:03:54 +02:00
github-actions[bot]
3f1504a913 [l10n] update translations from Weblate (#4897)
1abc876b1 - 2025-06-06 - Linerly <linerly@noreply.codeberg.org>
8e107bf1a - 2025-06-06 - realkendrick_fr <realkendrick_fr@noreply.codeberg.org>
3ea971192 - 2025-06-03 - LinuxWizard <linuxwizard@noreply.codeberg.org>
455f80f14 - 2025-06-02 - ghose <ghose@noreply.codeberg.org>
aab313207 - 2025-06-02 - wags07 <wags07@noreply.codeberg.org>
1f1390745 - 2025-06-02 - aindriu80 <aindriu80@noreply.codeberg.org>
c098e4d67 - 2025-06-02 - Shihfu Juan <xlion@xlion.tw>
a30395996 - 2025-06-01 - AndersNordh <andersnordh@noreply.codeberg.org>
a1648feed - 2025-06-02 - yurtpage <yurtpage@noreply.codeberg.org>
985d3f23c - 2025-06-02 - rodgui <rodgui@noreply.codeberg.org>
1526dbc88 - 2025-06-02 - rodgui <rodgui@noreply.codeberg.org>
2d6baae9e - 2025-06-02 - artens <artens@noreply.codeberg.org>
bb5344f55 - 2025-06-02 - Haraldher <haraldher@noreply.codeberg.org>
08991138c - 2025-06-01 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
94952bbd5 - 2025-06-01 - AndersNordh <andersnordh@noreply.codeberg.org>
e4a792010 - 2025-06-01 - Fjuro <git@alius.cz>
0bd241620 - 2025-06-02 - thenack0 <thenack0@noreply.codeberg.org>
3bdff93bc - 2025-06-01 - pochinki <pochinki@noreply.codeberg.org>
091107dc4 - 2025-06-01 - Outbreak2096 <outbreak2096@noreply.codeberg.org>
ac147f2cc - 2025-05-31 - SomeTr <sometr@noreply.codeberg.org>
dd0b77eee - 2025-06-01 - ngf <ngf@noreply.codeberg.org>
db2aa378b - 2025-06-01 - return42 <return42@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-06-06 09:50:34 +02:00
Ivan Gabaldon
eb36de8d91 [mod] container: revert to alpine (#4893)
I'm not too pleased to reverse this, but issues like https://github.com/searxng/searxng/issues/4792 have not been foreseen, and we can't just turn away. It has become apparent over the last weeks that there are still quite a few people with an incompatible CPU or having SearXNG on some random VM provider who can't (or won't) modify the configuration of their machines to expose the features needed for x86_64v2 march.

As I don't want to trash the work with apko and base images, I thought about trying building Alpine again now that we have all the container related workflow refactored.

There will still be the discussion of whether to use musl and its drawbacks, but right now I don't know any other alternatives.

The nice part of this is that both Dockerfiles (mainline and legacy) can now be unified under the same umbrella again.

Closes https://github.com/searxng/searxng/issues/4792
Closes https://github.com/searxng/searxng/issues/4753
2025-06-03 21:24:47 +02:00
useralias
b73ac81815 [fix] startpage engine: resolve instant CAPTCHA issues (#4890)
Changes:
- Improve log messages for better debugging of future CAPTCHA issues
- Fixed erroneous get_sc_url variable where sc was always blank (when no cached value)
- Move Origin and Referer headers to request() function
- Add missing form parameters (abp, abd, abe) required by Startpage
  to avoid being flagged as automated requests
- Include segment parameter for paginated requests
- Clean up unnecessary commented-out headers
- Fix minor typos e.g. "time-stamp" → "timestamp", "scrap" → "scrapes"

Related:
- https://github.com/searxng/searxng/issues/4673
2025-06-03 09:58:52 +02:00
Markus Heiser
d63bdcd773 [mod] CI: exclude SearXNG checker and build & deploy of online docs (#4875)
checker.yml

1. The checker is not yet of sufficient quality to allow the results of the
   check to be evaluated / we do not evaluate them ourselves.

2. The checker sends hundreds of requests to the search engines and causes
   problems there / we either overload small providers or we train their bot
   defenses to use the SearXNG signature.

documentation.yml

Building the documentation and deploying it on GH-docs of a clones (GH forks) is
generally not desirable either --> We have >2k clones, but we only need one
up-to-date documentation and that is the one from the master branch of the
searxng/searxng repo.

If search engines like Google start linking to the documentation in the clones,
SearXNG users may no longer find the original documentation or be lost in the
flood of options.

Related:

- https://github.com/searxng/searxng/issues/4847

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-06-01 19:47:56 +02:00
benpiano800
93751b6379 [chore] engine preferences: fix grammar mistakes (#4883) 2025-05-31 21:09:31 +02:00
Markus Heiser
6e2d3e05c4 [build] /static 2025-05-31 20:34:59 +02:00
Markus Heiser
ff206e9679 [mod] weather results: add types, i18n/l10n, symbols & unit conversions
The types necessary for weather information such as GeoLocation, DateTime,
Temperature,Pressure, WindSpeed, RelativeHumidity, Compass (wind direction) and
symbols for the weather have been implemented.

There are unit conversions and translations for weather property labels.

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-31 20:34:59 +02:00
Markus Heiser
a800dd0473 [mod] implement searx.wikidata_units for unit converters 2025-05-31 20:34:59 +02:00
Bnyro
cf59ee2efc [feat] open meteo: use new weather answerer 2025-05-31 20:34:59 +02:00
Bnyro
d70f0a3321 [feat] result types: add weather result answerer and template 2025-05-31 20:34:59 +02:00
benpiano800
37d851fb23 [mod] UI footer: correct capitalization of "SearXNG" in base.html 2025-05-30 09:33:57 +02:00
dependabot[bot]
1b424b8d54 [upd] pypi: Bump the minor group with 2 updates
Bumps the minor group with 2 updates: [selenium](https://github.com/SeleniumHQ/Selenium) and [typer-slim](https://github.com/fastapi/typer).


Updates `selenium` from 4.32.0 to 4.33.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.32.0...selenium-4.33.0)

Updates `typer-slim` from 0.15.4 to 0.16.0
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.15.4...0.16.0)

---
updated-dependencies:
- dependency-name: selenium
  dependency-version: 4.33.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: typer-slim
  dependency-version: 0.16.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-05-30 09:23:11 +02:00
dependabot[bot]
b991688fcb [upd] web-client (simple): Bump the minor group
Bumps the minor group in /client/simple with 2 updates: [globals](https://github.com/sindresorhus/globals) and [stylelint](https://github.com/stylelint/stylelint).


Updates `globals` from 16.1.0 to 16.2.0
- [Release notes](https://github.com/sindresorhus/globals/releases)
- [Commits](https://github.com/sindresorhus/globals/compare/v16.1.0...v16.2.0)

Updates `stylelint` from 16.19.1 to 16.20.0
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/16.19.1...16.20.0)

---
updated-dependencies:
- dependency-name: globals
  dependency-version: 16.2.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: stylelint
  dependency-version: 16.20.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-05-30 09:16:49 +02:00
searxng-bot
44471bef35 [l10n] update translations from Weblate
0f55f2438 - 2025-05-29 - sandijs <sandijs@noreply.codeberg.org>
109f7dcb8 - 2025-05-26 - ngf <ngf@noreply.codeberg.org>
d2ba9b3d0 - 2025-05-26 - artnay <artnay@noreply.codeberg.org>
33c6f23bf - 2025-05-26 - realkendrick_fr <realkendrick_fr@noreply.codeberg.org>
2025-05-30 09:13:36 +02:00
dependabot[bot]
0b4c47a123 [upd] web-client (simple): Bump the minor group
Bumps the minor group in /client/simple with 4 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js), [eslint](https://github.com/eslint/eslint), [sharp](https://github.com/lovell/sharp) and [webpack](https://github.com/webpack/webpack).


Updates `@eslint/js` from 9.26.0 to 9.27.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/commits/v9.27.0/packages/js)

Updates `eslint` from 9.26.0 to 9.27.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.26.0...v9.27.0)

Updates `sharp` from 0.34.1 to 0.34.2
- [Release notes](https://github.com/lovell/sharp/releases)
- [Commits](https://github.com/lovell/sharp/compare/v0.34.1...v0.34.2)

Updates `webpack` from 5.99.8 to 5.99.9
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.99.8...v5.99.9)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.27.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: eslint
  dependency-version: 9.27.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: minor
- dependency-name: sharp
  dependency-version: 0.34.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
- dependency-name: webpack
  dependency-version: 5.99.9
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-05-29 09:00:15 +02:00
Markus Heiser
913dfbde3c [fix] plugins: currency processor bug
Fix C&P typo from  https://github.com/searxng/searxng/pull/4836

Closes: https://github.com/searxng/searxng/issues/4861
2025-05-29 07:37:59 +02:00
searxng-bot
7448a18efa [data] update searx.data - update_ahmia_blacklist.py 2025-05-29 07:11:55 +02:00
searxng-bot
23396f5a1d [data] update searx.data - update_firefox_version.py 2025-05-29 07:10:22 +02:00
searxng-bot
dbe6a6f4fa [data] update searx.data - update_wikidata_units.py 2025-05-29 07:08:32 +02:00
searxng-bot
b2727e1be9 [data] update searx.data - update_currencies.py 2025-05-29 07:07:55 +02:00
searxng-bot
9d8592afd7 [data] update searx.data - update_engine_traits.py 2025-05-29 07:07:05 +02:00
searxng-bot
70a387a48f [data] update searx.data - update_engine_descriptions.py 2025-05-29 07:06:38 +02:00
Bnyro
2288f07d62 [fix] presearch: reuse response cookies from token extraction
Why?
- presearch requires the response cookies of the first request to be sent within the second request
- otherwise we miss auth information and the engine doesn't work

Related:
- https://github.com/searxng/searxng/pull/4858
- closes https://github.com/searxng/searxng/issues/4854

Co-authored-by: Aadniz <8147434+Aadniz@users.noreply.github.com>
2025-05-28 12:53:45 +02:00
Bnyro
20b40351b9 [chore] il post: disable by default 2025-05-26 17:39:09 +02:00
Bnyro
7a5a499795 [build] /static 2025-05-25 18:04:18 +02:00
Bnyro
9dfdd30da0 [fix] search: autocomplete focus on results page
This has been a regression introduced with the removal of
the unmaintained autocomplete.js library.

We should only focus the search bar on the main search page at `/`
and not at the results page located at `/search`.

I'm not sure if there's a better way to figure out if
we're on the results page than checking if the id of the
main element is `#main_results`, checking the path
obviously isn't a better solution because it can differ
depending on the instance / reverse proxy / ....

- related to 32823ecb69
- closes https://github.com/searxng/searxng/issues/4846
2025-05-25 18:04:18 +02:00
Ivan Gabaldon
14b8a999f3 [mod] ci: exclude some workflows from forks (#4849)
Excludes some workflows/jobs unneeded on forks.

Closes https://github.com/searxng/searxng/issues/4847
2025-05-25 14:54:27 +02:00
Markus Heiser
848c8d0544 [mod] data: implement a simple currencies (SQL) database (#4836)
To reduce the memory footprint, this patch no longer loads the JSON data
completely into memory.  Instead, there is an SQL database based on
`ExpireCacheSQLite`.

The class CurrenciesDB is a simple DB application that encapsulates the
DB (queries and initialization) and provides convenient methods like
`name_to_iso4217` and `iso4217_to_name`.

Related:

- https://github.com/searxng/searxng/discussions/1892
- https://github.com/searxng/searxng/pull/3458#issuecomment-2900807671
- https://github.com/searxng/searxng/pull/4650

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-25 10:40:57 +02:00
github-actions[bot]
e46187e3ce [l10n] update translations from Weblate (#4840)
51e0a154c - 2025-05-22 - Priit Jõerüüt <jrtcdbrg@noreply.codeberg.org>
256b8cb8e - 2025-05-16 - wetinee <wetinee@noreply.codeberg.org>
ac12b76a8 - 2025-05-16 - wetinee <wetinee@noreply.codeberg.org>

Co-authored-by: searxng-bot <searxng-bot@users.noreply.github.com>
2025-05-25 10:36:27 +02:00
Markus Heiser
064eb50473 [mod] engines: Yahoo in different languages (#4826)
BTW fix issue reported in [1]

[1] https://github.com/searxng/searxng/pull/4814#issuecomment-2896948787

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Co-authored-by: Bnyro <bnyro@tutanota.com>
2025-05-24 13:14:13 +02:00
Alexandre Flament
9ed9a9aa53 [fix] searx.network: don't trigger DeprecationWarning (#4845)
Avoid a confusing warning:

    DeprecationWarning: Setting per-request cookies=<...> is being deprecated

Code based on httpx unit test [1]

[1] 6a99f6f2b3/tests/client/test_cookies.py (L123-L137)

Closes: https://github.com/searxng/searxng/issues/4833
2025-05-24 12:40:05 +02:00
Markus Heiser
230215c250 [fix] preferences: description not localized for all UI languages (#4844)
The previous implementation for determining the description of an engine did not
take into account that the UI languages ​​can also have a region tag and/or a
script tag:

    el-GR:      Ελληνικά, Ελλάδα (Greek, Greece)
    fa-IR:      فارسی, ایران (Persian, Iran)
    nb-NO:      Norsk bokmål, Norge (Norwegian bokmål, Norway)
    nl-BE:      Nederlands, België (Dutch, Belgium)
    pt-BR:      Português, Brasil (Portuguese, Brazil)
    zh-HK:      中文, 中國香港特別行政區 (Chinese, Hong Kong SAR China)
    zh-Hans-CN: 中文, 中国 (Chinese, China)
    zh-Hant-TW: 中文, 台灣 (Chinese, Taiwan)

Closes: https://github.com/searxng/searxng/issues/4842

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-23 17:11:41 +02:00
Markus Heiser
1ef5c03962 [fix] ddg engine: IndexError exception is raised on empty contend (#4843)
Sometimes (e.g. when ddg does not have a result item) there is no content and
the engine will fail with an IndexError:

  * Error: IndexError
  * Percentage: 10
  * Parameters: `()`
  * File name: `searx/engines/duckduckgo.py:375`
  * Function: `response`
  * Code: `item["content"] = extract_text(eval_xpath(div_result, './/a[contains(@class, "result__snippet")]')[0])`

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-23 14:55:22 +02:00
useralias
4fa7de8033 [refactor] duckduckgo engine: improve request logic and code structure (#4837)
Changes:
- Add trailing slash to base URL to prevent potential redirects
- Remove advanced search syntax filtering (no longer guarantees a CAPTCHA)
- Correct pagination offset calculation: Page 2 now starts at offset 10,
  subsequent pages use 10 + (n-2)*15 formula instead of the previous
  broken 20 + (n-2)*50 calculation that caused CAPTCHAs
- Restructure request parameter building to better match a real request
- "kt" cookie is no longer an empty string if the language/region is "all"
- Group related parameter assignments together
- Add header logging to debugging output

Related:

- https://github.com/searxng/searxng/issues/4824
2025-05-23 13:01:10 +02:00
Markus Heiser
98badc9cd0 [fix] searx.data: fetch-traits - z-library (httpx.ConnectError) (#4835)
There is currently no known z-library, and all known URLs are dead [1]. To avoid
interrupting automated updates, a connection error to a z-library is treated as
a *known error*, and the old properties of the z-library are retained.

[1] https://github.com/searxng/searxng/issues/3610

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-22 17:43:11 +02:00
Markus Heiser
d29cf64ce4 [mod] searx.data: lazy load of the data objects (databases) (#4834)
In the previous implementation, all databases were loaded into memory when
importing the searx.data package, regardless of whether they were ever needed.

Regardless of this, it is an antipattern to load entire databases into memory
when importing a package or module; databases should be loaded when needed.

Lazy loading is a first step toward improving memory usage and also improves
performance when setting up the runtime environment.  Building on this,
subsequent PRs will be able to further optimize memory behavior, e.g., by using
a real database application such as the one already available via

    searx.cache.ExpireCache

Related:

- https://github.com/searxng/searxng/discussions/1892
- https://github.com/searxng/searxng/pull/3458
- https://github.com/searxng/searxng/pull/4650

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-22 16:23:30 +02:00
Markus Heiser
861f9c4be5 [build] /static 2025-05-22 15:16:54 +02:00
Bnyro
32823ecb69 [refactor] search.js: use custom auto completion implementation
The previously used library is unmaintained for 6 years now [1] and the solution
had know issues [2][3]

[1] https://github.com/searxng/searxng/pull/4284#discussion_r1954493434
[2] https://github.com/searxng/searxng/pull/4318#issuecomment-2731576657
[3] https://github.com/privau/searxng/issues/56
2025-05-22 15:16:54 +02:00
Zhijie He
156d1eb8c8 [feat] engines: add Naver engine (#4573)
Refactor Naver engine (Web, News, Images, Videos, Autocomplete)

- ref: https://search.naver.com/
- lang: `ko`
- Wikidata: https://www.wikidata.org/wiki/Q485639

Co-authored-by: Bnyro <bnyro@tutanota.com>
2025-05-21 18:25:02 +02:00
Markus Heiser
365b9426f1 [fix] engines: disable those with known issues (#4813)
- z-library https://github.com/searxng/searxng/issues/3610
- library of congress: https://github.com/searxng/searxng/issues/4810
- qwant: https://github.com/searxng/searxng/issues/3929

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-21 15:50:29 +02:00
Ivan Gabaldon
9ffe23ecf3 [mod] container: remove -e flag
Temporarily remove the -e flag from set to prevent entrypoint.sh from stopping execution if any command returns a non-zero status. This doesn't solve anything but relaxes the script checks.

Related https://github.com/searxng/searxng/issues/4818
2025-05-21 15:27:26 +02:00
Bnyro
502017b901 [fix] pinterest: engine broken due to API changes (#4816)
- apparently the API now requires a `X-Pinterest-PWS-Handler` in order to
  properly function (extracted from their web UI)

- the other `X-Pinterest` headers here are added in case they become mandatory
  too

Closes: https://github.com/searxng/searxng/issues/4812
2025-05-21 15:22:42 +02:00
Bnyro
88973f5431 [feat] engines: add uxwing engine for icons (#4819)
- uxwing provides attribution-free icons to use for design projects
- svgrepo was my go-to before, but it's ratelimiting a lot recently
2025-05-21 15:10:29 +02:00
Bnyro
8bff73c9b6 [refactor] icon engines: add new icon category (#4817)
Icons category makes sense because it allows to quickly search for free SVG
icons to use for websites / other designs with a quick `!icons` query

Icons don't seem to fit into the normal images category that well because icons
are quite a special type of images
2025-05-21 14:52:16 +02:00
Jost Alemann
7420706a50 [chore] fix some docstring typos (#4815) 2025-05-20 21:03:54 +02:00
useralias
6ec554cb5b [fix] yahoo: url and title xpath 2025-05-20 21:02:40 +02:00
Alexandre Flament
7a3742ae56 [mod] upgrade to httpx 0.28.1 (#4674) 2025-05-20 18:18:07 +02:00
Markus Heiser
ca67f1dffe [fix] duckduckgo engines: issue when get_vqd() is used by ddg-images and ddg-videos (#4809)
The global variable CACHE is not initialized when DDG images or DDG videos
import the get_vqd() function (please remember: the engine modules are imported
using the importlib method and not via the `import` keyword).

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-20 16:10:10 +02:00
Ivan Gabaldon
749de829d5 [mod] container: refactor entrypoint script
That entrypoint is prone to screw things up, especially with permission handling. The new script handles initialization better and fixes some issues like delayed settings update via ENVs and timestamp overwriting, also adjusts what should be copied into the container.

Related https://github.com/searxng/searxng/pull/4721#issuecomment-2850272129
2025-05-20 11:49:30 +02:00
Ivan Gabaldon
a195f52412 [fix] container: base-builder should have essentials
The wolfi-base metapackage includes busybox, ca-certificates-bundle and the package manager. The change is to make the use of base-builder image more flexible.
2025-05-20 11:31:45 +02:00
dependabot[bot]
5dff826937 [upd] web-client (simple): Bump vite-plugin-static-copy (#4791)
Bumps [vite-plugin-static-copy](https://github.com/sapphi-red/vite-plugin-static-copy) from 2.3.1 to 3.0.0.
- [Release notes](https://github.com/sapphi-red/vite-plugin-static-copy/releases)
- [Changelog](https://github.com/sapphi-red/vite-plugin-static-copy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sapphi-red/vite-plugin-static-copy/compare/vite-plugin-static-copy@2.3.1...vite-plugin-static-copy@3.0.0)
2025-05-18 13:22:48 +02:00
Markus Heiser
b8b857d24c [mod] engine invidious: commented out / no public API available nowadays (#4800)
Reported-by: @unifox https://github.com/searxng/searxng/issues/2722#issuecomment-2884993248

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-18 13:20:27 +02:00
Ivan Gabaldon
86373e7c87 [mod] container: build custom base images (#4799)
Instead of using Wolfi base images from cgr.dev and making that mess on the Dockerfile, why don't we build the base images ourselves from Wolfi repos with apko? The intention of this is to simplify the main Dockerfile and avoid having to patch the base image every time, it also simplifies some steps like image ownership management and provides extremely fast builds.
2025-05-17 18:21:04 +02:00
github-actions[bot]
1b08324f26 [l10n] update translations from Weblate (#4788) 2025-05-16 09:40:45 +02:00
dependabot[bot]
b8682ffc69 [upd] pypi: Bump typer-slim from 0.15.3 to 0.15.4 in the minor group (#4789)
Bumps the minor group with 1 update: [typer-slim](https://github.com/fastapi/typer).


Updates `typer-slim` from 0.15.3 to 0.15.4
- [Release notes](https://github.com/fastapi/typer/releases)
- [Changelog](https://github.com/fastapi/typer/blob/master/docs/release-notes.md)
- [Commits](https://github.com/fastapi/typer/compare/0.15.3...0.15.4)

---
updated-dependencies:
- dependency-name: typer-slim
  dependency-version: 0.15.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-16 09:20:44 +02:00
Ivan Gabaldon
03083f07da [enh] container: use Wolfi OS as base image
Wolfi OS images are specifically designed for container use. Using a specially designed base image for containers not only reduces maintenance burdens, but improves overall experience for developers (fewer packages we have to track) and end users (smaller images).

Discussion here: https://github.com/searxng/searxng/issues/4753
2025-05-15 22:56:31 +02:00
Ivan Gabaldon
cd64fb966e [enh] container: support multiple registries
Allows to push the manifests to other registries, this allows to push both docker.io and ghcr.io registries.
2025-05-15 11:37:18 +02:00
Ivan Gabaldon
743f24d8c6 [fix] CI: commit author should be searxng-bot
If the workflow is executed with the "workflow_dispatch" trigger, the user who executed the workflow becomes the author of the commit on the PR, this is not intended.

It also reverts the body param so that the default text of the action does not appear.
2025-05-15 11:19:28 +02:00
Ivan Gabaldon
bec76bc2e3 [fix] CI: prevent race condition
`checker.yml` and `integration.yml` are the only workflows that are currently safe to be executed simultaneously, the others present a risk that the order of completion may not be expected. The ones that are chained from `integration.yml` can be called as many times as `integration.yml` workflows are running at that moment, the same with the trigger "workflow_dispatch".

This can be fatal for workflows like `container.yml` that use a centralized cache to store and load the candidate images in a common tag called "searxng-<arch>".

* For example, a `container.yml` workflow is executed after being chained from `integration.yml` (called "~1"), and seconds later it may be triggered again because another PR merged some breaking changes (called "~2"). While "~1" has already passed the test job successfully and is about to start the release job, "~2" finishes building the container and overwrites the references on the common tag. When "~1" in the release job loads the images using the common tag, it will load the container of "~2" instead of "~1" having skipped the whole test job process.

The example is only set for the container workflow, but the other workflows might occur in a similar way.
2025-05-15 11:19:28 +02:00
Ivan Gabaldon
d0b7f26f4b [fix] CI: container-mounts bad hash
This is a typo, but if there are multiple patterns in hashFiles, they should be separated by commas.

https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/evaluate-expressions-in-workflows-and-actions#examples-with-multiple-patterns
2025-05-15 11:19:28 +02:00
Ivan Gabaldon
b42f812c57 [fix] CI: handle old cache images from registry
Currently, we have 1100~ cache images uploaded to GHCR that weigh more than 300 MB each (most of them are layers from the second phase of the Dockerfile that were uploaded by mistake, read below). To avoid problems, I have set up a new job in a new workflow to be run weekly purging all images older than 1 week, but leaving always the 100 most recent ones.

Only the builder images should be uploaded to cache, the actual behaviour not only slows down the time for building the container, but also wastes lots of space by saving large and useless layers to GHCR that will never be used again.
2025-05-14 22:42:36 +02:00
dependabot[bot]
c73b469ce7 Bump flask from 3.1.0 to 3.1.1 (#4780)
Bumps [flask](https://github.com/pallets/flask) from 3.1.0 to 3.1.1.
- [Release notes](https://github.com/pallets/flask/releases)
- [Changelog](https://github.com/pallets/flask/blob/main/CHANGES.rst)
- [Commits](https://github.com/pallets/flask/compare/3.1.0...3.1.1)
2025-05-14 08:18:03 +02:00
Ivan Gabaldon
1a8884fa26 [enh] tidy: clean old morty, filtron, searx references
Everyone should have already switched from legacy methods.
2025-05-13 21:10:02 +02:00
dependabot[bot]
4fb29aae81 [upd] pypi: Bump the minor group with 2 updates (#4776)
Bumps the minor group with 2 updates: [selenium](https://github.com/SeleniumHQ/Selenium) and [redis](https://github.com/redis/redis-py).


Updates `selenium` from 4.31.0 to 4.32.0
- [Release notes](https://github.com/SeleniumHQ/Selenium/releases)
- [Commits](https://github.com/SeleniumHQ/Selenium/compare/selenium-4.31.0...selenium-4.32.0)

Updates `redis` from 5.0.8 to 5.2.1
- [Release notes](https://github.com/redis/redis-py/releases)
- [Changelog](https://github.com/redis/redis-py/blob/master/CHANGES)
- [Commits](https://github.com/redis/redis-py/compare/v5.0.8...v5.2.1)
2025-05-13 17:44:10 +02:00
dependabot[bot]
c303da55b0 [upd] web-client (simple): Bump the minor group (#4775)
Bumps the minor group in /client/simple with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) | `9.25.1` | `9.26.0` |
| [eslint](https://github.com/eslint/eslint) | `9.25.1` | `9.26.0` |
| [globals](https://github.com/sindresorhus/globals) | `16.0.0` | `16.1.0` |
| [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) | `6.3.4` | `6.3.5` |
| [webpack](https://github.com/webpack/webpack) | `5.99.7` | `5.99.8` |


Updates `@eslint/js` from 9.25.1 to 9.26.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/commits/v9.26.0/packages/js)

Updates `eslint` from 9.25.1 to 9.26.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.25.1...v9.26.0)

Updates `globals` from 16.0.0 to 16.1.0
- [Release notes](https://github.com/sindresorhus/globals/releases)
- [Commits](https://github.com/sindresorhus/globals/compare/v16.0.0...v16.1.0)

Updates `vite` from 6.3.4 to 6.3.5
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.3.5/packages/vite)

Updates `webpack` from 5.99.7 to 5.99.8
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.99.7...v5.99.8)
2025-05-13 17:38:46 +02:00
Ivan Gabaldon
2cfd3fc44b [enh] tidy: clean old morty, filtron, searx references
Everyone should have already switched from legacy methods
2025-05-13 10:37:02 +02:00
Markus Heiser
9006866019 [fix] engine archlinux: avoid Anubis challenge by User-Agent "SearXNG" (#4779)
Of the archlinux wikis only wiki.archlinux.org has a has Anubis challenge.

About Anubis[1]:

> Anubis decides to present a challenge using this logic:
>
> - User-Agent contains "Mozilla"
> ...
> This should ensure that git clients, RSS readers, and other low-harm clients
> can get through without issue ..

[1] 6c0ff3f4d5/docs/docs/design/how-anubis-works.mdx (challenge-presentation)


Suggested-by: @unixfox https://github.com/searxng/searxng/issues/4646#issuecomment-2855322406
Closes: https://github.com/searxng/searxng/issues/4646

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-13 10:18:28 +02:00
Ivan Gabaldon
5d99373bc6 [fix] DOCKERHUB_USERNAME env reference (#4778)
When making the container rework, I unknowingly deleted the section where an env with the same name as the secret was defined on the job scope, making it look like it was originally defined as an organization env.

Since we can't validate the secrets in a condition directly, it's better to let docker/login-action take care of failing the entire job if the credentials are invalid.

Reported in: https://github.com/searxng/searxng/issues/4777
2025-05-12 23:43:47 +02:00
Ivan Gabaldon
945b30a1c4 [mod] lib_sxng_container.sh: replace echo commands with heredoc
Suggested-by: @return42 https://github.com/searxng/searxng/pull/4764#discussion_r2083571202
2025-05-12 17:11:35 +02:00
Ivan Gabaldon
64a5b6920f [mod] lib_sxng_container.sh use required_commands() helper
Suggested-by: @return42 https://github.com/searxng/searxng/pull/4764#discussion_r2083564489
2025-05-12 17:11:35 +02:00
Markus Heiser
346d7fe019 [mod] CI: dependabot group updates by minor & patch and major updates (#4773)
By default, Dependabot opens a new pull request to update each dependency and we
have a very large number of Dependabot pull requests to review and merge, which
can quickly become difficult to manage.

The intention of this patch to dependabot is to have:

- one PR for all minor & patch level updates
- one PR for every dependency with a major update

[1] https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/optimizing-pr-creation-version-updates
[2] https://docs.github.com/en/code-security/dependabot/working-with-dependabot/dependabot-options-reference#groups

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2025-05-12 16:42:43 +02:00
745 changed files with 76632 additions and 45660 deletions

View File

@@ -1,4 +1,22 @@
FROM mcr.microsoft.com/devcontainers/base:debian
ARG DEBIAN_CODENAME="bookworm"
FROM mcr.microsoft.com/devcontainers/base:$DEBIAN_CODENAME
ARG DEBIAN_CODENAME="bookworm"
RUN cat <<EOF > /etc/apt/sources.list.d/debian.sources
Types: deb
URIs: http://deb.debian.org/debian
Suites: $DEBIAN_CODENAME $DEBIAN_CODENAME-updates $DEBIAN_CODENAME-backports
Components: main
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
Types: deb
URIs: http://security.debian.org/debian-security
Suites: $DEBIAN_CODENAME-security
Components: main
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
EOF
RUN apt-get update && \
apt-get -y install python3 python3-venv redis firefox-esr graphviz imagemagick librsvg2-bin fonts-dejavu shellcheck
apt-get -y install python3 python3-venv valkey-server firefox-esr graphviz imagemagick librsvg2-bin fonts-dejavu shellcheck

View File

@@ -1,5 +1,8 @@
{
"build": {
"args": {
"DEBIAN_CODENAME": "bookworm",
},
"dockerfile": "Dockerfile"
},
"features": {

View File

@@ -1,44 +1,5 @@
*~
*/*~
*/*/*~
*/*/*/*~
*/*/*/*/*~
*
# Git
.git
.gitignore
# CI
.codeclimate.yml
.travis.yml
.taskcluster.yml
# Byte-compiled / optimized / DLL files
__pycache__/
*/__pycache__/
*/*/__pycache__/
*/*/*/__pycache__/
*.py[cod]
*/*.py[cod]
*/*/*.py[cod]
*/*/*/*.py[cod]
# node_modules
node_modules/
*/node_modules/
*/*/node_modules/
*/*/*/node_modules/
*/*/*/*/node_modules/
.tx/
# to sync with .gitignore
geckodriver.log
.coverage
coverage/
cache/
build/
dist/
local/
gh-pages/
*.egg-info/
!container/entrypoint.sh
!searx/**
!requirements*.txt

View File

@@ -10,11 +10,22 @@ trim_trailing_whitespace = true
end_of_line = lf
charset = utf-8
[*.py]
max_line_length = 119
[{*.py,*.pyi}]
# code formatter accepts length of 120, but editor should prefer 80
max_line_length = 80
[{*.sh,manage}]
indent_style = space
indent_size = 4
# shfmt options
shell_variant = bash
switch_case_indent = true
[*.html]
indent_size = 4
# in the jinja templates we use indent size of 2 and we do not use tabs
indent_size = 2
indent_style = space
[*.css]
indent_size = 2
@@ -25,12 +36,24 @@ indent_size = 2
[*.js]
indent_size = 2
[*.ts]
indent_size = 2
[*.json]
indent_size = 2
insert_final_newline = ignore
[*.map]
indent_size = ignore
insert_final_newline = ignore
# Minified JavaScript files shouldn't be changed
[**.min.js]
[*.min.js]
indent_style = ignore
insert_final_newline = ignore
# Minified CSS files shouldn't be changed
[*.min.css]
indent_style = ignore
insert_final_newline = ignore

View File

@@ -13,7 +13,7 @@ assignees: ''
in order to fetch the latest commit ID:
```
git log -1
```
```
If you are using searxng-docker then look at the bottom of the SearXNG page
and check for the version after "Powered by SearXNG"
@@ -37,3 +37,5 @@ or manually by executing the searx/webapp.py file? -->
**Additional context**
<!-- Add any other context about the problem here. -->
- [ ] I read the [AI Policy](https://github.com/searxng/searxng/blob/master/AI_POLICY.rst) and hereby confirm that this issue conforms with the policy.

View File

@@ -29,3 +29,5 @@ You can add multiple categories at the same time. -->
**Additional context**
<!-- Add any other context about this engine here. -->
- [ ] I read the [AI Policy](https://github.com/searxng/searxng/blob/master/AI_POLICY.rst) and hereby confirm that this issue conforms with the policy.

View File

@@ -19,3 +19,5 @@ assignees: ''
**Additional context**
<!-- Add any other context or screenshots about the feature request here. -->
- [ ] I read the [AI Policy](https://github.com/searxng/searxng/blob/master/AI_POLICY.rst) and hereby confirm that this issue conforms with the policy.

View File

@@ -10,6 +10,12 @@ updates:
target-branch: "master"
commit-message:
prefix: "[upd] pypi:"
groups:
minor:
applies-to: version-updates
update-types:
- "minor"
- "patch"
- package-ecosystem: "npm"
directory: "/client/simple"
@@ -20,15 +26,44 @@ updates:
target-branch: "master"
commit-message:
prefix: "[upd] web-client (simple):"
groups:
minor:
applies-to: version-updates
update-types:
- "minor"
- "patch"
- package-ecosystem: "docker"
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "weekly"
day: "friday"
open-pull-requests-limit: 5
target-branch: "master"
commit-message:
prefix: "[upd] docker:"
prefix: "[upd] searxng.org/devtools (Node.js):"
groups:
minor:
applies-to: version-updates
update-types:
- "minor"
- "patch"
- package-ecosystem: "gomod"
directory: "/"
schedule:
interval: "weekly"
day: "friday"
open-pull-requests-limit: 5
target-branch: "master"
commit-message:
prefix: "[upd] searxng.org/devtools (Go):"
groups:
minor:
applies-to: version-updates
update-types:
- "minor"
- "patch"
- package-ecosystem: "github-actions"
directory: "/"

View File

@@ -1,46 +0,0 @@
---
name: Checker
# yamllint disable-line rule:truthy
on:
workflow_dispatch:
schedule:
- cron: "0 4 * * 5"
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: false
permissions:
contents: read
env:
PYTHON_VERSION: "3.13"
jobs:
search:
name: Search
runs-on: ubuntu-24.04-arm
steps:
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "${{ env.PYTHON_VERSION }}"
- name: Checkout
uses: actions/checkout@v4
with:
persist-credentials: "false"
- name: Setup cache Python
uses: actions/cache@v4
with:
key: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-"
path: "./local"
- name: Setup venv
run: make V=1 install
- name: Search checker
run: make search.checker

View File

@@ -13,20 +13,19 @@ on:
- master
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
group: ${{ github.workflow }}
cancel-in-progress: false
permissions:
contents: read
# Organization GHCR
packages: read
env:
PYTHON_VERSION: "3.13"
PYTHON_VERSION: "3.14"
jobs:
build:
if: github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success'
if: github.repository_owner == 'searxng' || github.event_name == 'workflow_dispatch'
name: Build (${{ matrix.arch }})
runs-on: ${{ matrix.os }}
strategy:
@@ -34,60 +33,83 @@ jobs:
matrix:
include:
- arch: amd64
march: amd64
os: ubuntu-24.04
emulation: false
- arch: arm64
march: arm64
os: ubuntu-24.04-arm
emulation: false
- arch: armv7
march: arm64
os: ubuntu-24.04-arm
emulation: true
permissions:
# Organization GHCR
packages: write
outputs:
version_string: ${{ steps.build.outputs.version_string }}
version_tag: ${{ steps.build.outputs.version_tag }}
docker_tag: ${{ steps.build.outputs.docker_tag }}
git_url: ${{ steps.build.outputs.git_url }}
git_branch: ${{ steps.build.outputs.git_branch }}
steps:
# yamllint disable rule:line-length
- name: Setup podman
env:
PODMAN_VERSION: "v5.7.1"
run: |
sudo apt-get purge -y podman runc crun conmon
curl -fsSLO "https://github.com/mgoltzsche/podman-static/releases/download/${{ env.PODMAN_VERSION }}/podman-linux-${{ matrix.march }}.tar.gz"
curl -fsSLO "https://github.com/mgoltzsche/podman-static/releases/download/${{ env.PODMAN_VERSION }}/podman-linux-${{ matrix.march }}.tar.gz.asc"
gpg --keyserver hkps://keyserver.ubuntu.com --recv-keys 0CCF102C4F95D89E583FF1D4F8B5AF50344BB503
gpg --batch --verify "podman-linux-${{ matrix.march }}.tar.gz.asc" "podman-linux-${{ matrix.march }}.tar.gz"
tar -xzf "podman-linux-${{ matrix.march }}.tar.gz"
sudo cp -rfv ./podman-linux-${{ matrix.march }}/etc/. /etc/
sudo cp -rfv ./podman-linux-${{ matrix.march }}/usr/. /usr/
sudo sysctl -w kernel.apparmor_restrict_unprivileged_userns=0
# yamllint enable rule:line-length
- name: Setup Python
uses: actions/setup-python@v5
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "${{ env.PYTHON_VERSION }}"
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: "false"
fetch-depth: "0"
- name: Setup cache Python
uses: actions/cache@v4
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
key: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-"
restore-keys: |
python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-
path: "./local/"
- name: Setup cache container mounts
uses: actions/cache@v4
- name: Get date
id: date
run: echo "date=$(date +'%Y%m%d')" >>$GITHUB_OUTPUT
- name: Setup cache container
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
# yamllint disable-line rule:line-length
key: "container-mounts-${{ matrix.arch }}-${{ hashFiles('./container/Dockerfile ./container/legacy/Dockerfile') }}"
restore-keys: "container-mounts-${{ matrix.arch }}-"
path: |
/var/tmp/buildah-cache/
/var/tmp/buildah-cache-*/
key: "container-${{ matrix.arch }}-${{ steps.date.outputs.date }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: |
container-${{ matrix.arch }}-${{ steps.date.outputs.date }}-
container-${{ matrix.arch }}-
path: "/var/tmp/buildah-cache-*/*"
- if: ${{ matrix.emulation }}
name: Setup QEMU
uses: docker/setup-qemu-action@v3
uses: docker/setup-qemu-action@ce360397dd3f832beb865e1373c09c0e9f86d70a # v4.0.0
- name: Login to GHCR
uses: docker/login-action@v3
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4.1.0
with:
registry: "ghcr.io"
username: "${{ github.repository_owner }}"
@@ -117,22 +139,18 @@ jobs:
os: ubuntu-24.04-arm
emulation: true
permissions:
# Organization GHCR
packages: write
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: "false"
- if: ${{ matrix.emulation }}
name: Setup QEMU
uses: docker/setup-qemu-action@v3
uses: docker/setup-qemu-action@ce360397dd3f832beb865e1373c09c0e9f86d70a # v4.0.0
- name: Login to GHCR
uses: docker/login-action@v3
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4.1.0
with:
registry: "ghcr.io"
username: "${{ github.repository_owner }}"
@@ -152,31 +170,30 @@ jobs:
- build
- test
permissions:
packages: write
steps:
- if: env.DOCKERHUB_USERNAME != null
name: Checkout
uses: actions/checkout@v4
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: "false"
- if: env.DOCKERHUB_USERNAME != null
name: Login to GHCR
uses: docker/login-action@v3
- name: Login to GHCR
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4.1.0
with:
registry: "ghcr.io"
username: "${{ github.repository_owner }}"
password: "${{ secrets.GITHUB_TOKEN }}"
- if: env.DOCKERHUB_USERNAME != null
name: Login to Docker Hub
uses: docker/login-action@v3
- name: Login to Docker Hub
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4.1.0
with:
registry: "docker.io"
username: "${{ env.DOCKERHUB_USERNAME }}"
password: "${{ secrets.DOCKERHUB_TOKEN }}"
username: "${{ secrets.DOCKER_USER }}"
password: "${{ secrets.DOCKER_TOKEN }}"
- if: env.DOCKERHUB_USERNAME != null
name: Release
- name: Release
env:
GIT_URL: "${{ needs.build.outputs.git_url }}"
DOCKER_TAG: "${{ needs.build.outputs.docker_tag }}"

View File

@@ -8,14 +8,14 @@ on:
- cron: "59 23 28 * *"
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
group: ${{ github.workflow }}
cancel-in-progress: false
permissions:
contents: read
env:
PYTHON_VERSION: "3.13"
PYTHON_VERSION: "3.14"
jobs:
data:
@@ -33,6 +33,7 @@ jobs:
- update_engine_traits.py
- update_wikidata_units.py
- update_engine_descriptions.py
- update_gsa_useragents.py
permissions:
contents: write
@@ -40,20 +41,21 @@ jobs:
steps:
- name: Setup Python
uses: actions/setup-python@v5
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "${{ env.PYTHON_VERSION }}"
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: "false"
- name: Setup cache Python
uses: actions/cache@v4
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
key: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-"
restore-keys: |
python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-
path: "./local/"
- name: Setup venv
@@ -64,9 +66,9 @@ jobs:
- name: Create PR
id: cpr
uses: peter-evans/create-pull-request@v7
uses: peter-evans/create-pull-request@c0f553fe549906ede9cf27b5156039d195d2ece0 # v8.1.0
with:
author: "${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>"
author: "searxng-bot <searxng-bot@users.noreply.github.com>"
committer: "searxng-bot <searxng-bot@users.noreply.github.com>"
title: "[data] update searx.data - ${{ matrix.fetch }}"
commit-message: "[data] update searx.data - ${{ matrix.fetch }}"
@@ -74,6 +76,8 @@ jobs:
delete-branch: "true"
draft: "false"
signoff: "false"
body: |
[data] update searx.data - ${{ matrix.fetch }}
labels: |
data

View File

@@ -12,17 +12,18 @@ on:
- master
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
group: ${{ github.workflow }}
cancel-in-progress: false
permissions:
contents: read
env:
PYTHON_VERSION: "3.13"
PYTHON_VERSION: "3.14"
jobs:
release:
if: github.repository_owner == 'searxng' || github.event_name == 'workflow_dispatch'
name: Release
runs-on: ubuntu-24.04-arm
permissions:
@@ -31,21 +32,22 @@ jobs:
steps:
- name: Setup Python
uses: actions/setup-python@v5
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "${{ env.PYTHON_VERSION }}"
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: "false"
fetch-depth: "0"
- name: Setup cache Python
uses: actions/cache@v4
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
key: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-"
restore-keys: |
python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-
path: "./local/"
- name: Setup venv
@@ -56,7 +58,7 @@ jobs:
- if: github.ref_name == 'master'
name: Release
uses: JamesIves/github-pages-deploy-action@v4
uses: JamesIves/github-pages-deploy-action@d92aa235d04922e8f08b40ce78cc5442fcfbfa2f # v4.8.0
with:
folder: "dist/docs"
branch: "gh-pages"

View File

@@ -18,7 +18,7 @@ permissions:
contents: read
env:
PYTHON_VERSION: "3.13"
PYTHON_VERSION: "3.14"
jobs:
test:
@@ -27,28 +27,28 @@ jobs:
strategy:
matrix:
python-version:
- "3.9"
- "3.10"
- "3.11"
- "3.12"
- "3.13"
- "3.14"
steps:
- name: Setup Python
uses: actions/setup-python@v5
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "${{ matrix.python-version }}"
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: "false"
- name: Setup cache Python
uses: actions/cache@v4
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
key: "python-${{ matrix.python-version }}-${{ runner.arch }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: "python-${{ matrix.python-version }}-${{ runner.arch }}-"
restore-keys: |
python-${{ matrix.python-version }}-${{ runner.arch }}-
path: "./local/"
- name: Setup venv
@@ -62,35 +62,39 @@ jobs:
runs-on: ubuntu-24.04-arm
steps:
- name: Setup Python
uses: actions/setup-python@v5
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "${{ env.PYTHON_VERSION }}"
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: "false"
- name: Setup Node.js
uses: actions/setup-node@v4
uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
with:
node-version-file: "./.nvmrc"
- name: Setup cache Node.js
uses: actions/cache@v4
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
key: "nodejs-${{ runner.arch }}-${{ hashFiles('./.nvmrc', './package.json') }}"
path: "./client/simple/node_modules/"
- name: Setup cache Python
uses: actions/cache@v4
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
key: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-"
restore-keys: |
python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-
path: "./local/"
- name: Setup venv
run: make V=1 install
- name: Lint
run: make themes.lint
- name: Build
run: make themes.all

View File

@@ -15,14 +15,14 @@ on:
- cron: "05 07 * * 5"
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
group: ${{ github.workflow }}
cancel-in-progress: false
permissions:
contents: read
env:
PYTHON_VERSION: "3.13"
PYTHON_VERSION: "3.14"
jobs:
update:
@@ -35,21 +35,22 @@ jobs:
steps:
- name: Setup Python
uses: actions/setup-python@v5
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "${{ env.PYTHON_VERSION }}"
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
token: "${{ secrets.WEBLATE_GITHUB_TOKEN }}"
fetch-depth: "0"
- name: Setup cache Python
uses: actions/cache@v4
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
key: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-"
restore-keys: |
python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-
path: "./local/"
- name: Setup venv
@@ -82,21 +83,22 @@ jobs:
steps:
- name: Setup Python
uses: actions/setup-python@v5
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "${{ env.PYTHON_VERSION }}"
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
token: "${{ secrets.WEBLATE_GITHUB_TOKEN }}"
fetch-depth: "0"
- name: Setup cache Python
uses: actions/cache@v4
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
key: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-"
restore-keys: |
python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-
path: "./local/"
- name: Setup venv
@@ -117,9 +119,9 @@ jobs:
- name: Create PR
id: cpr
uses: peter-evans/create-pull-request@v7
uses: peter-evans/create-pull-request@c0f553fe549906ede9cf27b5156039d195d2ece0 # v8.1.0
with:
author: "${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>"
author: "searxng-bot <searxng-bot@users.noreply.github.com>"
committer: "searxng-bot <searxng-bot@users.noreply.github.com>"
title: "[l10n] update translations from Weblate"
commit-message: "[l10n] update translations from Weblate"
@@ -127,8 +129,10 @@ jobs:
delete-branch: "true"
draft: "false"
signoff: "false"
body: |
[l10n] update translations from Weblate
labels: |
translation
area:i18n
- name: Display information
run: |

View File

@@ -8,7 +8,7 @@ on:
- cron: "42 05 * * *"
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
group: ${{ github.workflow }}
cancel-in-progress: false
permissions:
@@ -16,6 +16,7 @@ permissions:
jobs:
container:
if: github.repository_owner == 'searxng'
name: Container
runs-on: ubuntu-24.04-arm
permissions:
@@ -23,21 +24,23 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: "false"
- name: Run Trivy scanner
uses: aquasecurity/trivy-action@0.30.0
- name: Sync GHCS from Docker Scout
uses: docker/scout-action@bacf462e8d090c09660de30a6ccc718035f961e3 # v1.20.4
with:
image-ref: "docker.io/searxng/searxng:latest"
vuln-type: "os,library"
severity: "UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL"
ignore-unfixed: "false"
format: "sarif"
output: "./trivy-results.sarif"
organization: "searxng"
dockerhub-user: "${{ secrets.DOCKER_USER }}"
dockerhub-password: "${{ secrets.DOCKER_TOKEN }}"
image: "registry://ghcr.io/searxng/searxng:latest"
command: "cves"
sarif-file: "./scout.sarif"
exit-code: "false"
write-comment: "false"
- name: Upload SARIFs
uses: github/codeql-action/upload-sarif@v3
uses: github/codeql-action/upload-sarif@c10b8064de6f491fea524254123dbe5e09572f13 # v4.35.1
with:
sarif_file: "./trivy-results.sarif"
sarif_file: "./scout.sarif"

1
.gitignore vendored
View File

@@ -9,6 +9,7 @@ geckodriver.log
.coverage
coverage/
.govm/
.nvm/
cache/
build/

2
.nvmrc
View File

@@ -1 +1 @@
v23.5
25

View File

@@ -162,7 +162,7 @@ no-docstring-rgx=^_
property-classes=abc.abstractproperty
# Regular expression matching correct variable names
variable-rgx=(([a-z][a-zA-Z0-9_]{2,30})|(_[a-z0-9_]*)|([a-z]))$
variable-rgx=([a-zA-Z0-9_]*)$
[FORMAT]
@@ -311,7 +311,7 @@ dummy-variables-rgx=_+$|(_[a-zA-Z0-9_]*[a-zA-Z0-9]+?$)|dummy|^ignored_|^unused_
ignored-argument-names=_.*|^ignored_|^unused_
# Tells whether we should check for unused import in __init__ files.
init-import=no
init-import=yes
# List of qualified module names which can have objects that can redefine
# builtins.

View File

@@ -1,4 +0,0 @@
nodejs 23.5.0
python 3.13.1
shellcheck 0.10.0
sqlite 3.47.2

20
AI_POLICY.rst Normal file
View File

@@ -0,0 +1,20 @@
.. SPDX-License-Identifier: AGPL-3.0-or-later
AI Policy
=========
Restrictions on Generative AI Usage
-----------------------------------
- **All AI usage in any form must be disclosed.** You must state the tool you used (e.g. Claude Code, Cursor, Amp) along with the extent that the work was AI-assisted.
- **The human-in-the-loop must fully understand all code.** If you use generative AI tools as an aid in developing code or documentation changes, ensure that you fully understand the proposed changes and can explain why they are the correct approach.
- **AI should never be the main author of the PR.** AI may be used as a tool to help with developing, but the human contribution to the code changes should always be reasonably larger than the part written by AI. For example, you should be the one that decides about the structure of the PR, not the LLM.
- **Issues and PR descriptions must be fully human-written.** Do not post output from Large Language Models or similar generative AI as comments on any of our discussion forums (e.g. GitHub Issues, Matrix, ...), as such comments tend to be formulaic and low content. If you're a not a native English speaker, using AI for translating self-written issue texts to English is okay, but please keep the wording as close as possible to the original wording.
- **Bad AI drivers will be denounced.** People who produce bad contributions that are clearly AI (slop) will be blocked for all future contributions.
There are Humans Here
---------------------
Every discussion, issue, and pull request is read and reviewed by humans. It is a boundary point at which people interact with each other and the work done. It is rude and disrespectful to approach this boundary with low-effort, unqualified work, since it puts the burden of validation on the maintainer.
It takes a lot of maintainer time and energy to review AI-generated contributions! Sending the output of an LLM to open source project maintainers extracts work from them in the form of design and code review, so we call this kind of contribution an "extractive contribution".
The *golden rule* is that a contribution should be worth more to the project than the time it takes to review it, which is usually not the case if large parts of your PR were written by LLMs.

View File

@@ -2,7 +2,7 @@ searxng is a fork from `searx <https://github.com/searx/searx>`_ and is
maintained by Markus Heiser (`@return42 <https://github.com/return42>`_)
People who have submitted patches/translations, reported bugs, consulted
features or generally made searx better:
features or generally made SearXNG better:
- Adam Tauber `@asciimoo <https://github.com/asciimoo>`_
- Matej Cotman `@matejc <https://github.com/matejc>`_
@@ -177,3 +177,5 @@ features or generally made searx better:
- Daniel Mowitz `<https://daniel.mowitz.rocks>`
- `Bearz314 <https://github.com/bearz314>`_
- Tommaso Colella `<https://github.com/gioleppe>`
- @AgentScrubbles
- Filip Mikina `<https://github.com/fiffek>`

View File

@@ -1,49 +0,0 @@
# How to contribute
## Resources in the documentation
* [Development quickstart](https://docs.searxng.org/dev/quickstart.html)
* [Contribution guide](https://docs.searxng.org/dev/contribution_guide.html)
## Submitting PRs
Please follow the provided PR template when writing a description for your changes.
Do not take criticism personally. When you get feedback, it is about your work,
not your character, personality, etc. Keep in mind we all want to make the project better.
When something is not clear, please ask questions to clear things up.
If you would like to introduce a big architectural changes or do a refactoring
either in the codebase or the development tools, please open an issue with a proposal
first. This way we can think together about the problem and probably come up
with a better solution.
## Coding conventions and guidelines
### Commit messages
* Always write descriptive commit messages ("fix bug" is not acceptable).
* Use the present tense ("Add feature" not "Added feature").
* Use the imperative mood ("Move cursor to..." not "Moves cursor to...").
* Limit the first line to 72 characters or less.
* Include the number of the issue you are fixing.
### Coding guidelines
As a Python project, we must follow [PEP 8](https://www.python.org/dev/peps/pep-0008/) and [PEP 20](https://www.python.org/dev/peps/pep-0020/) guidelines.
Furthermore, follow the Clean code conventions. The most important
in this project are the following rules:
* Simpler is better. [KISS principle](https://en.wikipedia.org/wiki/KISS_principle)
* Be consistent.
* Every function must do one thing.
* Use descriptive names for functions and variables.
* Always look for the root cause.
* Keep configurable data high level.
* Avoid negative conditionals.
* Prefer fewer arguments.
* Do not add obvious comment to code.
* Do not comment out code, just delete lines.

98
CONTRIBUTING.rst Normal file
View File

@@ -0,0 +1,98 @@
.. SPDX-License-Identifier: AGPL-3.0-or-later
.. _Quickstart guide: https://docs.searxng.org/dev/quickstart.html
.. _Commits guide: https://docs.searxng.org/dev/commits.html
.. _AI Policy: https://github.com/searxng/searxng/blob/master/AI_POLICY.rst
.. _Weblate: https://translate.codeberg.org/projects/searxng/searxng/
.. _GitHub Codespaces: https://docs.github.com/en/codespaces/overview
.. _120 hours per month: https://github.com/settings/billing
.. _list of existing Codespaces: https://github.com/codespaces
Thank you for your interest in SearXNG.
Have a look at our `Quickstart guide`_, it's very easy to contribute.
Further information on *how-to* can be found
`here <https://docs.searxng.org/dev/index.html>`_.
Translations
============
Help translate SearXNG at `Weblate`_.
.. image:: https://translate.codeberg.org/widget/searxng/searxng/horizontal-auto.svg
:target: https://translate.codeberg.org/engage/searxng/
:alt: Weblate
:width: 768px
Cloud development
=================
You can contribute from your browser using `GitHub Codespaces`_:
- Fork the repository.
- Click on the ``<> Code`` green button.
- Click on the ``Codespaces`` tab instead of ``Local``.
- Click on ``Create codespace on master``.
- VSCode is going to start in the browser.
- Wait for ``git pull && make install`` to appear and then disappear.
- You have `120 hours per month`_ (see also your `list of existing Codespaces`_).
- You can start SearXNG using ``make run`` in the terminal or by pressing ``Ctrl+Shift+B``.
How-to contribute
=================
Submitting pull requests
------------------------
Please follow the provided PR template when writing a description for your
changes.
Do not take criticism personally. When you get feedback, it is about your work,
not your character or personality. Keep in mind we all want to make SearXNG
better.
When something is not clear, please ask questions to clear things up.
If you would like to introduce a big architectural change or do a refactor,
either in the codebase or the development tooling, please open an issue with a
proposal first. This way we can think together about the problem and probably
come up with a better solution.
Coding conventions and guidelines
---------------------------------
Commit messages
~~~~~~~~~~~~~~~
- Always write descriptive commit messages *("fix bug" is not acceptable)*.
- Use the present tense *("Add feature", not "Added feature")*.
- Use the imperative mood *("Move cursor to...", not "Moves cursor to...")*.
- Limit the first line (commit title) to 72 characters or less.
See `Commits guide`_ for more details.
Coding guidelines
~~~~~~~~~~~~~~~~~
As a Python project, we must follow `PEP 8 <https://www.python.org/dev/peps/pep-0008/>`_
and `PEP 20 <https://www.python.org/dev/peps/pep-0020/>`_ guidelines.
Furthermore, follow Clean Code conventions. The most important
rules in this project are:
- Simpler is better. `KISS principle <https://en.wikipedia.org/wiki/KISS_principle>`_
- Be consistent.
- Every function must do one thing.
- Use descriptive names for functions and variables.
- Always look for the root cause.
- Keep configurable data high level.
- Avoid negative conditionals.
- Prefer fewer arguments.
- Do not add obvious comments to code.
- Do not comment out code, delete lines instead.
AI Policy
~~~~~~~~~
For our policy on the use of AI tools, please read `AI Policy`_.

View File

@@ -17,7 +17,6 @@ help:
@echo 'install - developer install of SearxNG into virtualenv'
@echo 'uninstall - uninstall developer installation'
@echo 'clean - clean up working tree'
@echo 'search.checker - check search engines'
@echo 'test - run shell & CI tests'
@echo 'test.shell - test shell scripts'
@echo 'ci.test - run CI tests'
@@ -32,50 +31,39 @@ install uninstall:
$(Q)./manage pyenv.$@
PHONY += clean
clean: py.clean docs.clean node.clean nvm.clean test.clean
clean: py.clean docs.clean node.clean nvm.clean go.clean test.clean
$(Q)./manage build_msg CLEAN "common files"
$(Q)find . -name '*.orig' -exec rm -f {} +
$(Q)find . -name '*.rej' -exec rm -f {} +
$(Q)find . -name '*~' -exec rm -f {} +
$(Q)find . -name '*.bak' -exec rm -f {} +
lxc.clean:
$(Q)rm -rf lxc-env
PHONY += search.checker search.checker.%
search.checker: install
$(Q)./manage pyenv.cmd searxng-checker -v
search.checker.%: install
$(Q)./manage pyenv.cmd searxng-checker -v "$(subst _, ,$(patsubst search.checker.%,%,$@))"
PHONY += test ci.test test.shell
ci.test: test.yamllint test.black test.types.ci test.pylint test.unit test.robot test.rst test.shell test.pybabel
test: test.yamllint test.black test.types.dev test.pylint test.unit test.robot test.rst test.shell
test: test.yamllint test.black test.pyright_modified test.pylint test.unit test.robot test.rst test.shell test.shfmt
ci.test: test test.pybabel
test.shell:
$(Q)shellcheck -x -s dash \
container/docker-entrypoint.sh
container/entrypoint.sh
$(Q)shellcheck -x -s bash \
utils/brand.sh \
$(MTOOLS) \
utils/lib.sh \
utils/lib_sxng*.sh \
utils/lib_go.sh \
utils/lib_govm.sh \
utils/lib_nvm.sh \
utils/lib_redis.sh \
utils/searxng.sh \
utils/lxc.sh \
utils/lxc-searxng.env \
utils/searx.sh \
utils/filtron.sh \
utils/morty.sh
utils/lib_valkey.sh \
utils/searxng.sh
$(Q)$(MTOOLS) build_msg TEST "$@ OK"
PHONY += format
format: format.python format.shell
# wrap ./manage script
MANAGE += weblate.translations.commit weblate.push.translations
MANAGE += data.all data.traits data.useragents data.locales data.currencies
MANAGE += data.all data.traits data.useragents data.gsa_useragents data.locales data.currencies
MANAGE += docs.html docs.live docs.gh-pages docs.prebuild docs.clean
MANAGE += podman.build
MANAGE += docker.build docker.buildx
@@ -84,11 +72,12 @@ MANAGE += gecko.driver
MANAGE += node.env node.env.dev node.clean
MANAGE += py.build py.clean
MANAGE += pyenv pyenv.install pyenv.uninstall
MANAGE += format.python
MANAGE += test.yamllint test.pylint test.black test.pybabel test.unit test.coverage test.robot test.rst test.clean test.themes test.types.dev test.types.ci
MANAGE += themes.all themes.fix themes.test
MANAGE += format.python format.shell
MANAGE += test.yamllint test.pylint test.black test.pybabel test.unit test.coverage test.robot test.rst test.clean test.themes test.pyright test.pyright_modified test.shfmt
MANAGE += themes.all themes.simple themes.simple.analyze themes.fix themes.lint themes.test
MANAGE += static.build.commit static.build.drop static.build.restore
MANAGE += nvm.install nvm.clean nvm.status nvm.nodejs
MANAGE += go.env.dev go.clean
PHONY += $(MANAGE)

View File

@@ -23,3 +23,8 @@
<!--
Closes #234
-->
## AI Disclosure
<!-- please read https://github.com/searxng/searxng/blob/master/AI_POLICY.rst -->
- [ ] I hereby confirm that I have not used any AI tools for creating this PR.
- [ ] I have used AI tools for working on the changes in this pull request and will attach a list of all AI tools I used and how I used them. I hereby confirm that I haven't used any other tools than the ones I mention below.

View File

@@ -1,130 +1,62 @@
.. SPDX-License-Identifier: AGPL-3.0-or-later
----
.. _metasearch engine: https://en.wikipedia.org/wiki/Metasearch_engine
.. _Installation guide: https://docs.searxng.org/admin/installation.html
.. _Configuration guide: https://docs.searxng.org/admin/settings/index.html
.. _CONTRIBUTING: https://github.com/searxng/searxng/blob/master/CONTRIBUTING.rst
.. _LICENSE: https://github.com/searxng/searxng/blob/master/LICENSE
.. figure:: https://raw.githubusercontent.com/searxng/searxng/master/client/simple/src/brand/searxng.svg
:target: https://docs.searxng.org/
:target: https://searxng.org
:alt: SearXNG
:width: 100%
:align: center
:width: 512px
----
Privacy-respecting, hackable `metasearch engine`_
SearXNG is a `metasearch engine`_. Users are neither tracked nor profiled.
Searx.space_ lists ready-to-use running instances.
.. image:: https://img.shields.io/badge/organization-3050ff?style=flat-square&logo=searxng&logoColor=fff&cacheSeconds=86400
:target: https://github.com/searxng
:alt: Organization
A user_, admin_ and developer_ handbook is available on the homepage_.
.. image:: https://img.shields.io/badge/documentation-3050ff?style=flat-square&logo=readthedocs&logoColor=fff&cacheSeconds=86400
:target: https://docs.searxng.org
:alt: Documentation
|SearXNG install|
|SearXNG homepage|
|SearXNG wiki|
|AGPL License|
|Issues|
|commits|
|weblate|
|SearXNG logo|
----
.. _searx.space: https://searx.space
.. _user: https://docs.searxng.org/user
.. _admin: https://docs.searxng.org/admin
.. _developer: https://docs.searxng.org/dev
.. _homepage: https://docs.searxng.org/
.. _metasearch engine: https://en.wikipedia.org/wiki/Metasearch_engine
.. |SearXNG logo| image:: https://raw.githubusercontent.com/searxng/searxng/master/client/simple/src/brand/searxng-wordmark.svg
:target: https://docs.searxng.org/
:width: 5%
.. |SearXNG install| image:: https://img.shields.io/badge/-install-blue
:target: https://docs.searxng.org/admin/installation.html
.. |SearXNG homepage| image:: https://img.shields.io/badge/-homepage-blue
:target: https://docs.searxng.org/
.. |SearXNG wiki| image:: https://img.shields.io/badge/-wiki-blue
:target: https://github.com/searxng/searxng/wiki
.. |AGPL License| image:: https://img.shields.io/badge/license-AGPL-blue.svg
.. image:: https://img.shields.io/github/license/searxng/searxng?style=flat-square&label=license&color=3050ff&cacheSeconds=86400
:target: https://github.com/searxng/searxng/blob/master/LICENSE
:alt: License
.. |Issues| image:: https://img.shields.io/github/issues/searxng/searxng?color=yellow&label=issues
:target: https://github.com/searxng/searxng/issues
.. image:: https://img.shields.io/github/commit-activity/y/searxng/searxng/master?style=flat-square&label=commits&color=3050ff&cacheSeconds=3600
:target: https://github.com/searxng/searxng/commits/master/
:alt: Commits
.. |PR| image:: https://img.shields.io/github/issues-pr-raw/searxng/searxng?color=yellow&label=PR
:target: https://github.com/searxng/searxng/pulls
.. |commits| image:: https://img.shields.io/github/commit-activity/y/searxng/searxng?color=yellow&label=commits
:target: https://github.com/searxng/searxng/commits/master
.. |weblate| image:: https://translate.codeberg.org/widgets/searxng/-/searxng/svg-badge.svg
.. image:: https://img.shields.io/weblate/progress/searxng?server=https%3A%2F%2Ftranslate.codeberg.org&style=flat-square&label=translated&color=3050ff&cacheSeconds=86400
:target: https://translate.codeberg.org/projects/searxng/
Contact
=======
Ask questions or chat with the SearXNG community (this not a chatbot) on
IRC
`#searxng on libera.chat <https://web.libera.chat/?channel=#searxng>`_
which is bridged to Matrix.
Matrix
`#searxng:matrix.org <https://matrix.to/#/#searxng:matrix.org>`_
:alt: Translated
Setup
=====
- A well maintained `Docker image`_, also built for ARM64 and ARM/v7
architectures.
- Alternatively there are *up to date* `installation scripts`_.
- For individual setup consult our detailed `Step by step`_ instructions.
- To fine-tune your instance, take a look at the `Administrator documentation`_.
To install SearXNG, see `Installation guide`_.
.. _Administrator documentation: https://docs.searxng.org/admin/index.html
.. _Step by step: https://docs.searxng.org/admin/installation-searxng.html
.. _installation scripts: https://docs.searxng.org/admin/installation-scripts.html
.. _Docker image: https://github.com/searxng/searxng-docker
To fine-tune SearXNG, see `Configuration guide`_.
Translations
============
Further information on *how-to* can be found `here <https://docs.searxng.org/admin/index.html>`_.
.. _Weblate: https://translate.codeberg.org/projects/searxng/searxng/
Connect
=======
Help translate SearXNG at `Weblate`_
.. figure:: https://translate.codeberg.org/widgets/searxng/-/multi-auto.svg
:target: https://translate.codeberg.org/projects/searxng/
If you have questions or want to connect with others in the community:
- `#searxng:matrix.org <https://matrix.to/#/#searxng:matrix.org>`_
Contributing
============
.. _development quickstart: https://docs.searxng.org/dev/quickstart.html
.. _developer documentation: https://docs.searxng.org/dev/index.html
See CONTRIBUTING_ for more details.
Are you a developer? Have a look at our `development quickstart`_ guide, it's
very easy to contribute. Additionally we have a `developer documentation`_.
License
=======
Codespaces
==========
You can contribute from your browser using `GitHub Codespaces`_:
- Fork the repository
- Click on the ``<> Code`` green button
- Click on the ``Codespaces`` tab instead of ``Local``
- Click on ``Create codespace on master``
- VSCode is going to start in the browser
- Wait for ``git pull && make install`` to appear and then disappear
- You have `120 hours per month`_ (see also your `list of existing Codespaces`_)
- You can start SearXNG using ``make run`` in the terminal or by pressing ``Ctrl+Shift+B``
.. _GitHub Codespaces: https://docs.github.com/en/codespaces/overview
.. _120 hours per month: https://github.com/settings/billing
.. _list of existing Codespaces: https://github.com/codespaces
This project is licensed under the GNU Affero General Public License (AGPL-3.0).
See LICENSE_ for more details.

View File

@@ -1,3 +1,2 @@
dist
node_modules
.stylelintcache

View File

@@ -1,17 +1,19 @@
{
"formatter": "unix",
"plugins": [ "stylelint-prettier" ],
"extends": [ "stylelint-config-standard-less" ],
"$schema": "https://json.schemastore.org/stylelintrc.json",
"plugins": ["stylelint-prettier"],
"extends": ["stylelint-config-standard-less"],
"rules": {
"prettier/prettier": true,
"declaration-empty-line-before": null,
"no-invalid-position-at-import-rule": null,
"property-no-vendor-prefix": null,
"selector-no-vendor-prefix": null,
"selector-attribute-quotes": null,
"shorthand-property-no-redundant-values": null,
"at-rule-no-vendor-prefix": null,
"at-rule-prelude-no-invalid": null,
"declaration-empty-line-before": null,
"declaration-property-value-no-unknown": null,
"no-invalid-position-at-import-rule": null,
"prettier/prettier": true,
"property-no-vendor-prefix": null,
"selector-attribute-quotes": null,
"selector-class-pattern": null,
"selector-id-pattern": null,
"selector-class-pattern": null
"selector-no-vendor-prefix": null,
"shorthand-property-no-redundant-values": null
}
}

169
client/simple/biome.json Normal file
View File

@@ -0,0 +1,169 @@
{
"$schema": "./node_modules/@biomejs/biome/configuration_schema.json",
"files": {
"ignoreUnknown": true,
"includes": ["**", "!node_modules"]
},
"assist": {
"enabled": true,
"actions": {
"recommended": true,
"source": {
"useSortedAttributes": "on",
"useSortedProperties": "on"
}
}
},
"formatter": {
"enabled": true,
"bracketSameLine": false,
"bracketSpacing": true,
"formatWithErrors": false,
"indentStyle": "space",
"indentWidth": 2,
"lineEnding": "lf",
"lineWidth": 120
},
"linter": {
"enabled": true,
"rules": {
"recommended": true,
"complexity": {
"noForEach": "error",
"noImplicitCoercions": "error",
"noUselessCatchBinding": "error",
"noUselessUndefined": "error",
"useSimplifiedLogicExpression": "error"
},
"correctness": {
"noGlobalDirnameFilename": "error",
"useImportExtensions": "error",
"useJsonImportAttributes": "error",
"useSingleJsDocAsterisk": "error"
},
"nursery": {
"noContinue": "warn",
"noEqualsToNull": "warn",
"noFloatingPromises": "warn",
"noForIn": "warn",
"noIncrementDecrement": "warn",
"noMisusedPromises": "warn",
"noMultiAssign": "warn",
"noMultiStr": "warn",
"noNestedPromises": "warn",
"noParametersOnlyUsedInRecursion": "warn",
"noRedundantDefaultExport": "warn",
"noReturnAssign": "warn",
"noUselessReturn": "off",
"useAwaitThenable": "off",
"useConsistentEnumValueType": "warn",
"useDestructuring": "warn",
"useExhaustiveSwitchCases": "warn",
"useExplicitType": "off",
"useFind": "warn",
"useRegexpExec": "warn"
},
"performance": {
"noAwaitInLoops": "error",
"noBarrelFile": "error",
"noDelete": "error",
"noNamespaceImport": "error",
"noReExportAll": "error",
"useTopLevelRegex": "error"
},
"style": {
"noCommonJs": "error",
"noEnum": "error",
"noImplicitBoolean": "error",
"noInferrableTypes": "error",
"noNamespace": "error",
"noNegationElse": "error",
"noNestedTernary": "error",
"noParameterAssign": "error",
"noParameterProperties": "error",
"noRestrictedTypes": {
"level": "error",
"options": {
"types": {
"Element": {
"message": "Element is too generic",
"use": "HTMLElement"
}
}
}
},
"noSubstr": "error",
"noUnusedTemplateLiteral": "error",
"noUselessElse": "error",
"noYodaExpression": "error",
"useAsConstAssertion": "error",
"useAtIndex": "error",
"useCollapsedElseIf": "error",
"useCollapsedIf": "error",
"useConsistentArrayType": {
"level": "error",
"options": {
"syntax": "shorthand"
}
},
"useConsistentBuiltinInstantiation": "error",
"useConsistentMemberAccessibility": {
"level": "error",
"options": {
"accessibility": "explicit"
}
},
"useConsistentObjectDefinitions": {
"level": "error",
"options": {
"syntax": "explicit"
}
},
"useConsistentTypeDefinitions": {
"level": "error",
"options": {
"style": "type"
}
},
"useDefaultSwitchClause": "error",
"useExplicitLengthCheck": "error",
"useForOf": "error",
"useGroupedAccessorPairs": "error",
"useNumberNamespace": "error",
"useNumericSeparators": "error",
"useObjectSpread": "error",
"useReadonlyClassProperties": "error",
"useSelfClosingElements": "error",
"useShorthandAssign": "error",
"useSingleVarDeclarator": "error",
"useThrowNewError": "error",
"useThrowOnlyError": "error",
"useTrimStartEnd": "error",
"useUnifiedTypeSignatures": "error"
},
"suspicious": {
"noAlert": "error",
"noBitwiseOperators": "error",
"noConstantBinaryExpressions": "error",
"noDeprecatedImports": "error",
"noEmptyBlockStatements": "error",
"noEvolvingTypes": "error",
"noImportCycles": "error",
"noUnassignedVariables": "error",
"noVar": "error",
"useNumberToFixedDigitsArgument": "error",
"useStaticResponseMethods": "error"
}
}
},
"javascript": {
"formatter": {
"arrowParentheses": "always",
"jsxQuoteStyle": "double",
"quoteProperties": "asNeeded",
"quoteStyle": "double",
"semicolons": "always",
"trailingCommas": "none"
}
}
}

View File

@@ -1,34 +0,0 @@
import globals from "globals";
import pluginJs from "@eslint/js";
/** @type {import('eslint').Linter.Config[]} */
export default [
pluginJs.configs.recommended,
// global "ignores"
// https://eslint.org/docs/latest/use/configure/configuration-files#globally-ignoring-files-with-ignores
{
ignores: ["node_modules/", "dist/"]
},
{
files: [
"**/*.js",
],
linterOptions: {
reportUnusedDisableDirectives: "error",
// noInlineConfig: true
},
languageOptions: {
sourceType: "module",
globals: {
...globals.browser,
}
},
rules: {
indent: ["error", 2],
},
},
];

View File

@@ -1,12 +1,16 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/*
this file is generated automatically by searxng_extra/update/update_pygments.py
using pygments version 2.19.1
using pygments version 2.20.0:
./manage templates.simple.pygments
*/
.code-highlight {
pre { line-height: 100%; }
pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
@@ -85,89 +89,89 @@
.code-highlight-dark(){
.code-highlight {
pre { line-height: 100%; }
td.linenos .normal { color: #3c4354; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: #3c4354; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #3c4354; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #3c4354; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.hll { background-color: #6e7681 }
.c { color: #7E8AA1 } /* Comment */
.err { color: #F88F7F } /* Error */
.esc { color: #D4D2C8 } /* Escape */
.g { color: #D4D2C8 } /* Generic */
.k { color: #FFAD66 } /* Keyword */
.l { color: #D5FF80 } /* Literal */
.n { color: #D4D2C8 } /* Name */
.o { color: #FFAD66 } /* Operator */
.x { color: #D4D2C8 } /* Other */
.p { color: #D4D2C8 } /* Punctuation */
.ch { color: #F88F7F; font-style: italic } /* Comment.Hashbang */
.cm { color: #7E8AA1 } /* Comment.Multiline */
.cp { color: #FFAD66; font-weight: bold } /* Comment.Preproc */
.cpf { color: #7E8AA1 } /* Comment.PreprocFile */
.c1 { color: #7E8AA1 } /* Comment.Single */
.cs { color: #7E8AA1; font-style: italic } /* Comment.Special */
.gd { color: #F88F7F; background-color: #3D1E20 } /* Generic.Deleted */
.ge { color: #D4D2C8; font-style: italic } /* Generic.Emph */
.ges { color: #D4D2C8 } /* Generic.EmphStrong */
.gr { color: #F88F7F } /* Generic.Error */
.gh { color: #D4D2C8 } /* Generic.Heading */
.gi { color: #6AD4AF; background-color: #19362C } /* Generic.Inserted */
.go { color: #7E8AA1 } /* Generic.Output */
.gp { color: #D4D2C8 } /* Generic.Prompt */
.gs { color: #D4D2C8; font-weight: bold } /* Generic.Strong */
.gu { color: #D4D2C8 } /* Generic.Subheading */
.gt { color: #F88F7F } /* Generic.Traceback */
.kc { color: #FFAD66 } /* Keyword.Constant */
.kd { color: #FFAD66 } /* Keyword.Declaration */
.kn { color: #FFAD66 } /* Keyword.Namespace */
.kp { color: #FFAD66 } /* Keyword.Pseudo */
.kr { color: #FFAD66 } /* Keyword.Reserved */
.kt { color: #73D0FF } /* Keyword.Type */
.ld { color: #D5FF80 } /* Literal.Date */
.m { color: #DFBFFF } /* Literal.Number */
.s { color: #D5FF80 } /* Literal.String */
.na { color: #FFD173 } /* Name.Attribute */
.nb { color: #FFD173 } /* Name.Builtin */
.nc { color: #73D0FF } /* Name.Class */
.no { color: #FFD173 } /* Name.Constant */
.nd { color: #7E8AA1; font-weight: bold; font-style: italic } /* Name.Decorator */
.ni { color: #95E6CB } /* Name.Entity */
.ne { color: #73D0FF } /* Name.Exception */
.nf { color: #FFD173 } /* Name.Function */
.nl { color: #D4D2C8 } /* Name.Label */
.nn { color: #D4D2C8 } /* Name.Namespace */
.nx { color: #D4D2C8 } /* Name.Other */
.py { color: #FFD173 } /* Name.Property */
.nt { color: #5CCFE6 } /* Name.Tag */
.nv { color: #D4D2C8 } /* Name.Variable */
.ow { color: #FFAD66 } /* Operator.Word */
.pm { color: #D4D2C8 } /* Punctuation.Marker */
.w { color: #D4D2C8 } /* Text.Whitespace */
.mb { color: #DFBFFF } /* Literal.Number.Bin */
.mf { color: #DFBFFF } /* Literal.Number.Float */
.mh { color: #DFBFFF } /* Literal.Number.Hex */
.mi { color: #DFBFFF } /* Literal.Number.Integer */
.mo { color: #DFBFFF } /* Literal.Number.Oct */
.sa { color: #F29E74 } /* Literal.String.Affix */
.sb { color: #D5FF80 } /* Literal.String.Backtick */
.sc { color: #D5FF80 } /* Literal.String.Char */
.dl { color: #D5FF80 } /* Literal.String.Delimiter */
.sd { color: #7E8AA1 } /* Literal.String.Doc */
.s2 { color: #D5FF80 } /* Literal.String.Double */
.se { color: #95E6CB } /* Literal.String.Escape */
.sh { color: #D5FF80 } /* Literal.String.Heredoc */
.si { color: #95E6CB } /* Literal.String.Interpol */
.sx { color: #95E6CB } /* Literal.String.Other */
.sr { color: #95E6CB } /* Literal.String.Regex */
.s1 { color: #D5FF80 } /* Literal.String.Single */
.ss { color: #DFBFFF } /* Literal.String.Symbol */
.bp { color: #5CCFE6 } /* Name.Builtin.Pseudo */
.fm { color: #FFD173 } /* Name.Function.Magic */
.vc { color: #D4D2C8 } /* Name.Variable.Class */
.vg { color: #D4D2C8 } /* Name.Variable.Global */
.vi { color: #D4D2C8 } /* Name.Variable.Instance */
.vm { color: #D4D2C8 } /* Name.Variable.Magic */
.il { color: #DFBFFF } /* Literal.Number.Integer.Long */
pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.hll { background-color: #49483e }
.c { color: #959077 } /* Comment */
.err { color: #ED007E; background-color: #1E0010 } /* Error */
.esc { color: #F8F8F2 } /* Escape */
.g { color: #F8F8F2 } /* Generic */
.k { color: #66D9EF } /* Keyword */
.l { color: #AE81FF } /* Literal */
.n { color: #F8F8F2 } /* Name */
.o { color: #FF4689 } /* Operator */
.x { color: #F8F8F2 } /* Other */
.p { color: #F8F8F2 } /* Punctuation */
.ch { color: #959077 } /* Comment.Hashbang */
.cm { color: #959077 } /* Comment.Multiline */
.cp { color: #959077 } /* Comment.Preproc */
.cpf { color: #959077 } /* Comment.PreprocFile */
.c1 { color: #959077 } /* Comment.Single */
.cs { color: #959077 } /* Comment.Special */
.gd { color: #FF4689 } /* Generic.Deleted */
.ge { color: #F8F8F2; font-style: italic } /* Generic.Emph */
.ges { color: #F8F8F2; font-weight: bold; font-style: italic } /* Generic.EmphStrong */
.gr { color: #F8F8F2 } /* Generic.Error */
.gh { color: #F8F8F2 } /* Generic.Heading */
.gi { color: #A6E22E } /* Generic.Inserted */
.go { color: #66D9EF } /* Generic.Output */
.gp { color: #FF4689; font-weight: bold } /* Generic.Prompt */
.gs { color: #F8F8F2; font-weight: bold } /* Generic.Strong */
.gu { color: #959077 } /* Generic.Subheading */
.gt { color: #F8F8F2 } /* Generic.Traceback */
.kc { color: #66D9EF } /* Keyword.Constant */
.kd { color: #66D9EF } /* Keyword.Declaration */
.kn { color: #FF4689 } /* Keyword.Namespace */
.kp { color: #66D9EF } /* Keyword.Pseudo */
.kr { color: #66D9EF } /* Keyword.Reserved */
.kt { color: #66D9EF } /* Keyword.Type */
.ld { color: #E6DB74 } /* Literal.Date */
.m { color: #AE81FF } /* Literal.Number */
.s { color: #E6DB74 } /* Literal.String */
.na { color: #A6E22E } /* Name.Attribute */
.nb { color: #F8F8F2 } /* Name.Builtin */
.nc { color: #A6E22E } /* Name.Class */
.no { color: #66D9EF } /* Name.Constant */
.nd { color: #A6E22E } /* Name.Decorator */
.ni { color: #F8F8F2 } /* Name.Entity */
.ne { color: #A6E22E } /* Name.Exception */
.nf { color: #A6E22E } /* Name.Function */
.nl { color: #F8F8F2 } /* Name.Label */
.nn { color: #F8F8F2 } /* Name.Namespace */
.nx { color: #A6E22E } /* Name.Other */
.py { color: #F8F8F2 } /* Name.Property */
.nt { color: #FF4689 } /* Name.Tag */
.nv { color: #F8F8F2 } /* Name.Variable */
.ow { color: #FF4689 } /* Operator.Word */
.pm { color: #F8F8F2 } /* Punctuation.Marker */
.w { color: #F8F8F2 } /* Text.Whitespace */
.mb { color: #AE81FF } /* Literal.Number.Bin */
.mf { color: #AE81FF } /* Literal.Number.Float */
.mh { color: #AE81FF } /* Literal.Number.Hex */
.mi { color: #AE81FF } /* Literal.Number.Integer */
.mo { color: #AE81FF } /* Literal.Number.Oct */
.sa { color: #E6DB74 } /* Literal.String.Affix */
.sb { color: #E6DB74 } /* Literal.String.Backtick */
.sc { color: #E6DB74 } /* Literal.String.Char */
.dl { color: #E6DB74 } /* Literal.String.Delimiter */
.sd { color: #E6DB74 } /* Literal.String.Doc */
.s2 { color: #E6DB74 } /* Literal.String.Double */
.se { color: #AE81FF } /* Literal.String.Escape */
.sh { color: #E6DB74 } /* Literal.String.Heredoc */
.si { color: #E6DB74 } /* Literal.String.Interpol */
.sx { color: #E6DB74 } /* Literal.String.Other */
.sr { color: #E6DB74 } /* Literal.String.Regex */
.s1 { color: #E6DB74 } /* Literal.String.Single */
.ss { color: #E6DB74 } /* Literal.String.Symbol */
.bp { color: #F8F8F2 } /* Name.Builtin.Pseudo */
.fm { color: #A6E22E } /* Name.Function.Magic */
.vc { color: #F8F8F2 } /* Name.Variable.Class */
.vg { color: #F8F8F2 } /* Name.Variable.Global */
.vi { color: #F8F8F2 } /* Name.Variable.Instance */
.vm { color: #F8F8F2 } /* Name.Variable.Magic */
.il { color: #AE81FF } /* Literal.Number.Integer.Long */
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -1,41 +1,49 @@
{
"name": "simple",
"version": "1.0.0",
"$schema": "https://json.schemastore.org/package.json",
"name": "@searxng/theme-simple",
"version": "0.0.0",
"private": true,
"license": "AGPL-3.0",
"type": "module",
"scripts": {
"build": "npm run build:icons && npm run build:vite",
"build:icons": "node theme_icons.ts",
"build:vite": "vite build",
"clean": "rm -Rf node_modules",
"build": "node theme_icons.js && vite build",
"fix": "eslint --fix && stylelint --fix strict 'src/**/*.{css,scss,sass,less,styl,vue,svelte}'",
"icons.html": "node theme_icons.js"
"fix": "npm run fix:stylelint && npm run fix:biome && npm run fix:package",
"fix:biome": "biome check --write",
"fix:package": "sort-package-json --quiet",
"fix:stylelint": "stylelint --fix strict 'src/**/*.{scss,sass,less,styl}'",
"lint": "npm run lint:biome && npm run lint:tsc",
"lint:biome": "biome lint",
"lint:tsc": "tsc --noEmit"
},
"browserslist": [
"baseline 2022",
"not dead"
],
"dependencies": {
"ionicons": "^8.0.13",
"normalize.css": "8.0.1",
"ol": "^10.8.0",
"swiped-events": "1.2.0"
},
"devDependencies": {
"@eslint/js": "^9.25.1",
"copy-webpack-plugin": "^13.0.0",
"css-loader": "^7.1.2",
"edge.js": "^6.2.1",
"eslint": "^9.25.1",
"filemanager-webpack-plugin": "^8.0.0",
"globals": "^16.0.0",
"ionicons": "^8.0.8",
"leaflet": "^1.9.4",
"less": "^4.3.0",
"less-loader": "^12.3.0",
"normalize.css": "^8.0.1",
"sharp": "^0.34.1",
"style-loader": "^4.0.0",
"stylelint": "^16.19.1",
"stylelint-config-standard": "^38.0.0",
"stylelint-config-standard-less": "^3.0.1",
"@biomejs/biome": "2.4.10",
"@types/node": "^25.5.0",
"browserslist": "^4.28.2",
"browserslist-to-esbuild": "^2.1.1",
"edge.js": "^6.5.0",
"less": "^4.6.4",
"mathjs": "^15.1.1",
"sharp": "~0.34.5",
"sort-package-json": "^3.6.1",
"stylelint": "^17.6.0",
"stylelint-config-standard-less": "^4.1.0",
"stylelint-prettier": "^5.0.3",
"svgo": "^3.3.2",
"swiped-events": "^1.2.0",
"vite": "^6.3.4",
"vite-plugin-static-copy": "^2.3.1",
"vite-plugin-stylelint": "^6.0.0",
"webpack": "^5.99.7",
"webpack-cli": "^6.0.1"
},
"dependencies": {
"autocomplete-js": "^2.7.1"
"svgo": "^4.0.1",
"typescript": "~6.0.2",
"vite": "^8.0.3",
"vite-bundle-analyzer": "^1.3.6"
}
}

View File

@@ -0,0 +1,66 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/**
* Base class for client-side plugins.
*
* @remarks
* Handle conditional loading of the plugin in:
*
* - client/simple/src/js/router.ts
*
* @abstract
*/
export abstract class Plugin {
/**
* Plugin name.
*/
protected readonly id: string;
/**
* @remarks
* Don't hold references of this instance outside the class.
*/
protected constructor(id: string) {
this.id = id;
queueMicrotask(() => this.invoke());
}
private async invoke(): Promise<void> {
try {
console.debug(`[PLUGIN] ${this.id}: Running...`);
const result = await this.run();
if (!result) return;
console.debug(`[PLUGIN] ${this.id}: Running post-exec...`);
// @ts-expect-error
void (await this.post(result as NonNullable<Awaited<ReturnType<this["run"]>>>));
} catch (error) {
console.error(`[PLUGIN] ${this.id}:`, error);
} finally {
console.debug(`[PLUGIN] ${this.id}: Done.`);
}
}
/**
* Plugin goes here.
*
* @remarks
* The plugin is already loaded at this point. If you wish to execute
* conditions to exit early, consider moving the logic to:
*
* - client/simple/src/js/router.ts
*
* ...to avoid unnecessarily loading this plugin on the client.
*/
protected abstract run(): Promise<unknown>;
/**
* Post-execution hook.
*
* @remarks
* The hook is only executed if `#run()` returns a truthy value.
*/
// @ts-expect-error
protected abstract post(result: NonNullable<Awaited<ReturnType<this["run"]>>>): Promise<void>;
}

View File

@@ -1,20 +0,0 @@
/* SPDX-License-Identifier: AGPL-3.0-or-later */
(function (w, d) {
'use strict';
// add data- properties
var script = d.currentScript || (function () {
var scripts = d.getElementsByTagName('script');
return scripts[scripts.length - 1];
})();
w.searxng = {
settings: JSON.parse(atob(script.getAttribute('client_settings')))
};
// update the css
var htmlElement = d.getElementsByTagName("html")[0];
htmlElement.classList.remove('no-js');
htmlElement.classList.add('js');
})(window, document);

View File

@@ -0,0 +1,4 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
// core
void import.meta.glob(["./*.ts", "./util/**/.ts"], { eager: true });

View File

@@ -0,0 +1,36 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import type { Plugin } from "./Plugin.ts";
import { type EndpointsKeys, endpoint } from "./toolkit.ts";
type Options =
| {
on: "global";
}
| {
on: "endpoint";
where: EndpointsKeys[];
};
export const load = <T extends Plugin>(instance: () => Promise<T>, options: Options): void => {
if (!check(options)) return;
void instance();
};
const check = (options: Options): boolean => {
// biome-ignore lint/style/useDefaultSwitchClause: options is typed
switch (options.on) {
case "global": {
return true;
}
case "endpoint": {
if (!options.where.includes(endpoint)) {
// not on the expected endpoint
return false;
}
return true;
}
}
};

View File

@@ -1,165 +0,0 @@
/**
* @license
* (C) Copyright Contributors to the SearXNG project.
* (C) Copyright Contributors to the searx project (2014 - 2021).
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
window.searxng = (function (w, d) {
'use strict';
// not invented here toolkit with bugs fixed elsewhere
// purposes : be just good enough and as small as possible
// from https://plainjs.com/javascript/events/live-binding-event-handlers-14/
if (w.Element) {
(function (ElementPrototype) {
ElementPrototype.matches = ElementPrototype.matches ||
ElementPrototype.matchesSelector ||
ElementPrototype.webkitMatchesSelector ||
ElementPrototype.msMatchesSelector ||
function (selector) {
var node = this, nodes = (node.parentNode || node.document).querySelectorAll(selector), i = -1;
while (nodes[++i] && nodes[i] != node);
return !!nodes[i];
};
})(Element.prototype);
}
function callbackSafe (callback, el, e) {
try {
callback.call(el, e);
} catch (exception) {
console.log(exception);
}
}
var searxng = window.searxng || {};
searxng.on = function (obj, eventType, callback, useCapture) {
useCapture = useCapture || false;
if (typeof obj !== 'string') {
// obj HTMLElement, HTMLDocument
obj.addEventListener(eventType, callback, useCapture);
} else {
// obj is a selector
d.addEventListener(eventType, function (e) {
var el = e.target || e.srcElement, found = false;
while (el && el.matches && el !== d && !(found = el.matches(obj))) el = el.parentElement;
if (found) callbackSafe(callback, el, e);
}, useCapture);
}
};
searxng.ready = function (callback) {
if (document.readyState != 'loading') {
callback.call(w);
} else {
w.addEventListener('DOMContentLoaded', callback.bind(w));
}
};
searxng.http = function (method, url, data = null) {
return new Promise(function (resolve, reject) {
try {
var req = new XMLHttpRequest();
req.open(method, url, true);
req.timeout = 20000;
// On load
req.onload = function () {
if (req.status == 200) {
resolve(req.response, req.responseType);
} else {
reject(Error(req.statusText));
}
};
// Handle network errors
req.onerror = function () {
reject(Error("Network Error"));
};
req.onabort = function () {
reject(Error("Transaction is aborted"));
};
req.ontimeout = function () {
reject(Error("Timeout"));
}
// Make the request
if (data) {
req.send(data)
} else {
req.send();
}
} catch (ex) {
reject(ex);
}
});
};
searxng.loadStyle = function (src) {
var path = searxng.settings.theme_static_path + "/" + src,
id = "style_" + src.replace('.', '_'),
s = d.getElementById(id);
if (s === null) {
s = d.createElement('link');
s.setAttribute('id', id);
s.setAttribute('rel', 'stylesheet');
s.setAttribute('type', 'text/css');
s.setAttribute('href', path);
d.body.appendChild(s);
}
};
searxng.loadScript = function (src, callback) {
var path = searxng.settings.theme_static_path + "/" + src,
id = "script_" + src.replace('.', '_'),
s = d.getElementById(id);
if (s === null) {
s = d.createElement('script');
s.setAttribute('id', id);
s.setAttribute('src', path);
s.onload = callback;
s.onerror = function () {
s.setAttribute('error', '1');
};
d.body.appendChild(s);
} else if (!s.hasAttribute('error')) {
try {
callback.apply(s, []);
} catch (exception) {
console.log(exception);
}
} else {
console.log("callback not executed : script '" + path + "' not loaded.");
}
};
searxng.insertBefore = function (newNode, referenceNode) {
referenceNode.parentNode.insertBefore(newNode, referenceNode);
};
searxng.insertAfter = function (newNode, referenceNode) {
referenceNode.parentNode.insertAfter(newNode, referenceNode.nextSibling);
};
searxng.on('.close', 'click', function () {
this.parentNode.classList.add('invisible');
});
function getEndpoint () {
for (var className of d.getElementsByTagName('body')[0].classList.values()) {
if (className.endsWith('_endpoint')) {
return className.split('_')[0];
}
}
return '';
}
searxng.endpoint = getEndpoint();
return searxng;
})(window, document);

View File

@@ -0,0 +1,142 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import { http, listen, settings } from "../toolkit.ts";
import { assertElement } from "../util/assertElement.ts";
const fetchResults = async (qInput: HTMLInputElement, query: string): Promise<void> => {
try {
let res: Response;
if (settings.method === "GET") {
res = await http("GET", `./autocompleter?q=${query}`);
} else {
res = await http("POST", "./autocompleter", { body: new URLSearchParams({ q: query }) });
}
const results = await res.json();
const autocomplete = document.querySelector<HTMLElement>(".autocomplete");
assertElement(autocomplete);
const autocompleteList = document.querySelector<HTMLUListElement>(".autocomplete ul");
assertElement(autocompleteList);
autocomplete.classList.add("open");
autocompleteList.replaceChildren();
// show an error message that no result was found
if (results?.[1]?.length === 0) {
const noItemFoundMessage = Object.assign(document.createElement("li"), {
className: "no-item-found",
textContent: settings.translations?.no_item_found ?? "No results found"
});
autocompleteList.append(noItemFoundMessage);
return;
}
const fragment = new DocumentFragment();
for (const result of results[1]) {
const li = Object.assign(document.createElement("li"), { textContent: result });
listen("mousedown", li, () => {
qInput.value = result;
const form = document.querySelector<HTMLFormElement>("#search");
form?.submit();
});
fragment.append(li);
}
autocompleteList.append(fragment);
} catch (error) {
console.error("Error fetching autocomplete results:", error);
}
};
const qInput = document.getElementById("q") as HTMLInputElement | null;
assertElement(qInput);
let timeoutId: number;
listen("input", qInput, () => {
clearTimeout(timeoutId);
const query = qInput.value;
const minLength = settings.autocomplete_min ?? 2;
if (query.length < minLength) return;
timeoutId = window.setTimeout(async () => {
if (query === qInput.value) {
await fetchResults(qInput, query);
}
}, 300);
});
const autocomplete: HTMLElement | null = document.querySelector<HTMLElement>(".autocomplete");
const autocompleteList: HTMLUListElement | null = document.querySelector<HTMLUListElement>(".autocomplete ul");
if (autocompleteList) {
listen("keydown", qInput, (event: KeyboardEvent) => {
if (event.key === "Escape") {
autocomplete?.classList.remove("open");
}
});
listen("keyup", qInput, (event: KeyboardEvent) => {
const listItems = [...autocompleteList.children] as HTMLElement[];
const currentIndex = listItems.findIndex((item) => item.classList.contains("active"));
let newCurrentIndex = -1;
switch (event.key) {
case "ArrowUp": {
const currentItem = listItems[currentIndex];
if (currentItem && currentIndex >= 0) {
currentItem.classList.remove("active");
}
// we need to add listItems.length to the index calculation here because the JavaScript modulos
// operator doesn't work with negative numbers
newCurrentIndex = (currentIndex - 1 + listItems.length) % listItems.length;
break;
}
case "ArrowDown": {
const currentItem = listItems[currentIndex];
if (currentItem && currentIndex >= 0) {
currentItem.classList.remove("active");
}
newCurrentIndex = (currentIndex + 1) % listItems.length;
break;
}
case "Enter":
if (autocomplete) {
autocomplete.classList.remove("open");
}
break;
default:
break;
}
if (newCurrentIndex !== -1) {
const selectedItem = listItems[newCurrentIndex];
if (selectedItem) {
selectedItem.classList.add("active");
if (!selectedItem.classList.contains("no-item-found")) {
const qInput = document.getElementById("q") as HTMLInputElement | null;
if (qInput) {
qInput.value = selectedItem.textContent ?? "";
}
}
}
}
});
listen("blur", qInput, () => {
autocomplete?.classList.remove("open");
});
listen("focus", qInput, () => {
autocomplete?.classList.add("open");
});
}

View File

@@ -1,88 +0,0 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/* global searxng */
searxng.ready(function () {
'use strict';
searxng.infinite_scroll_supported = (
'IntersectionObserver' in window &&
'IntersectionObserverEntry' in window &&
'intersectionRatio' in window.IntersectionObserverEntry.prototype);
if (searxng.endpoint !== 'results') {
return;
}
if (!searxng.infinite_scroll_supported) {
console.log('IntersectionObserver not supported');
return;
}
let d = document;
var onlyImages = d.getElementById('results').classList.contains('only_template_images');
function newLoadSpinner () {
var loader = d.createElement('div');
loader.classList.add('loader');
return loader;
}
function replaceChildrenWith (element, children) {
element.textContent = '';
children.forEach(child => element.appendChild(child));
}
function loadNextPage (callback) {
var form = d.querySelector('#pagination form.next_page');
if (!form) {
return
}
replaceChildrenWith(d.querySelector('#pagination'), [ newLoadSpinner() ]);
var formData = new FormData(form);
searxng.http('POST', d.querySelector('#search').getAttribute('action'), formData).then(
function (response) {
var nextPageDoc = new DOMParser().parseFromString(response, 'text/html');
var articleList = nextPageDoc.querySelectorAll('#urls article');
var paginationElement = nextPageDoc.querySelector('#pagination');
d.querySelector('#pagination').remove();
if (articleList.length > 0 && !onlyImages) {
// do not add <hr> element when there are only images
d.querySelector('#urls').appendChild(d.createElement('hr'));
}
articleList.forEach(articleElement => {
d.querySelector('#urls').appendChild(articleElement);
});
if (paginationElement) {
d.querySelector('#results').appendChild(paginationElement);
callback();
}
}
).catch(
function (err) {
console.log(err);
var e = d.createElement('div');
e.textContent = searxng.settings.translations.error_loading_next_page;
e.classList.add('dialog-error');
e.setAttribute('role', 'alert');
replaceChildrenWith(d.querySelector('#pagination'), [ e ]);
}
)
}
if (searxng.settings.infinite_scroll && searxng.infinite_scroll_supported) {
const intersectionObserveOptions = {
rootMargin: "20rem",
};
const observedSelector = 'article.result:last-child';
const observer = new IntersectionObserver(entries => {
const paginationEntry = entries[0];
if (paginationEntry.isIntersecting) {
observer.unobserve(paginationEntry.target);
loadNextPage(() => observer.observe(d.querySelector(observedSelector), intersectionObserveOptions));
}
});
observer.observe(d.querySelector(observedSelector), intersectionObserveOptions);
}
});

View File

@@ -1,461 +0,0 @@
/* SPDX-License-Identifier: AGPL-3.0-or-later */
/* global searxng */
searxng.ready(function () {
function isElementInDetail (el) {
while (el !== undefined) {
if (el.classList.contains('detail')) {
return true;
}
if (el.classList.contains('result')) {
// we found a result, no need to go to the root of the document:
// el is not inside a <div class="detail"> element
return false;
}
el = el.parentNode;
}
return false;
}
function getResultElement (el) {
while (el !== undefined) {
if (el.classList.contains('result')) {
return el;
}
el = el.parentNode;
}
return undefined;
}
function isImageResult (resultElement) {
return resultElement && resultElement.classList.contains('result-images');
}
searxng.on('.result', 'click', function (e) {
if (!isElementInDetail(e.target)) {
highlightResult(this)(true, true);
let resultElement = getResultElement(e.target);
if (isImageResult(resultElement)) {
e.preventDefault();
searxng.selectImage(resultElement);
}
}
});
searxng.on('.result a', 'focus', function (e) {
if (!isElementInDetail(e.target)) {
let resultElement = getResultElement(e.target);
if (resultElement && resultElement.getAttribute("data-vim-selected") === null) {
highlightResult(resultElement)(true);
}
if (isImageResult(resultElement)) {
searxng.selectImage(resultElement);
}
}
}, true);
/* common base for layouts */
var baseKeyBinding = {
'Escape': {
key: 'ESC',
fun: removeFocus,
des: 'remove focus from the focused input',
cat: 'Control'
},
'c': {
key: 'c',
fun: copyURLToClipboard,
des: 'copy url of the selected result to the clipboard',
cat: 'Results'
},
'h': {
key: 'h',
fun: toggleHelp,
des: 'toggle help window',
cat: 'Other'
},
'i': {
key: 'i',
fun: searchInputFocus,
des: 'focus on the search input',
cat: 'Control'
},
'n': {
key: 'n',
fun: GoToNextPage(),
des: 'go to next page',
cat: 'Results'
},
'o': {
key: 'o',
fun: openResult(false),
des: 'open search result',
cat: 'Results'
},
'p': {
key: 'p',
fun: GoToPreviousPage(),
des: 'go to previous page',
cat: 'Results'
},
'r': {
key: 'r',
fun: reloadPage,
des: 'reload page from the server',
cat: 'Control'
},
't': {
key: 't',
fun: openResult(true),
des: 'open the result in a new tab',
cat: 'Results'
},
};
var keyBindingLayouts = {
"default": Object.assign(
{ /* SearXNG layout */
'ArrowLeft': {
key: '←',
fun: highlightResult('up'),
des: 'select previous search result',
cat: 'Results'
},
'ArrowRight': {
key: '→',
fun: highlightResult('down'),
des: 'select next search result',
cat: 'Results'
},
}, baseKeyBinding),
'vim': Object.assign(
{ /* Vim-like Key Layout. */
'b': {
key: 'b',
fun: scrollPage(-window.innerHeight),
des: 'scroll one page up',
cat: 'Navigation'
},
'f': {
key: 'f',
fun: scrollPage(window.innerHeight),
des: 'scroll one page down',
cat: 'Navigation'
},
'u': {
key: 'u',
fun: scrollPage(-window.innerHeight / 2),
des: 'scroll half a page up',
cat: 'Navigation'
},
'd': {
key: 'd',
fun: scrollPage(window.innerHeight / 2),
des: 'scroll half a page down',
cat: 'Navigation'
},
'g': {
key: 'g',
fun: scrollPageTo(-document.body.scrollHeight, 'top'),
des: 'scroll to the top of the page',
cat: 'Navigation'
},
'v': {
key: 'v',
fun: scrollPageTo(document.body.scrollHeight, 'bottom'),
des: 'scroll to the bottom of the page',
cat: 'Navigation'
},
'k': {
key: 'k',
fun: highlightResult('up'),
des: 'select previous search result',
cat: 'Results'
},
'j': {
key: 'j',
fun: highlightResult('down'),
des: 'select next search result',
cat: 'Results'
},
'y': {
key: 'y',
fun: copyURLToClipboard,
des: 'copy url of the selected result to the clipboard',
cat: 'Results'
},
}, baseKeyBinding)
}
var keyBindings = keyBindingLayouts[searxng.settings.hotkeys] || keyBindingLayouts.default;
searxng.on(document, "keydown", function (e) {
// check for modifiers so we don't break browser's hotkeys
if (
Object.prototype.hasOwnProperty.call(keyBindings, e.key)
&& !e.ctrlKey && !e.altKey
&& !e.shiftKey && !e.metaKey
) {
var tagName = e.target.tagName.toLowerCase();
if (e.key === 'Escape') {
keyBindings[e.key].fun(e);
} else {
if (e.target === document.body || tagName === 'a' || tagName === 'button') {
e.preventDefault();
keyBindings[e.key].fun();
}
}
}
});
function highlightResult (which) {
return function (noScroll, keepFocus) {
var current = document.querySelector('.result[data-vim-selected]'),
effectiveWhich = which;
if (current === null) {
// no selection : choose the first one
current = document.querySelector('.result');
if (current === null) {
// no first one : there are no results
return;
}
// replace up/down actions by selecting first one
if (which === "down" || which === "up") {
effectiveWhich = current;
}
}
var next, results = document.querySelectorAll('.result');
results = Array.from(results); // convert NodeList to Array for further use
if (typeof effectiveWhich !== 'string') {
next = effectiveWhich;
} else {
switch (effectiveWhich) {
case 'visible':
var top = document.documentElement.scrollTop || document.body.scrollTop;
var bot = top + document.documentElement.clientHeight;
for (var i = 0; i < results.length; i++) {
next = results[i];
var etop = next.offsetTop;
var ebot = etop + next.clientHeight;
if ((ebot <= bot) && (etop > top)) {
break;
}
}
break;
case 'down':
next = results[results.indexOf(current) + 1] || current;
break;
case 'up':
next = results[results.indexOf(current) - 1] || current;
break;
case 'bottom':
next = results[results.length - 1];
break;
case 'top':
/* falls through */
default:
next = results[0];
}
}
if (next) {
current.removeAttribute('data-vim-selected');
next.setAttribute('data-vim-selected', 'true');
if (!keepFocus) {
var link = next.querySelector('h3 a') || next.querySelector('a');
if (link !== null) {
link.focus();
}
}
if (!noScroll) {
scrollPageToSelected();
}
}
};
}
function reloadPage () {
document.location.reload(true);
}
function removeFocus (e) {
const tagName = e.target.tagName.toLowerCase();
if (document.activeElement && (tagName === 'input' || tagName === 'select' || tagName === 'textarea')) {
document.activeElement.blur();
} else {
searxng.closeDetail();
}
}
function pageButtonClick (css_selector) {
return function () {
var button = document.querySelector(css_selector);
if (button) {
button.click();
}
};
}
function GoToNextPage () {
return pageButtonClick('nav#pagination .next_page button[type="submit"]');
}
function GoToPreviousPage () {
return pageButtonClick('nav#pagination .previous_page button[type="submit"]');
}
function scrollPageToSelected () {
var sel = document.querySelector('.result[data-vim-selected]');
if (sel === null) {
return;
}
var wtop = document.documentElement.scrollTop || document.body.scrollTop,
wheight = document.documentElement.clientHeight,
etop = sel.offsetTop,
ebot = etop + sel.clientHeight,
offset = 120;
// first element ?
if ((sel.previousElementSibling === null) && (ebot < wheight)) {
// set to the top of page if the first element
// is fully included in the viewport
window.scroll(window.scrollX, 0);
return;
}
if (wtop > (etop - offset)) {
window.scroll(window.scrollX, etop - offset);
} else {
var wbot = wtop + wheight;
if (wbot < (ebot + offset)) {
window.scroll(window.scrollX, ebot - wheight + offset);
}
}
}
function scrollPage (amount) {
return function () {
window.scrollBy(0, amount);
highlightResult('visible')();
};
}
function scrollPageTo (position, nav) {
return function () {
window.scrollTo(0, position);
highlightResult(nav)();
};
}
function searchInputFocus () {
window.scrollTo(0, 0);
var q = document.querySelector('#q');
q.focus();
if (q.setSelectionRange) {
var len = q.value.length;
q.setSelectionRange(len, len);
}
}
function openResult (newTab) {
return function () {
var link = document.querySelector('.result[data-vim-selected] h3 a');
if (link === null) {
link = document.querySelector('.result[data-vim-selected] > a');
}
if (link !== null) {
var url = link.getAttribute('href');
if (newTab) {
window.open(url);
} else {
window.location.href = url;
}
}
};
}
function initHelpContent (divElement) {
var categories = {};
for (var k in keyBindings) {
var key = keyBindings[k];
categories[key.cat] = categories[key.cat] || [];
categories[key.cat].push(key);
}
var sorted = Object.keys(categories).sort(function (a, b) {
return categories[b].length - categories[a].length;
});
if (sorted.length === 0) {
return;
}
var html = '<a href="#" class="close" aria-label="close" title="close">×</a>';
html += '<h3>How to navigate SearXNG with hotkeys</h3>';
html += '<table>';
for (var i = 0; i < sorted.length; i++) {
var cat = categories[sorted[i]];
var lastCategory = i === (sorted.length - 1);
var first = i % 2 === 0;
if (first) {
html += '<tr>';
}
html += '<td>';
html += '<h4>' + cat[0].cat + '</h4>';
html += '<ul class="list-unstyled">';
for (var cj in cat) {
html += '<li><kbd>' + cat[cj].key + '</kbd> ' + cat[cj].des + '</li>';
}
html += '</ul>';
html += '</td>'; // col-sm-*
if (!first || lastCategory) {
html += '</tr>'; // row
}
}
html += '</table>';
divElement.innerHTML = html;
}
function toggleHelp () {
var helpPanel = document.querySelector('#vim-hotkeys-help');
if (helpPanel === undefined || helpPanel === null) {
// first call
helpPanel = document.createElement('div');
helpPanel.id = 'vim-hotkeys-help';
helpPanel.className = 'dialog-modal';
initHelpContent(helpPanel);
var body = document.getElementsByTagName('body')[0];
body.appendChild(helpPanel);
} else {
// toggle hidden
helpPanel.classList.toggle('invisible');
return;
}
}
function copyURLToClipboard () {
var currentUrlElement = document.querySelector('.result[data-vim-selected] h3 a');
if (currentUrlElement === null) return;
const url = currentUrlElement.getAttribute('href');
navigator.clipboard.writeText(url);
}
searxng.scrollPageToSelected = scrollPageToSelected;
searxng.selectNext = highlightResult('down');
searxng.selectPrevious = highlightResult('up');
});

View File

@@ -0,0 +1,488 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import { listen, mutable, settings } from "../toolkit.ts";
import { assertElement } from "../util/assertElement.ts";
export type KeyBindingLayout = "default" | "vim";
type KeyBinding = {
key: string;
fun: (event: KeyboardEvent) => void;
des: string;
cat: string;
};
type HighlightResultElement = "down" | "up" | "visible" | "bottom" | "top";
/* common base for layouts */
const baseKeyBinding: Record<string, KeyBinding> = {
Escape: {
key: "ESC",
fun: (event: KeyboardEvent) => removeFocus(event),
des: "remove focus from the focused input",
cat: "Control"
},
c: {
key: "c",
fun: () => copyURLToClipboard(),
des: "copy url of the selected result to the clipboard",
cat: "Results"
},
h: {
key: "h",
fun: () => toggleHelp(keyBindings),
des: "toggle help window",
cat: "Other"
},
i: {
key: "i",
fun: () => searchInputFocus(),
des: "focus on the search input",
cat: "Control"
},
n: {
key: "n",
fun: () => GoToNextPage(),
des: "go to next page",
cat: "Results"
},
o: {
key: "o",
fun: () => openResult(false),
des: "open search result",
cat: "Results"
},
p: {
key: "p",
fun: () => GoToPreviousPage(),
des: "go to previous page",
cat: "Results"
},
r: {
key: "r",
fun: () => reloadPage(),
des: "reload page from the server",
cat: "Control"
},
t: {
key: "t",
fun: () => openResult(true),
des: "open the result in a new tab",
cat: "Results"
}
};
const keyBindingLayouts: Record<KeyBindingLayout, Record<string, KeyBinding>> = {
// SearXNG layout
default: {
ArrowLeft: {
key: "←",
fun: () => highlightResult("up")(),
des: "select previous search result",
cat: "Results"
},
ArrowRight: {
key: "→",
fun: () => highlightResult("down")(),
des: "select next search result",
cat: "Results"
},
...baseKeyBinding
},
// Vim-like keyboard layout
vim: {
b: {
key: "b",
fun: () => scrollPage(-window.innerHeight),
des: "scroll one page up",
cat: "Navigation"
},
d: {
key: "d",
fun: () => scrollPage(window.innerHeight / 2),
des: "scroll half a page down",
cat: "Navigation"
},
f: {
key: "f",
fun: () => scrollPage(window.innerHeight),
des: "scroll one page down",
cat: "Navigation"
},
g: {
key: "g",
fun: () => scrollPageTo(-document.body.scrollHeight, "top"),
des: "scroll to the top of the page",
cat: "Navigation"
},
j: {
key: "j",
fun: () => highlightResult("down")(),
des: "select next search result",
cat: "Results"
},
k: {
key: "k",
fun: () => highlightResult("up")(),
des: "select previous search result",
cat: "Results"
},
u: {
key: "u",
fun: () => scrollPage(-window.innerHeight / 2),
des: "scroll half a page up",
cat: "Navigation"
},
v: {
key: "v",
fun: () => scrollPageTo(document.body.scrollHeight, "bottom"),
des: "scroll to the bottom of the page",
cat: "Navigation"
},
y: {
key: "y",
fun: () => copyURLToClipboard(),
des: "copy url of the selected result to the clipboard",
cat: "Results"
},
...baseKeyBinding
}
};
const keyBindings: Record<string, KeyBinding> =
settings.hotkeys && settings.hotkeys in keyBindingLayouts
? keyBindingLayouts[settings.hotkeys]
: keyBindingLayouts.default;
const isElementInDetail = (element?: HTMLElement): boolean => {
const ancestor = element?.closest(".detail, .result");
return ancestor?.classList.contains("detail") ?? false;
};
const getResultElement = (element?: HTMLElement): HTMLElement | undefined => {
return element?.closest(".result") ?? undefined;
};
const isImageResult = (resultElement?: HTMLElement): boolean => {
return resultElement?.classList.contains("result-images") ?? false;
};
const highlightResult =
(which: HighlightResultElement | HTMLElement) =>
(noScroll?: boolean, keepFocus?: boolean): void => {
let effectiveWhich = which;
let current = document.querySelector<HTMLElement>(".result[data-vim-selected]");
if (!current) {
// no selection : choose the first one
current = document.querySelector<HTMLElement>(".result");
if (!current) {
// no first one : there are no results
return;
}
// replace up/down actions by selecting first one
if (which === "down" || which === "up") {
effectiveWhich = current;
}
}
const results = Array.from(document.querySelectorAll<HTMLElement>(".result"));
let next: HTMLElement | undefined;
if (typeof effectiveWhich === "string") {
switch (effectiveWhich) {
case "visible": {
const top = document.documentElement.scrollTop || document.body.scrollTop;
const bot = top + document.documentElement.clientHeight;
for (const element of results) {
const etop = element.offsetTop;
const ebot = etop + element.clientHeight;
if (ebot <= bot && etop > top) {
next = element;
break;
}
}
break;
}
case "down":
next = results[results.indexOf(current) + 1] || current;
break;
case "up":
next = results[results.indexOf(current) - 1] || current;
break;
case "bottom":
next = results.at(-1);
break;
// biome-ignore lint/complexity/noUselessSwitchCase: fallthrough is intended
case "top":
default:
[next] = results;
}
} else {
next = effectiveWhich;
}
if (next) {
current.removeAttribute("data-vim-selected");
next.setAttribute("data-vim-selected", "true");
if (!keepFocus) {
const link = next.querySelector<HTMLAnchorElement>("h3 a") || next.querySelector<HTMLAnchorElement>("a");
link?.focus();
}
if (!noScroll) {
mutable.scrollPageToSelected?.();
}
}
};
const reloadPage = (): void => {
document.location.reload();
};
const removeFocus = (event: KeyboardEvent): void => {
const target = event.target as HTMLElement;
const tagName = target?.tagName?.toLowerCase();
if (document.activeElement && (tagName === "input" || tagName === "select" || tagName === "textarea")) {
(document.activeElement as HTMLElement).blur();
} else {
mutable.closeDetail?.();
}
};
const pageButtonClick = (css_selector: string): void => {
const button = document.querySelector<HTMLButtonElement>(css_selector);
if (button) {
button.click();
}
};
const GoToNextPage = (): void => {
pageButtonClick('nav#pagination .next_page button[type="submit"]');
};
const GoToPreviousPage = (): void => {
pageButtonClick('nav#pagination .previous_page button[type="submit"]');
};
mutable.scrollPageToSelected = (): void => {
const sel = document.querySelector<HTMLElement>(".result[data-vim-selected]");
if (!sel) return;
const wtop = document.documentElement.scrollTop || document.body.scrollTop;
const height = document.documentElement.clientHeight;
const etop = sel.offsetTop;
const ebot = etop + sel.clientHeight;
const offset = 120;
// first element ?
if (!sel.previousElementSibling && ebot < height) {
// set to the top of page if the first element
// is fully included in the viewport
window.scroll(window.scrollX, 0);
return;
}
if (wtop > etop - offset) {
window.scroll(window.scrollX, etop - offset);
} else {
const wbot = wtop + height;
if (wbot < ebot + offset) {
window.scroll(window.scrollX, ebot - height + offset);
}
}
};
const scrollPage = (amount: number): void => {
window.scrollBy(0, amount);
highlightResult("visible")();
};
const scrollPageTo = (position: number, nav: HighlightResultElement): void => {
window.scrollTo(0, position);
highlightResult(nav)();
};
const searchInputFocus = (): void => {
window.scrollTo(0, 0);
const q = document.querySelector<HTMLInputElement>("#q");
if (q) {
q.focus();
if (q.setSelectionRange) {
const len = q.value.length;
q.setSelectionRange(len, len);
}
}
};
const openResult = (newTab: boolean): void => {
let link = document.querySelector<HTMLAnchorElement>(".result[data-vim-selected] h3 a");
if (!link) {
link = document.querySelector<HTMLAnchorElement>(".result[data-vim-selected] > a");
}
if (!link) return;
const url = link.getAttribute("href");
if (url) {
if (newTab) {
window.open(url);
} else {
window.location.href = url;
}
}
};
const initHelpContent = (divElement: HTMLElement, keyBindings: typeof baseKeyBinding): void => {
const categories: Record<string, KeyBinding[]> = {};
for (const binding of Object.values(keyBindings)) {
const { cat } = binding;
categories[cat] ??= [];
categories[cat].push(binding);
}
const sortedCategoryKeys = Object.keys(categories).sort(
(a, b) => (categories[b]?.length ?? 0) - (categories[a]?.length ?? 0)
);
let html = '<a href="#" class="close" aria-label="close" title="close">×</a>';
html += "<h3>How to navigate SearXNG with hotkeys</h3>";
html += "<table>";
for (const [i, categoryKey] of sortedCategoryKeys.entries()) {
const bindings = categories[categoryKey];
if (!bindings || bindings.length === 0) continue;
const isFirst = i % 2 === 0;
const isLast = i === sortedCategoryKeys.length - 1;
if (isFirst) {
html += "<tr>";
}
html += "<td>";
html += `<h4>${categoryKey}</h4>`;
html += '<ul class="list-unstyled">';
for (const binding of bindings) {
html += `<li><kbd>${binding.key}</kbd> ${binding.des}</li>`;
}
html += "</ul>";
html += "</td>";
if (!isFirst || isLast) {
html += "</tr>";
}
}
html += "</table>";
divElement.innerHTML = html;
};
const toggleHelp = (keyBindings: typeof baseKeyBinding): void => {
let helpPanel = document.querySelector<HTMLElement>("#vim-hotkeys-help");
if (helpPanel) {
// toggle hidden
helpPanel.classList.toggle("invisible");
} else {
// first call
helpPanel = Object.assign(document.createElement("div"), {
id: "vim-hotkeys-help",
className: "dialog-modal"
});
initHelpContent(helpPanel, keyBindings);
const [body] = document.getElementsByTagName("body");
if (body) {
body.appendChild(helpPanel);
}
}
};
const copyURLToClipboard = async (): Promise<void> => {
const selectedResult = document.querySelector<HTMLElement>(".result[data-vim-selected]");
if (!selectedResult) return;
const resultAnchor = selectedResult.querySelector<HTMLAnchorElement>("a");
assertElement(resultAnchor);
const url = resultAnchor.getAttribute("href");
if (url) {
if (window.isSecureContext) {
await navigator.clipboard.writeText(url);
} else {
const selection = window.getSelection();
if (selection) {
const node = document.createElement("span");
node.textContent = url;
resultAnchor.appendChild(node);
const range = document.createRange();
range.selectNodeContents(node);
selection.removeAllRanges();
selection.addRange(range);
document.execCommand("copy");
node.remove();
}
}
}
};
listen("click", ".result", function (this: HTMLElement, event: PointerEvent) {
if (!isElementInDetail(event.target as HTMLElement)) {
highlightResult(this)(true, true);
const resultElement = getResultElement(event.target as HTMLElement);
if (resultElement && isImageResult(resultElement)) {
event.preventDefault();
mutable.selectImage?.(resultElement);
}
}
});
// FIXME: Focus might also trigger Pointer event ^^^
listen(
"focus",
".result a",
(event: FocusEvent) => {
if (!isElementInDetail(event.target as HTMLElement)) {
const resultElement = getResultElement(event.target as HTMLElement);
if (resultElement && !resultElement.hasAttribute("data-vim-selected")) {
highlightResult(resultElement)(true);
}
if (resultElement && isImageResult(resultElement)) {
event.preventDefault();
mutable.selectImage?.(resultElement);
}
}
},
{ capture: true }
);
listen("keydown", document, (event: KeyboardEvent) => {
// check for modifiers so we don't break browser's hotkeys
if (Object.hasOwn(keyBindings, event.key) && !event.ctrlKey && !event.altKey && !event.shiftKey && !event.metaKey) {
const tagName = (event.target as HTMLElement)?.tagName?.toLowerCase();
if (event.key === "Escape") {
keyBindings[event.key]?.fun(event);
} else if (event.target === document.body || tagName === "a" || tagName === "button") {
event.preventDefault();
keyBindings[event.key]?.fun(event);
}
}
});
mutable.selectNext = highlightResult("down");
mutable.selectPrevious = highlightResult("up");

View File

@@ -1,74 +0,0 @@
/* SPDX-License-Identifier: AGPL-3.0-or-later */
/* global L */
(function (w, d, searxng) {
'use strict';
searxng.ready(function () {
searxng.on('.searxng_init_map', 'click', function (event) {
// no more request
this.classList.remove("searxng_init_map");
//
var leaflet_target = this.dataset.leafletTarget;
var map_lon = parseFloat(this.dataset.mapLon);
var map_lat = parseFloat(this.dataset.mapLat);
var map_zoom = parseFloat(this.dataset.mapZoom);
var map_boundingbox = JSON.parse(this.dataset.mapBoundingbox);
var map_geojson = JSON.parse(this.dataset.mapGeojson);
searxng.loadStyle('css/leaflet.css');
searxng.loadScript('js/leaflet.js', function () {
var map_bounds = null;
if (map_boundingbox) {
var southWest = L.latLng(map_boundingbox[0], map_boundingbox[2]);
var northEast = L.latLng(map_boundingbox[1], map_boundingbox[3]);
map_bounds = L.latLngBounds(southWest, northEast);
}
// init map
var map = L.map(leaflet_target);
// create the tile layer with correct attribution
var osmMapnikUrl = 'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png';
var osmMapnikAttrib = 'Map data © <a href="https://openstreetmap.org">OpenStreetMap</a> contributors';
var osmMapnik = new L.TileLayer(osmMapnikUrl, {minZoom: 1, maxZoom: 19, attribution: osmMapnikAttrib});
var osmWikimediaUrl = 'https://maps.wikimedia.org/osm-intl/{z}/{x}/{y}.png';
var osmWikimediaAttrib = 'Wikimedia maps | Maps data © <a href="https://openstreetmap.org">OpenStreetMap contributors</a>';
var osmWikimedia = new L.TileLayer(osmWikimediaUrl, {minZoom: 1, maxZoom: 19, attribution: osmWikimediaAttrib});
// init map view
if (map_bounds) {
// TODO hack: https://github.com/Leaflet/Leaflet/issues/2021
// Still useful ?
setTimeout(function () {
map.fitBounds(map_bounds, {
maxZoom: 17
});
}, 0);
} else if (map_lon && map_lat) {
if (map_zoom) {
map.setView(new L.latLng(map_lat, map_lon), map_zoom);
} else {
map.setView(new L.latLng(map_lat, map_lon), 8);
}
}
map.addLayer(osmMapnik);
var baseLayers = {
"OSM Mapnik": osmMapnik,
"OSM Wikimedia": osmWikimedia,
};
L.control.layers(baseLayers).addTo(map);
if (map_geojson) {
L.geoJson(map_geojson).addTo(map);
} /* else if(map_bounds) {
L.rectangle(map_bounds, {color: "#ff7800", weight: 3, fill:false}).addTo(map);
} */
});
// this event occur only once per element
event.preventDefault();
});
});
})(window, document, window.searxng);

View File

@@ -1,53 +0,0 @@
/* SPDX-License-Identifier: AGPL-3.0-or-later */
(function (w, d, searxng) {
'use strict';
if (searxng.endpoint !== 'preferences') {
return;
}
searxng.ready(function () {
let engine_descriptions = null;
function load_engine_descriptions () {
if (engine_descriptions == null) {
searxng.http("GET", "engine_descriptions.json").then(function (content) {
engine_descriptions = JSON.parse(content);
for (const [engine_name, description] of Object.entries(engine_descriptions)) {
let elements = d.querySelectorAll('[data-engine-name="' + engine_name + '"] .engine-description');
for (const element of elements) {
let source = ' (<i>' + searxng.settings.translations.Source + ':&nbsp;' + description[1] + '</i>)';
element.innerHTML = description[0] + source;
}
}
});
}
}
for (const el of d.querySelectorAll('[data-engine-name]')) {
searxng.on(el, 'mouseenter', load_engine_descriptions);
}
const enableAllEngines = d.querySelectorAll(".enable-all-engines");
const disableAllEngines = d.querySelectorAll(".disable-all-engines");
const engineToggles = d.querySelectorAll('tbody input[type=checkbox][class~=checkbox-onoff]');
const toggleEngines = (enable) => {
for (const el of engineToggles) {
// check if element visible, so that only engines of the current category are modified
if (el.offsetParent !== null) el.checked = !enable;
}
};
for (const el of enableAllEngines) {
searxng.on(el, 'click', () => toggleEngines(true));
}
for (const el of disableAllEngines) {
searxng.on(el, 'click', () => toggleEngines(false));
}
const copyHashButton = d.querySelector("#copy-hash");
searxng.on(copyHashButton, 'click', (e) => {
e.preventDefault();
navigator.clipboard.writeText(copyHashButton.dataset.hash);
copyHashButton.innerText = copyHashButton.dataset.copiedText;
});
});
})(window, document, window.searxng);

View File

@@ -0,0 +1,76 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import { http, listen, settings } from "../toolkit.ts";
import { assertElement } from "../util/assertElement.ts";
let engineDescriptions: Record<string, [string, string]> | undefined;
const loadEngineDescriptions = async (): Promise<void> => {
if (engineDescriptions) return;
try {
const res = await http("GET", "engine_descriptions.json");
engineDescriptions = await res.json();
} catch (error) {
console.error("Error fetching engineDescriptions:", error);
}
if (!engineDescriptions) return;
for (const [engine_name, [description, source]] of Object.entries(engineDescriptions)) {
const elements = document.querySelectorAll<HTMLElement>(`[data-engine-name="${engine_name}"] .engine-description`);
const sourceText = ` (<i>${settings.translations?.Source}:&nbsp;${source}</i>)`;
for (const element of elements) {
element.innerHTML = description + sourceText;
}
}
};
const toggleEngines = (enable: boolean, engineToggles: NodeListOf<HTMLInputElement>): void => {
for (const engineToggle of engineToggles) {
// check if element visible, so that only engines of the current category are modified
if (engineToggle.offsetParent) {
engineToggle.checked = !enable;
}
}
};
const engineElements: NodeListOf<HTMLElement> = document.querySelectorAll<HTMLElement>("[data-engine-name]");
for (const engineElement of engineElements) {
listen("mouseenter", engineElement, loadEngineDescriptions);
}
const engineToggles: NodeListOf<HTMLInputElement> = document.querySelectorAll<HTMLInputElement>(
"tbody input[type=checkbox][class~=checkbox-onoff]"
);
const enableAllEngines: NodeListOf<HTMLElement> = document.querySelectorAll<HTMLElement>(".enable-all-engines");
for (const engine of enableAllEngines) {
listen("click", engine, () => toggleEngines(true, engineToggles));
}
const disableAllEngines: NodeListOf<HTMLElement> = document.querySelectorAll<HTMLElement>(".disable-all-engines");
for (const engine of disableAllEngines) {
listen("click", engine, () => toggleEngines(false, engineToggles));
}
listen("click", "#copy-hash", async function (this: HTMLElement) {
const target = this.parentElement?.querySelector<HTMLPreElement>("pre");
assertElement(target);
if (window.isSecureContext) {
await navigator.clipboard.writeText(target.innerText);
} else {
const selection = window.getSelection();
if (selection) {
const range = document.createRange();
range.selectNodeContents(target);
selection.removeAllRanges();
selection.addRange(range);
document.execCommand("copy");
}
}
if (this.dataset.copiedText) {
this.innerText = this.dataset.copiedText;
}
});

View File

@@ -1,184 +0,0 @@
/* SPDX-License-Identifier: AGPL-3.0-or-later */
import "../../../node_modules/swiped-events/src/swiped-events.js";
(function (w, d, searxng) {
'use strict';
if (searxng.endpoint !== 'results') {
return;
}
searxng.ready(function () {
d.querySelectorAll('#urls img').forEach(
img =>
img.addEventListener(
'error', () => {
// console.log("ERROR can't load: " + img.src);
img.src = window.searxng.settings.theme_static_path + "/img/img_load_error.svg";
},
{once: true}
));
if (d.querySelector('#search_url button#copy_url')) {
d.querySelector('#search_url button#copy_url').style.display = "block";
}
searxng.on('.btn-collapse', 'click', function () {
var btnLabelCollapsed = this.getAttribute('data-btn-text-collapsed');
var btnLabelNotCollapsed = this.getAttribute('data-btn-text-not-collapsed');
var target = this.getAttribute('data-target');
var targetElement = d.querySelector(target);
var html = this.innerHTML;
if (this.classList.contains('collapsed')) {
html = html.replace(btnLabelCollapsed, btnLabelNotCollapsed);
} else {
html = html.replace(btnLabelNotCollapsed, btnLabelCollapsed);
}
this.innerHTML = html;
this.classList.toggle('collapsed');
targetElement.classList.toggle('invisible');
});
searxng.on('.media-loader', 'click', function () {
var target = this.getAttribute('data-target');
var iframe_load = d.querySelector(target + ' > iframe');
var srctest = iframe_load.getAttribute('src');
if (srctest === null || srctest === undefined || srctest === false) {
iframe_load.setAttribute('src', iframe_load.getAttribute('data-src'));
}
});
searxng.on('#copy_url', 'click', function () {
var target = this.parentElement.querySelector('pre');
navigator.clipboard.writeText(target.innerText);
this.innerText = this.dataset.copiedText;
});
// searxng.selectImage (gallery)
// -----------------------------
// setTimeout() ID, needed to cancel *last* loadImage
let imgTimeoutID;
// progress spinner, while an image is loading
const imgLoaderSpinner = d.createElement('div');
imgLoaderSpinner.classList.add('loader');
// singleton image object, which is used for all loading processes of a
// detailed image
const imgLoader = new Image();
const loadImage = (imgSrc, onSuccess) => {
// if defered image load exists, stop defered task.
if (imgTimeoutID) clearTimeout(imgTimeoutID);
// defer load of the detail image for 1 sec
imgTimeoutID = setTimeout(() => {
imgLoader.src = imgSrc;
}, 1000);
// set handlers in the on-properties
imgLoader.onload = () => {
onSuccess();
imgLoaderSpinner.remove();
};
imgLoader.onerror = () => {
imgLoaderSpinner.remove();
};
};
searxng.selectImage = (resultElement) => {
// add a class that can be evaluated in the CSS and indicates that the
// detail view is open
d.getElementById('results').classList.add('image-detail-open');
// add a hash to the browser history so that pressing back doesn't return
// to the previous page this allows us to dismiss the image details on
// pressing the back button on mobile devices
window.location.hash = '#image-viewer';
searxng.scrollPageToSelected();
// if there is none element given by the caller, stop here
if (!resultElement) return;
// find <img> object in the element, if there is none, stop here.
const img = resultElement.querySelector('.result-images-source img');
if (!img) return;
// <img src="" data-src="http://example.org/image.jpg">
const src = img.getAttribute('data-src');
// already loaded high-res image or no high-res image available
if (!src) return;
// use the image thumbnail until the image is fully loaded
const thumbnail = resultElement.querySelector('.image_thumbnail');
img.src = thumbnail.src;
// show a progress spinner
const detailElement = resultElement.querySelector('.detail');
detailElement.appendChild(imgLoaderSpinner);
// load full size image in background
loadImage(src, () => {
// after the singelton loadImage has loaded the detail image into the
// cache, it can be used in the origin <img> as src property.
img.src = src;
img.removeAttribute('data-src');
});
};
searxng.closeDetail = function () {
d.getElementById('results').classList.remove('image-detail-open');
// remove #image-viewer hash from url by navigating back
if (window.location.hash == '#image-viewer') window.history.back();
searxng.scrollPageToSelected();
};
searxng.on('.result-detail-close', 'click', e => {
e.preventDefault();
searxng.closeDetail();
});
searxng.on('.result-detail-previous', 'click', e => {
e.preventDefault();
searxng.selectPrevious(false);
});
searxng.on('.result-detail-next', 'click', e => {
e.preventDefault();
searxng.selectNext(false);
});
// listen for the back button to be pressed and dismiss the image details when called
window.addEventListener('hashchange', () => {
if (window.location.hash != '#image-viewer') searxng.closeDetail();
});
d.querySelectorAll('.swipe-horizontal').forEach(
obj => {
obj.addEventListener('swiped-left', function () {
searxng.selectNext(false);
});
obj.addEventListener('swiped-right', function () {
searxng.selectPrevious(false);
});
}
);
w.addEventListener('scroll', function () {
var e = d.getElementById('backToTop'),
scrollTop = document.documentElement.scrollTop || document.body.scrollTop,
results = d.getElementById('results');
if (e !== null) {
if (scrollTop >= 100) {
results.classList.add('scrolling');
} else {
results.classList.remove('scrolling');
}
}
}, true);
});
})(window, document, window.searxng);

View File

@@ -0,0 +1,189 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import "../../../node_modules/swiped-events/src/swiped-events.js";
import { listen, mutable, settings } from "../toolkit.ts";
import { assertElement } from "../util/assertElement.ts";
let imgTimeoutID: number;
const imageLoader = (resultElement: HTMLElement): void => {
if (imgTimeoutID) clearTimeout(imgTimeoutID);
const imgElement = resultElement.querySelector<HTMLImageElement>(".result-images-source img");
if (!imgElement) return;
// use thumbnail until full image loads
const thumbnail = resultElement.querySelector<HTMLImageElement>(".image_thumbnail");
if (thumbnail) {
if (thumbnail.src === `${settings.theme_static_path}/img/img_load_error.svg`) return;
imgElement.onerror = (): void => {
imgElement.src = thumbnail.src;
};
imgElement.src = thumbnail.src;
}
const imgSource = imgElement.getAttribute("data-src");
if (!imgSource) return;
// unsafe nodejs specific, cast to https://developer.mozilla.org/en-US/docs/Web/API/Window/setTimeout#return_value
// https://github.com/searxng/searxng/pull/5073#discussion_r2265767231
imgTimeoutID = setTimeout(() => {
imgElement.src = imgSource;
imgElement.removeAttribute("data-src");
}, 1000) as unknown as number;
};
const imageThumbnails: NodeListOf<HTMLImageElement> =
document.querySelectorAll<HTMLImageElement>("#urls img.image_thumbnail");
for (const thumbnail of imageThumbnails) {
if (thumbnail.complete && thumbnail.naturalWidth === 0) {
thumbnail.src = `${settings.theme_static_path}/img/img_load_error.svg`;
}
thumbnail.onerror = (): void => {
thumbnail.src = `${settings.theme_static_path}/img/img_load_error.svg`;
};
}
const copyUrlButton: HTMLButtonElement | null =
document.querySelector<HTMLButtonElement>("#search_url button#copy_url");
copyUrlButton?.style.setProperty("display", "block");
mutable.selectImage = (resultElement: HTMLElement): void => {
// add a class that can be evaluated in the CSS and indicates that the
// detail view is open
const resultsElement = document.getElementById("results");
resultsElement?.classList.add("image-detail-open");
// add a hash to the browser history so that pressing back doesn't return
// to the previous page this allows us to dismiss the image details on
// pressing the back button on mobile devices
window.location.hash = "#image-viewer";
mutable.scrollPageToSelected?.();
// if there is no element given by the caller, stop here
if (!resultElement) return;
imageLoader(resultElement);
};
mutable.closeDetail = (): void => {
const resultsElement = document.getElementById("results");
resultsElement?.classList.remove("image-detail-open");
// remove #image-viewer hash from url by navigating back
if (window.location.hash === "#image-viewer") {
window.history.back();
}
mutable.scrollPageToSelected?.();
};
listen("click", ".btn-collapse", function (this: HTMLElement) {
const btnLabelCollapsed = this.getAttribute("data-btn-text-collapsed");
const btnLabelNotCollapsed = this.getAttribute("data-btn-text-not-collapsed");
const target = this.getAttribute("data-target");
if (!(target && btnLabelCollapsed && btnLabelNotCollapsed)) return;
const targetElement = document.querySelector<HTMLElement>(target);
assertElement(targetElement);
const isCollapsed = this.classList.contains("collapsed");
const newLabel = isCollapsed ? btnLabelNotCollapsed : btnLabelCollapsed;
const oldLabel = isCollapsed ? btnLabelCollapsed : btnLabelNotCollapsed;
this.innerHTML = this.innerHTML.replace(oldLabel, newLabel);
this.classList.toggle("collapsed");
targetElement.classList.toggle("invisible");
});
listen("click", ".media-loader", function (this: HTMLElement) {
const target = this.getAttribute("data-target");
if (!target) return;
const iframeLoad = document.querySelector<HTMLIFrameElement>(`${target} > iframe`);
assertElement(iframeLoad);
const srctest = iframeLoad.getAttribute("src");
if (!srctest) {
const dataSrc = iframeLoad.getAttribute("data-src");
if (dataSrc) {
iframeLoad.setAttribute("src", dataSrc);
}
}
});
listen("click", "#copy_url", async function (this: HTMLElement) {
const target = this.parentElement?.querySelector<HTMLPreElement>("pre");
assertElement(target);
if (window.isSecureContext) {
await navigator.clipboard.writeText(target.innerText);
} else {
const selection = window.getSelection();
if (selection) {
const range = document.createRange();
range.selectNodeContents(target);
selection.removeAllRanges();
selection.addRange(range);
document.execCommand("copy");
}
}
if (this.dataset.copiedText) {
this.innerText = this.dataset.copiedText;
}
});
listen("click", ".result-detail-close", (event: Event) => {
event.preventDefault();
mutable.closeDetail?.();
});
listen("click", ".result-detail-previous", (event: Event) => {
event.preventDefault();
mutable.selectPrevious?.(false);
});
listen("click", ".result-detail-next", (event: Event) => {
event.preventDefault();
mutable.selectNext?.(false);
});
// listen for the back button to be pressed and dismiss the image details when called
window.addEventListener("hashchange", () => {
if (window.location.hash !== "#image-viewer") {
mutable.closeDetail?.();
}
});
const swipeHorizontal: NodeListOf<HTMLElement> = document.querySelectorAll<HTMLElement>(".swipe-horizontal");
for (const element of swipeHorizontal) {
listen("swiped-left", element, () => {
mutable.selectNext?.(false);
});
listen("swiped-right", element, () => {
mutable.selectPrevious?.(false);
});
}
window.addEventListener(
"scroll",
() => {
const backToTopElement = document.getElementById("backToTop");
const resultsElement = document.getElementById("results");
if (backToTopElement && resultsElement) {
const scrollTop = document.documentElement.scrollTop || document.body.scrollTop;
const isScrolling = scrollTop >= 100;
resultsElement.classList.toggle("scrolling", isScrolling);
}
},
true
);

View File

@@ -1,210 +0,0 @@
/* SPDX-License-Identifier: AGPL-3.0-or-later */
/* exported AutoComplete */
import AutoComplete from "../../../node_modules/autocomplete-js/dist/autocomplete.js";
(function (w, d, searxng) {
'use strict';
var qinput_id = "q", qinput;
const isMobile = window.matchMedia("only screen and (max-width: 50em)").matches;
function submitIfQuery () {
if (qinput.value.length > 0) {
var search = document.getElementById('search');
setTimeout(search.submit.bind(search), 0);
}
}
function createClearButton (qinput) {
var cs = document.getElementById('clear_search');
var updateClearButton = function () {
if (qinput.value.length === 0) {
cs.classList.add("empty");
} else {
cs.classList.remove("empty");
}
};
// update status, event listener
updateClearButton();
cs.addEventListener('click', function (ev) {
qinput.value = '';
qinput.focus();
updateClearButton();
ev.preventDefault();
});
qinput.addEventListener('input', updateClearButton, false);
}
searxng.ready(function () {
qinput = d.getElementById(qinput_id);
if (qinput !== null) {
// clear button
createClearButton(qinput);
// autocompleter
if (searxng.settings.autocomplete) {
searxng.autocomplete = AutoComplete.call(w, {
Url: "./autocompleter",
EmptyMessage: searxng.settings.translations.no_item_found,
HttpMethod: searxng.settings.method,
HttpHeaders: {
"Content-type": "application/x-www-form-urlencoded",
"X-Requested-With": "XMLHttpRequest"
},
MinChars: searxng.settings.autocomplete_min,
Delay: 300,
_Position: function () {},
_Open: function () {
var params = this;
Array.prototype.forEach.call(this.DOMResults.getElementsByTagName("li"), function (li) {
if (li.getAttribute("class") != "locked") {
li.onmousedown = function () {
params._Select(li);
};
}
});
},
_Select: function (item) {
AutoComplete.defaults._Select.call(this, item);
var form = item.closest('form');
if (form) {
form.submit();
}
},
_MinChars: function () {
if (this.Input.value.indexOf('!') > -1) {
return 0;
} else {
return AutoComplete.defaults._MinChars.call(this);
}
},
KeyboardMappings: Object.assign({}, AutoComplete.defaults.KeyboardMappings, {
"KeyUpAndDown_up": Object.assign({}, AutoComplete.defaults.KeyboardMappings.KeyUpAndDown_up, {
Callback: function (event) {
AutoComplete.defaults.KeyboardMappings.KeyUpAndDown_up.Callback.call(this, event);
var liActive = this.DOMResults.querySelector("li.active");
if (liActive) {
AutoComplete.defaults._Select.call(this, liActive);
}
},
}),
"Tab": Object.assign({}, AutoComplete.defaults.KeyboardMappings.Enter, {
Conditions: [{
Is: 9,
Not: false
}],
Callback: function (event) {
if (this.DOMResults.getAttribute("class").indexOf("open") != -1) {
var liActive = this.DOMResults.querySelector("li.active");
if (liActive !== null) {
AutoComplete.defaults._Select.call(this, liActive);
event.preventDefault();
}
}
},
})
}),
}, "#" + qinput_id);
}
/*
Monkey patch autocomplete.js to fix a bug
With the POST method, the values are not URL encoded: query like "1 + 1" are sent as "1 1" since space are URL encoded as plus.
See HTML specifications:
* HTML5: https://url.spec.whatwg.org/#concept-urlencoded-serializer
* HTML4: https://www.w3.org/TR/html401/interact/forms.html#h-17.13.4.1
autocomplete.js does not URL encode the name and values:
https://github.com/autocompletejs/autocomplete.js/blob/87069524f3b95e68f1b54d8976868e0eac1b2c83/src/autocomplete.ts#L665
The monkey patch overrides the compiled version of the ajax function.
See https://github.com/autocompletejs/autocomplete.js/blob/87069524f3b95e68f1b54d8976868e0eac1b2c83/dist/autocomplete.js#L143-L158
The patch changes only the line 156 from
params.Request.send(params._QueryArg() + "=" + params._Pre());
to
params.Request.send(encodeURIComponent(params._QueryArg()) + "=" + encodeURIComponent(params._Pre()));
Related to:
* https://github.com/autocompletejs/autocomplete.js/issues/78
* https://github.com/searxng/searxng/issues/1695
*/
AutoComplete.prototype.ajax = function (params, request, timeout) {
if (timeout === void 0) { timeout = true; }
if (params.$AjaxTimer) {
window.clearTimeout(params.$AjaxTimer);
}
if (timeout === true) {
params.$AjaxTimer = window.setTimeout(AutoComplete.prototype.ajax.bind(null, params, request, false), params.Delay);
} else {
if (params.Request) {
params.Request.abort();
}
params.Request = request;
params.Request.send(encodeURIComponent(params._QueryArg()) + "=" + encodeURIComponent(params._Pre()));
}
};
if (!isMobile && document.querySelector('.index_endpoint')) {
qinput.focus();
}
}
// Additionally to searching when selecting a new category, we also
// automatically start a new search request when the user changes a search
// filter (safesearch, time range or language) (this requires JavaScript
// though)
if (
qinput !== null
&& searxng.settings.search_on_category_select
// If .search_filters is undefined (invisible) we are on the homepage and
// hence don't have to set any listeners
&& d.querySelector(".search_filters") != null
) {
searxng.on(d.getElementById('safesearch'), 'change', submitIfQuery);
searxng.on(d.getElementById('time_range'), 'change', submitIfQuery);
searxng.on(d.getElementById('language'), 'change', submitIfQuery);
}
const categoryButtons = d.querySelectorAll("button.category_button");
for (let button of categoryButtons) {
searxng.on(button, 'click', (event) => {
if (event.shiftKey) {
event.preventDefault();
button.classList.toggle("selected");
return;
}
// manually deselect the old selection when a new category is selected
const selectedCategories = d.querySelectorAll("button.category_button.selected");
for (let categoryButton of selectedCategories) {
categoryButton.classList.remove("selected");
}
button.classList.add("selected");
})
}
// override form submit action to update the actually selected categories
const form = d.querySelector("#search");
if (form != null) {
searxng.on(form, 'submit', (event) => {
event.preventDefault();
const categoryValuesInput = d.querySelector("#selected-categories");
if (categoryValuesInput) {
let categoryValues = [];
for (let categoryButton of categoryButtons) {
if (categoryButton.classList.contains("selected")) {
categoryValues.push(categoryButton.name.replace("category_", ""));
}
}
categoryValuesInput.value = categoryValues.join(",");
}
form.submit();
});
}
});
})(window, document, window.searxng);

View File

@@ -0,0 +1,94 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import { listen } from "../toolkit.ts";
import { getElement } from "../util/getElement.ts";
const searchForm: HTMLFormElement = getElement<HTMLFormElement>("search");
const searchInput: HTMLInputElement = getElement<HTMLInputElement>("q");
const searchReset: HTMLButtonElement = getElement<HTMLButtonElement>("clear_search");
const isMobile: boolean = window.matchMedia("(max-width: 50em)").matches;
const isResultsPage: boolean = document.querySelector("main")?.id === "main_results";
const categoryButtons: HTMLButtonElement[] = Array.from(
document.querySelectorAll<HTMLButtonElement>("#categories_container button.category")
);
if (searchInput.value.length === 0) {
searchReset.classList.add("empty");
}
// focus search input on large screens
if (!(isMobile || isResultsPage)) {
searchInput.focus();
}
// On mobile, move cursor to the end of the input on focus
if (isMobile) {
listen("focus", searchInput, () => {
// Defer cursor move until the next frame to prevent a visual jump
requestAnimationFrame(() => {
const end = searchInput.value.length;
searchInput.setSelectionRange(end, end);
searchInput.scrollLeft = searchInput.scrollWidth;
});
});
}
listen("input", searchInput, () => {
searchReset.classList.toggle("empty", searchInput.value.length === 0);
});
listen("click", searchReset, (event: MouseEvent) => {
event.preventDefault();
searchInput.value = "";
searchInput.focus();
searchReset.classList.add("empty");
});
for (const button of categoryButtons) {
listen("click", button, (event: MouseEvent) => {
if (event.shiftKey) {
event.preventDefault();
button.classList.toggle("selected");
return;
}
// deselect all other categories
for (const categoryButton of categoryButtons) {
categoryButton.classList.toggle("selected", categoryButton === button);
}
});
}
if (document.querySelector("div.search_filters")) {
const safesearchElement = document.getElementById("safesearch");
if (safesearchElement) {
listen("change", safesearchElement, () => searchForm.submit());
}
const timeRangeElement = document.getElementById("time_range");
if (timeRangeElement) {
listen("change", timeRangeElement, () => searchForm.submit());
}
const languageElement = document.getElementById("language");
if (languageElement) {
listen("change", languageElement, () => searchForm.submit());
}
}
// override searchForm submit event
listen("submit", searchForm, (event: Event) => {
event.preventDefault();
if (categoryButtons.length > 0) {
const searchCategories = getElement<HTMLInputElement>("selected-categories");
searchCategories.value = categoryButtons
.filter((button) => button.classList.contains("selected"))
.map((button) => button.name.replace("category_", ""))
.join(",");
}
searchForm.submit();
});

View File

@@ -0,0 +1,93 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import {
absDependencies,
addDependencies,
create,
divideDependencies,
eDependencies,
evaluateDependencies,
expDependencies,
factorialDependencies,
gcdDependencies,
lcmDependencies,
log1pDependencies,
log2Dependencies,
log10Dependencies,
logDependencies,
modDependencies,
multiplyDependencies,
nthRootDependencies,
piDependencies,
powDependencies,
roundDependencies,
signDependencies,
sqrtDependencies,
subtractDependencies
} from "mathjs/number";
import { Plugin } from "../Plugin.ts";
import { appendAnswerElement } from "../util/appendAnswerElement.ts";
import { getElement } from "../util/getElement.ts";
/**
* Parses and solves mathematical expressions. Can do basic arithmetic and
* evaluate some functions.
*
* @example
* "(3 + 5) / 2" = "4"
* "e ^ 2 + pi" = "10.530648752520442"
* "gcd(48, 18) + lcm(4, 5)" = "26"
*
* @remarks
* Depends on `mathjs` library.
*/
export default class Calculator extends Plugin {
public constructor() {
super("calculator");
}
/**
* @remarks
* Compare bundle size after adding or removing features.
*/
private static readonly math = create({
...absDependencies,
...addDependencies,
...divideDependencies,
...eDependencies,
...evaluateDependencies,
...expDependencies,
...factorialDependencies,
...gcdDependencies,
...lcmDependencies,
...log10Dependencies,
...log1pDependencies,
...log2Dependencies,
...logDependencies,
...modDependencies,
...multiplyDependencies,
...nthRootDependencies,
...piDependencies,
...powDependencies,
...roundDependencies,
...signDependencies,
...sqrtDependencies,
...subtractDependencies
});
protected async run(): Promise<string | undefined> {
const searchInput = getElement<HTMLInputElement>("q");
const node = Calculator.math.parse(searchInput.value);
try {
return `${node.toString()} = ${node.evaluate()}`;
} catch {
// not a compatible math expression
return;
}
}
protected async post(result: string): Promise<void> {
appendAnswerElement(result);
}
}

View File

@@ -0,0 +1,110 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import { Plugin } from "../Plugin.ts";
import { http, settings } from "../toolkit.ts";
import { assertElement } from "../util/assertElement.ts";
import { getElement } from "../util/getElement.ts";
/**
* Automatically loads the next page when scrolling to bottom of the current page.
*/
export default class InfiniteScroll extends Plugin {
public constructor() {
super("infiniteScroll");
}
protected async run(): Promise<void> {
const resultsElement = getElement<HTMLElement>("results");
const onlyImages: boolean = resultsElement.classList.contains("only_template_images");
const observedSelector = "article.result:last-child";
const spinnerElement = document.createElement("div");
spinnerElement.className = "loader";
const loadNextPage = async (callback: () => void): Promise<void> => {
const searchForm = document.querySelector<HTMLFormElement>("#search");
assertElement(searchForm);
const form = document.querySelector<HTMLFormElement>("#pagination form.next_page");
assertElement(form);
const action = searchForm.getAttribute("action");
if (!action) {
throw new Error("Form action not defined");
}
const paginationElement = document.querySelector<HTMLElement>("#pagination");
assertElement(paginationElement);
paginationElement.replaceChildren(spinnerElement);
try {
const res = await http("POST", action, { body: new FormData(form) });
const nextPage = await res.text();
if (!nextPage) return;
const nextPageDoc = new DOMParser().parseFromString(nextPage, "text/html");
const articleList = nextPageDoc.querySelectorAll<HTMLElement>("#urls article");
const nextPaginationElement = nextPageDoc.querySelector<HTMLElement>("#pagination");
document.querySelector("#pagination")?.remove();
const urlsElement = document.querySelector<HTMLElement>("#urls");
if (!urlsElement) {
throw new Error("URLs element not found");
}
if (articleList.length > 0 && !onlyImages) {
// do not add <hr> element when there are only images
urlsElement.appendChild(document.createElement("hr"));
}
urlsElement.append(...articleList);
if (nextPaginationElement) {
const results = document.querySelector<HTMLElement>("#results");
results?.appendChild(nextPaginationElement);
callback();
}
} catch (error) {
console.error("Error loading next page:", error);
const errorElement = Object.assign(document.createElement("div"), {
textContent: settings.translations?.error_loading_next_page ?? "Error loading next page",
className: "dialog-error"
});
errorElement.setAttribute("role", "alert");
document.querySelector("#pagination")?.replaceChildren(errorElement);
}
};
const intersectionObserveOptions: IntersectionObserverInit = {
rootMargin: "320px"
};
const observer: IntersectionObserver = new IntersectionObserver(async (entries: IntersectionObserverEntry[]) => {
const [paginationEntry] = entries;
if (paginationEntry?.isIntersecting) {
observer.unobserve(paginationEntry.target);
await loadNextPage(() => {
const nextObservedElement = document.querySelector<HTMLElement>(observedSelector);
if (nextObservedElement) {
observer.observe(nextObservedElement);
}
});
}
}, intersectionObserveOptions);
const initialObservedElement: HTMLElement | null = document.querySelector<HTMLElement>(observedSelector);
if (initialObservedElement) {
observer.observe(initialObservedElement);
}
}
protected async post(): Promise<void> {
// noop
}
}

View File

@@ -0,0 +1,93 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import "ol/ol.css";
import { Feature, Map as OlMap, View } from "ol";
import { GeoJSON } from "ol/format";
import { Point } from "ol/geom";
import { Tile as TileLayer, Vector as VectorLayer } from "ol/layer";
import { fromLonLat } from "ol/proj";
import { OSM, Vector as VectorSource } from "ol/source";
import { Circle, Fill, Stroke, Style } from "ol/style";
import { Plugin } from "../Plugin.ts";
/**
* MapView
*/
export default class MapView extends Plugin {
private readonly map: HTMLElement;
public constructor(map: HTMLElement) {
super("mapView");
this.map = map;
}
protected async run(): Promise<void> {
const { leafletTarget: target, mapLon = "0", mapLat = "0", mapGeojson } = this.map.dataset;
const lon = Number.parseFloat(mapLon);
const lat = Number.parseFloat(mapLat);
const view = new View({ maxZoom: 16, enableRotation: false });
const map = new OlMap({
target: target,
layers: [new TileLayer({ source: new OSM({ maxZoom: 16 }) })],
view: view
});
try {
const markerSource = new VectorSource({
features: [
new Feature({
geometry: new Point(fromLonLat([lon, lat]))
})
]
});
const markerLayer = new VectorLayer({
source: markerSource,
style: new Style({
image: new Circle({
radius: 6,
fill: new Fill({ color: "#3050ff" })
})
})
});
map.addLayer(markerLayer);
} catch (error) {
console.error("Failed to create marker layer:", error);
}
if (mapGeojson) {
try {
const geoSource = new VectorSource({
features: new GeoJSON().readFeatures(JSON.parse(mapGeojson), {
dataProjection: "EPSG:4326",
featureProjection: "EPSG:3857"
})
});
const geoLayer = new VectorLayer({
source: geoSource,
style: new Style({
stroke: new Stroke({ color: "#3050ff", width: 2 }),
fill: new Fill({ color: "#3050ff33" })
})
});
map.addLayer(geoLayer);
const geoSourceExtent = geoSource.getExtent();
if (geoSourceExtent) {
view.fit(geoSourceExtent, { padding: [20, 20, 20, 20] });
}
} catch (error) {
console.error("Failed to create GeoJSON layer:", error);
}
}
}
protected async post(): Promise<void> {
// noop
}
}

View File

@@ -0,0 +1,69 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import { load } from "./loader.ts";
import { Endpoints, endpoint, listen, ready, settings } from "./toolkit.ts";
ready(() => {
document.documentElement.classList.remove("no-js");
document.documentElement.classList.add("js");
listen("click", ".close", function (this: HTMLElement) {
(this.parentNode as HTMLElement)?.classList.add("invisible");
});
listen("click", ".searxng_init_map", async function (this: HTMLElement, event: Event) {
event.preventDefault();
this.classList.remove("searxng_init_map");
load(() => import("./plugin/MapView.ts").then(({ default: Plugin }) => new Plugin(this)), {
on: "endpoint",
where: [Endpoints.results]
});
});
if (settings.plugins?.includes("infiniteScroll")) {
load(() => import("./plugin/InfiniteScroll.ts").then(({ default: Plugin }) => new Plugin()), {
on: "endpoint",
where: [Endpoints.results]
});
}
if (settings.plugins?.includes("calculator")) {
load(() => import("./plugin/Calculator.ts").then(({ default: Plugin }) => new Plugin()), {
on: "endpoint",
where: [Endpoints.results]
});
}
});
ready(
() => {
void import("./main/keyboard.ts");
void import("./main/search.ts");
if (settings.autocomplete) {
void import("./main/autocomplete.ts");
}
},
{ on: [endpoint === Endpoints.index] }
);
ready(
() => {
void import("./main/keyboard.ts");
void import("./main/results.ts");
void import("./main/search.ts");
if (settings.autocomplete) {
void import("./main/autocomplete.ts");
}
},
{ on: [endpoint === Endpoints.results] }
);
ready(
() => {
void import("./main/preferences.ts");
},
{ on: [endpoint === Endpoints.preferences] }
);

View File

@@ -1 +0,0 @@
import "./head/00_init.js";

View File

@@ -1,7 +0,0 @@
import "./main/00_toolkit.js";
import "./main/infinite_scroll.js";
import "./main/keyboard.js";
import "./main/mapresult.js";
import "./main/preferences.js";
import "./main/results.js";
import "./main/search.js";

View File

@@ -0,0 +1,134 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import type { KeyBindingLayout } from "./main/keyboard.ts";
// synced with searx/webapp.py get_client_settings
type Settings = {
plugins?: string[];
advanced_search?: boolean;
autocomplete?: string;
autocomplete_min?: number;
doi_resolver?: string;
favicon_resolver?: string;
hotkeys?: KeyBindingLayout;
method?: "GET" | "POST";
query_in_title?: boolean;
results_on_new_tab?: boolean;
safesearch?: 0 | 1 | 2;
search_on_category_select?: boolean;
theme?: string;
theme_static_path?: string;
translations?: Record<string, string>;
url_formatting?: "pretty" | "full" | "host";
};
type HTTPOptions = {
body?: BodyInit;
timeout?: number;
};
type ReadyOptions = {
// all values must be truthy for the callback to be executed
on?: (boolean | undefined)[];
};
export type EndpointsKeys = keyof typeof Endpoints;
export const Endpoints = {
index: "index",
results: "results",
preferences: "preferences",
unknown: "unknown"
} as const;
export const mutable = {
closeDetail: undefined as (() => void) | undefined,
scrollPageToSelected: undefined as (() => void) | undefined,
selectImage: undefined as ((resultElement: HTMLElement) => void) | undefined,
selectNext: undefined as ((openDetailView?: boolean) => void) | undefined,
selectPrevious: undefined as ((openDetailView?: boolean) => void) | undefined
};
const getEndpoint = (): EndpointsKeys => {
const metaEndpoint = document.querySelector('meta[name="endpoint"]')?.getAttribute("content");
if (metaEndpoint && metaEndpoint in Endpoints) {
return metaEndpoint as EndpointsKeys;
}
return Endpoints.unknown;
};
const getSettings = (): Settings => {
const settings = document.querySelector("script[client_settings]")?.getAttribute("client_settings");
if (!settings) return {};
try {
return JSON.parse(atob(settings));
} catch (error) {
console.error("Failed to load client_settings:", error);
return {};
}
};
export const http = async (method: string, url: string | URL, options?: HTTPOptions): Promise<Response> => {
const controller = new AbortController();
const timeoutId = setTimeout(() => controller.abort(), options?.timeout ?? 30_000);
const res = await fetch(url, {
body: options?.body,
method: method,
signal: controller.signal
}).finally(() => clearTimeout(timeoutId));
if (!res.ok) {
throw new Error(res.statusText);
}
return res;
};
export const listen = <K extends keyof DocumentEventMap, E extends HTMLElement>(
type: string | K,
target: string | Document | E,
listener: (this: E, event: DocumentEventMap[K]) => void | Promise<void>,
options?: AddEventListenerOptions
): void => {
if (typeof target !== "string") {
target.addEventListener(type, listener as EventListener, options);
return;
}
document.addEventListener(
type,
(event: Event) => {
for (const node of event.composedPath()) {
if (node instanceof HTMLElement && node.matches(target)) {
try {
listener.call(node as E, event as DocumentEventMap[K]);
} catch (error) {
console.error(error);
}
break;
}
}
},
options
);
};
export const ready = (callback: () => void, options?: ReadyOptions): void => {
for (const condition of options?.on ?? []) {
if (!condition) {
return;
}
}
if (document.readyState === "loading") {
listen("DOMContentLoaded", document, callback, { once: true });
} else {
callback();
}
};
export const endpoint: EndpointsKeys = getEndpoint();
export const settings: Settings = getSettings();

View File

@@ -0,0 +1,34 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import { getElement } from "./getElement.ts";
export const appendAnswerElement = (element: HTMLElement | string | number): void => {
const results = getElement<HTMLDivElement>("results");
// ./searx/templates/elements/answers.html
let answers = getElement<HTMLDivElement>("answers", { assert: false });
if (!answers) {
// what is this?
const answersTitle = document.createElement("h4");
answersTitle.setAttribute("class", "title");
answersTitle.setAttribute("id", "answers-title");
answersTitle.textContent = "Answers : ";
answers = document.createElement("div");
answers.setAttribute("id", "answers");
answers.setAttribute("role", "complementary");
answers.setAttribute("aria-labelledby", "answers-title");
answers.appendChild(answersTitle);
}
if (!(element instanceof HTMLElement)) {
const span = document.createElement("span");
span.innerHTML = element.toString();
// biome-ignore lint/style/noParameterAssign: TODO
element = span;
}
answers.appendChild(element);
results.insertAdjacentElement("afterbegin", answers);
};

View File

@@ -0,0 +1,8 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
type AssertElement = <T>(element?: T | null) => asserts element is T;
export const assertElement: AssertElement = <T>(element?: T | null): asserts element is T => {
if (!element) {
throw new Error("DOM element not found");
}
};

View File

@@ -0,0 +1,21 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import { assertElement } from "./assertElement.ts";
type Options = {
assert?: boolean;
};
export function getElement<T>(id: string, options?: { assert: true }): T;
export function getElement<T>(id: string, options?: { assert: false }): T | null;
export function getElement<T>(id: string, options: Options = {}): T | null {
options.assert ??= true;
const element = document.getElementById(id) as T | null;
if (options.assert) {
assertElement(element);
}
return element;
}

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
.dialog-modal {
animation-name: dialogmodal;
animation-duration: 0.13s;

View File

@@ -1,8 +1,9 @@
/*! Autocomplete.js v2.6.3 | license MIT | (c) 2017, Baptiste Donaux | http://autocomplete-js.com */
// SPDX-License-Identifier: AGPL-3.0-or-later
.autocomplete {
position: absolute;
width: @search-width;
max-width: calc(100% - 2 * @search-padding-horizontal);
max-height: 0;
overflow-y: hidden;
.ltr-text-align-left();
@@ -65,8 +66,6 @@
@media screen and (max-width: @phone) {
.autocomplete {
width: 100%;
> ul > li {
padding: 1rem;
}

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/*
* SearXNG, A privacy-respecting, hackable metasearch engine
*
@@ -287,8 +289,9 @@
@results-image-row-height: 12rem;
@results-image-row-height-phone: 10rem;
@search-width: 44rem;
// heigh of #search, see detail.less
// height of #search, see detail.less
@search-height: 13rem;
@search-padding-horizontal: 0.5rem;
/// Device Size
/// @desktop > @tablet

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
#main_results #results.image-detail-open.only_template_images {
width: min(98%, 59.25rem) !important;
}
@@ -244,7 +246,7 @@ article.result-images .detail {
a.result-images-source img {
width: 100%;
max-height: calc(100vh - 20rem);
max-height: calc(100vh - 2rem);
margin: 0;
}

View File

@@ -1,17 +1,16 @@
iframe[src^="https://w.soundcloud.com"]
{
// SPDX-License-Identifier: AGPL-3.0-or-later
iframe[src^="https://w.soundcloud.com"] {
height: 120px;
}
iframe[src^="https://www.deezer.com"]
{
iframe[src^="https://www.deezer.com"] {
// The real size is 92px, but 94px are needed to avoid an inner scrollbar of
// the embedded HTML.
height: 94px;
}
iframe[src^="https://www.mixcloud.com"]
{
iframe[src^="https://www.mixcloud.com"] {
// the embedded player from mixcloud has some quirks: initial there is an
// issue with an image URL that is blocked since it is an a Cross-Origin
// request. The alternative text (<img alt='Mixcloud Logo'> then cause an
@@ -21,19 +20,16 @@ iframe[src^="https://www.mixcloud.com"]
height: 250px;
}
iframe[src^="https://bandcamp.com/EmbeddedPlayer"]
{
iframe[src^="https://bandcamp.com/EmbeddedPlayer"] {
// show playlist
height: 350px;
}
iframe[src^="https://bandcamp.com/EmbeddedPlayer/track"]
{
iframe[src^="https://bandcamp.com/EmbeddedPlayer/track"] {
// hide playlist
height: 120px;
}
iframe[src^="https://genius.com/songs"]
{
iframe[src^="https://genius.com/songs"] {
height: 65px;
}

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
#main_index {
margin-top: 26vh;
}
@@ -6,7 +8,7 @@
text-align: center;
.title {
background: url("../img/searxng.png") no-repeat;
background: url("./img/searxng.png") no-repeat;
min-height: 4rem;
margin: 4rem auto;
background-position: center;

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
.info-page {
code {
font-family: monospace;

View File

@@ -2,9 +2,6 @@
// Mixins
.text-size-adjust (@property: 100%) {
-webkit-text-size-adjust: @property;
-ms-text-size-adjust: @property;
-moz-text-size-adjust: @property;
text-size-adjust: @property;
}
@@ -22,7 +19,6 @@
// disable user selection
.disable-user-select () {
-webkit-touch-callout: none;
user-select: none;
}

View File

@@ -1,37 +0,0 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
.stats_endpoint {
.github-issue-button {
display: block;
font-size: 16px;
}
.issue-hide {
display: none;
}
input[type="checked"] {
position: absolute;
}
label {
margin: 1rem 1rem 1rem 0;
}
.step_content {
margin: 1rem 1rem 1rem 2rem;
}
.step1,
.step2 {
visibility: hidden;
}
.step1_delay {
transition: visibility 0s linear 4s;
}
#step1:checked ~ .step1,
#step2:checked ~ .step2 {
visibility: visible;
}
}

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
table {
border-collapse: collapse;

View File

@@ -1,4 +1,6 @@
@import "../../generated/pygments.less";
// SPDX-License-Identifier: AGPL-3.0-or-later
@import "../../../generated/pygments.less";
.codelines {
margin: @results-margin 0 0 0;
@@ -18,12 +20,9 @@
cursor: default;
&::selection {
background: transparent; /* WebKit/Blink Browsers */
background: transparent;
}
&::-moz-selection {
background: transparent; /* Gecko Browsers */
}
margin-right: 8px;
text-align: right;
}
@@ -31,6 +30,12 @@
span.linenos {
color: var(--color-line-number);
}
.err {
// The code view in the result list should not act as a code-checker.
border: none;
color: inherit;
}
}
}

View File

@@ -0,0 +1,22 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/*
Layout of the Files result class
*/
#main_results .result-file {
border: 1px solid var(--color-result-border);
margin: 0 @results-tablet-offset 1rem @results-tablet-offset !important;
.rounded-corners;
video {
width: 100%;
aspect-ratio: 16 / 9;
padding: 10px 0 0 0;
}
audio {
width: 100%;
padding: 10px 0 0 0;
}
}

View File

@@ -1,6 +1,9 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/*
Layout of the KeyValue result class
*/
#main_results .result-keyvalue {
caption {
padding: 0.8rem 0.5rem;
@@ -14,7 +17,7 @@
}
table {
word-break: break-word;
word-break: break-all;
table-layout: fixed;
width: 100%;
background-color: var(--color-result-keyvalue-table);

View File

@@ -0,0 +1,72 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/*
Layout of the Paper result class
*/
.result-paper {
.attributes {
display: table;
border-spacing: 0.125rem;
div {
display: table-row;
span {
font-size: 0.9rem;
margin-top: 0.25rem;
display: table-cell;
time {
font-size: 0.9rem;
}
}
span:first-child {
color: var(--color-base-font);
min-width: 10rem;
}
span:nth-child(2) {
color: var(--color-result-publishdate-font);
}
}
}
.content {
margin-top: 0.25rem;
}
.comments {
font-size: 0.9rem;
margin: 0.25rem 0 0 0;
padding: 0;
overflow-wrap: break-word;
line-height: 1.24;
font-style: italic;
}
}
@media screen and (max-width: @phone) {
.result-paper {
.attributes {
display: block;
div {
display: block;
span {
display: inline;
}
span:first-child {
font-weight: bold;
}
span:nth-child(2) {
.ltr-margin-left(0.5rem);
}
}
}
}
}

View File

@@ -1,12 +1,8 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
@import (inline) "../../node_modules/normalize.css/normalize.css";
@import "definitions.less";
.text-size-adjust (@property: 100%) {
-webkit-text-size-adjust: @property;
-ms-text-size-adjust: @property;
-moz-text-size-adjust: @property;
text-size-adjust: @property;
}
@import "mixins.less";
// Reset padding and margin
html,

View File

@@ -1,6 +1,4 @@
/*
* SearXNG, A privacy-respecting, hackable metasearch engine
*/
// SPDX-License-Identifier: AGPL-3.0-or-later
#search {
padding: 0;
@@ -131,7 +129,7 @@ button.category_button {
}
#search_view {
padding: 0.5rem 0.3rem 0 0.5rem;
padding: 0.5rem @search-padding-horizontal 0 @search-padding-horizontal;
grid-area: search;
body.results_endpoint & {
@@ -141,7 +139,8 @@ button.category_button {
.search_box {
border-radius: 0.8rem;
width: @search-width;
width: 100%;
max-width: @search-width;
display: inline-flex;
flex-direction: row;
white-space: nowrap;
@@ -179,7 +178,6 @@ html.no-js #clear_search.hide_if_nojs {
#send_search {
display: block;
margin: 0;
padding: 0.8rem;
background: none repeat scroll 0 0 var(--color-search-background);
border: none;
outline: none;
@@ -195,13 +193,9 @@ html.no-js #clear_search.hide_if_nojs {
.ltr-rounded-left-corners(0.8rem);
}
#q::-ms-clear,
#q::-webkit-search-cancel-button {
display: none;
}
#send_search {
.ltr-rounded-right-corners(0.8rem);
padding: 0.8rem;
&:hover {
cursor: pointer;
@@ -270,7 +264,6 @@ html.no-js #clear_search.hide_if_nojs {
width: 100%;
.ltr-text-align-left();
overflow: scroll hidden;
-webkit-overflow-scrolling: touch;
}
}
}
@@ -291,8 +284,7 @@ html.no-js #clear_search.hide_if_nojs {
}
.search_box {
width: 98%;
display: flex;
width: 100%;
}
#q {
@@ -374,11 +366,6 @@ html.no-js #clear_search.hide_if_nojs {
#categories {
.disable-user-select;
&::-webkit-scrollbar {
width: 0;
height: 0;
}
}
#categories_container {

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/*
--center-page-width overrides the less variable @results-width when the results are centered
see the CSS rules for #results in style.less ( grid-template-columns and gap).

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
.ltr-left(@offset) {
left: @offset;
}

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
.ltr-left(@offset) {
right: @offset;
}
@@ -129,13 +131,7 @@
}
// select HTML element
@supports (
(background-position-x: 100%) and
(
(appearance: none) or (-webkit-appearance: none) or
(-moz-appearance: none)
)
) {
@supports ((background-position-x: 100%) and ((appearance: none))) {
select {
border-width: 0 0 0 2rem;
background-position-x: -2rem;

View File

@@ -1,24 +1,19 @@
/*
* SearXNG, A privacy-respecting, hackable metasearch engine
*
* To convert "style.less" to "style.css" run: $make styles
*/
// SPDX-License-Identifier: AGPL-3.0-or-later
// stylelint-disable no-descending-specificity
@import (inline) "../../node_modules/normalize.css/normalize.css";
@import "definitions.less";
@import "mixins.less";
@import "code.less";
@import "toolkit.less";
@import "autocomplete.less";
@import "detail.less";
@import "animations.less";
@import "embedded.less";
@import "info.less";
@import "new_issue.less";
@import "stats.less";
@import "result_templates.less";
@import "weather.less";
// for index.html template
@import "index.less";
@@ -167,12 +162,22 @@ article[data-vim-selected].category-videos,
article[data-vim-selected].category-news,
article[data-vim-selected].category-map,
article[data-vim-selected].category-music,
article[data-vim-selected].category-files,
article[data-vim-selected].category-social {
border: 1px solid var(--color-result-vim-arrow);
.rounded-corners;
}
.image-label-bottom-right() {
position: absolute;
right: 0;
bottom: 0;
background: var(--color-image-resolution-background);
padding: 0.3rem 0.5rem;
font-size: 0.9rem;
color: var(--color-image-resolution-font);
border-top-left-radius: 0.3rem;
}
.result {
margin: @results-margin 0;
padding: @result-padding;
@@ -182,7 +187,7 @@ article[data-vim-selected].category-social {
h3 {
font-size: 1.2rem;
word-wrap: break-word;
overflow-wrap: break-word;
margin: 0.4rem 0 0.4rem 0;
padding: 0;
@@ -216,7 +221,7 @@ article[data-vim-selected].category-social {
margin: 0;
padding: 0;
max-width: 54em;
word-wrap: break-word;
overflow-wrap: break-word;
line-height: 1.24;
.highlight {
@@ -299,12 +304,22 @@ article[data-vim-selected].category-social {
color: var(--color-result-description-highlight-font);
}
img.thumbnail {
a.thumbnail_link {
position: relative;
margin-top: 0.6rem;
.ltr-margin-right(1rem);
.ltr-float-left();
padding-top: 0.6rem;
.ltr-padding-right(1rem);
width: 7rem;
height: unset; // remove height value that was needed for lazy loading
img.thumbnail {
width: 7rem;
height: unset; // remove height value that was needed for lazy loading
display: block;
}
.thumbnail_length {
.image-label-bottom-right();
right: 6px;
}
}
.break {
@@ -312,11 +327,11 @@ article[data-vim-selected].category-social {
}
}
.result-paper,
.result-packages {
.attributes {
display: table;
border-spacing: 0.125rem;
margin-top: 0.3rem;
div {
display: table-row;
@@ -350,18 +365,12 @@ article[data-vim-selected].category-social {
font-size: 0.9rem;
margin: 0.25rem 0 0 0;
padding: 0;
word-wrap: break-word;
overflow-wrap: break-word;
line-height: 1.24;
font-style: italic;
}
}
.result-packages {
.attributes {
margin-top: 0.3rem;
}
}
.template_group_images {
display: flex;
flex-wrap: wrap;
@@ -376,7 +385,6 @@ article[data-vim-selected].category-social {
.category-news,
.category-map,
.category-music,
.category-files,
.category-social {
border: 1px solid var(--color-result-border);
margin: 0 @results-tablet-offset 1rem @results-tablet-offset !important;
@@ -401,23 +409,19 @@ article[data-vim-selected].category-social {
}
.result-videos {
img.thumbnail {
.ltr-float-left();
padding-top: 0.6rem;
.ltr-padding-right(1rem);
a.thumbnail_link img.thumbnail {
width: 20rem;
height: unset; // remove height value that was needed for lazy loading
}
}
.result-videos .content {
overflow: hidden;
}
.content {
overflow: hidden;
}
.result-videos .embedded-video iframe {
width: 100%;
aspect-ratio: 16 / 9;
padding: 10px 0 0 0;
.embedded-video iframe {
width: 100%;
aspect-ratio: 16 / 9;
padding: 10px 0 0 0;
}
}
@supports not (aspect-ratio: 1 / 1) {
@@ -482,14 +486,7 @@ article[data-vim-selected].category-social {
}
.image_resolution {
position: absolute;
right: 0;
bottom: 0;
background: var(--color-image-resolution-background);
padding: 0.3rem 0.5rem;
font-size: 0.9rem;
color: var(--color-image-resolution-font);
border-top-left-radius: 0.3rem;
.image-label-bottom-right();
}
span.title,
@@ -573,13 +570,16 @@ article[data-vim-selected].category-social {
#suggestions {
.wrapper {
display: flex;
flex-flow: column;
justify-content: flex-end;
padding-left: 0;
margin: 0;
list-style-position: inside;
li::marker {
color: var(--color-result-link-font);
}
form {
display: inline-block;
flex: 1 1 50%;
}
}
}
@@ -587,8 +587,8 @@ article[data-vim-selected].category-social {
#suggestions,
#infoboxes {
input {
padding: 0;
margin: 3px;
padding: 3px;
margin: 0;
font-size: 0.9em;
display: inline-block;
background: transparent;
@@ -690,7 +690,7 @@ summary.title {
#sidebar {
grid-area: sidebar;
word-wrap: break-word;
overflow-wrap: break-word;
color: var(--color-sidebar-font);
.infobox {
@@ -1031,10 +1031,6 @@ summary.title {
/ 100%;
gap: 0;
#sidebar {
display: none;
}
#urls {
margin: 0;
display: flex;
@@ -1121,7 +1117,6 @@ summary.title {
display: none;
}
.result-paper,
.result-packages {
.attributes {
display: block;
@@ -1167,3 +1162,6 @@ pre code {
// import layouts of the Result types
@import "result_types/keyvalue.less";
@import "result_types/code.less";
@import "result_types/paper.less";
@import "result_types/file.less";

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
// other solution : http://stackoverflow.com/questions/1577598/how-to-hide-parts-of-html-when-javascript-is-disabled/13857783#13857783
// stylelint-disable no-descending-specificity
@@ -156,9 +158,7 @@ div.selectable_url {
td {
padding: 0 1em 0 0;
padding-top: 0;
.ltr-padding-right(1rem);
padding-bottom: 0;
.ltr-padding-left(0);
}
@@ -193,6 +193,15 @@ div.selectable_url {
border-color: var(--color-warning);
}
.dialog-warning-block {
.dialog();
display: block;
color: var(--color-warning);
background: var(--color-warning-background);
border-color: var(--color-warning);
}
.dialog-modal {
.dialog();
@@ -307,7 +316,7 @@ html body .tabs > input:checked {
}
~ label {
position: inherited;
position: inherit;
background: inherit;
border-bottom: 2px solid transparent;
font-weight: normal;
@@ -347,17 +356,9 @@ select {
}
}
@supports (
(background-position-x: 100%) and
(
(appearance: none) or (-webkit-appearance: none) or
(-moz-appearance: none)
)
) {
@supports ((background-position-x: 100%) and ((appearance: none))) {
select {
appearance: none;
-webkit-appearance: none;
-moz-appearance: none;
border-width: 0 2rem 0 0;
border-color: transparent;
background: data-uri("image/svg+xml;charset=UTF-8", @select-light-svg-path)
@@ -400,8 +401,6 @@ select {
/* -- checkbox-onoff -- */
input.checkbox-onoff[type="checkbox"] {
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
cursor: pointer;
display: inline-block;
@@ -475,8 +474,6 @@ input.checkbox-onoff.reversed-checkbox[type="checkbox"] {
/* -- checkbox -- */
@supports (transform: rotate(-45deg)) {
input[type="checkbox"]:not(.checkbox-onoff) {
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
width: 20px;
@@ -549,33 +546,16 @@ input.checkbox-onoff.reversed-checkbox[type="checkbox"] {
border-right: 0.5em solid var(--color-toolkit-loader-border);
border-bottom: 0.5em solid var(--color-toolkit-loader-border);
border-left: 0.5em solid var(--color-toolkit-loader-borderleft);
-webkit-transform: translateZ(0);
-ms-transform: translateZ(0);
transform: translateZ(0);
-webkit-animation: load8 1.2s infinite linear;
animation: load8 1.2s infinite linear;
}
@-webkit-keyframes load8 {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@keyframes load8 {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@@ -606,9 +586,6 @@ td:hover .engine-tooltip,
margin: 0;
padding: 0 0.125rem 0 4rem;
width: 100%;
width: -moz-available;
width: -webkit-fill-available;
width: fill;
flex-flow: row nowrap;
align-items: center;
display: inline-flex;
@@ -633,7 +610,7 @@ td:hover .engine-tooltip,
.stacked-bar-chart-base();
background: var(--color-base-font);
border: 1px solid rgba(var(--color-base-font-rgb), 0.9);
border: 1px solid rgb(var(--color-base-font-rgb), 0.9);
padding: 0.3rem 0;
}
@@ -641,7 +618,7 @@ td:hover .engine-tooltip,
.stacked-bar-chart-base();
background: transparent;
border: 1px solid rgba(var(--color-base-font-rgb), 0.3);
border: 1px solid rgb(var(--color-base-font-rgb), 0.3);
padding: 0.3rem 0;
}
@@ -649,7 +626,7 @@ td:hover .engine-tooltip,
.stacked-bar-chart-base();
background: transparent;
border-bottom: 1px dotted rgba(var(--color-base-font-rgb), 0.5);
border-bottom: 1px dotted rgb(var(--color-base-font-rgb), 0.5);
padding: 0;
}
@@ -657,7 +634,7 @@ td:hover .engine-tooltip,
.stacked-bar-chart-base();
background: transparent;
border-left: 1px solid rgba(var(--color-base-font-rgb), 0.9);
border-left: 1px solid rgb(var(--color-base-font-rgb), 0.9);
padding: 0.4rem 0;
width: 1px;
}

View File

@@ -1,3 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
.loader,
.loader::after {
border-radius: 50%;

View File

@@ -0,0 +1,44 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
#answers .weather {
summary {
display: block;
list-style: none;
}
div.summary {
margin: 0;
padding: 0.5rem 1rem;
background-color: var(--color-header-background);
.rounded-corners-tiny;
}
table {
font-size: 0.9rem;
table-layout: fixed;
margin-top: 0.5rem;
margin-bottom: 0.5rem;
border-collapse: separate;
border-spacing: 0.1em 0;
}
td {
padding: 0;
overflow: hidden;
text-overflow: ellipsis;
}
img.symbol {
width: 5rem;
margin: auto;
display: block;
}
.title {
// background-color: var(--color-result-keyvalue-even);
}
.measured {
// background-color: var(--color-result-keyvalue-odd);
}
}

View File

@@ -1,2 +0,0 @@
leaflet.css -diff
leaflet.js -diff

View File

@@ -1,84 +0,0 @@
/**
* Generate icons.html for the jinja templates of the simple theme.
*/
import { argv } from "node:process";
import { dirname, resolve } from "node:path";
import { jinja_svg_sets } from "./tools/jinja_svg_catalog.js";
const HERE = dirname(argv[1]) + "/";
const dest = resolve(HERE, "../../searx/templates/simple/icons.html");
/** @type import("./tools/jinja_svg_catalog.js").JinjaMacro[] */
const searxng_jinja_macros = [
{ name: "icon", class: "sxng-icon-set" },
{ name: "icon_small", class: "sxng-icon-set-small" },
{ name: "icon_big", class: "sxng-icon-set-big" },
];
const sxng_icon_opts ={
multipass: true,
plugins: [
{ name: "removeTitle" },
{ name: "removeXMLNS" },
{ name: "addAttributesToSVGElement",
params: {
attributes: [
{
"aria-hidden": "true",
}]}}]
};
/** @type import("./tools/jinja_svg_catalog.js").IconSet */
const simple_icons = [
{
base: resolve(HERE, "node_modules/ionicons/dist/svg"),
set: {
"alert": "alert-outline.svg",
"appstore": "apps-outline.svg",
"book": "book-outline.svg",
"close": "close-outline.svg",
"download": "download-outline.svg",
"ellipsis-vertical": "ellipsis-vertical-outline.svg",
"file-tray-full": "file-tray-full-outline.svg",
"film": "film-outline.svg",
"globe": "globe-outline.svg",
"heart": "heart-outline.svg",
"image": "image-outline.svg",
"layers": "layers-outline.svg",
"leecher": "arrow-down.svg",
"location": "location-outline.svg",
"magnet": "magnet-outline.svg",
"musical-notes": "musical-notes-outline.svg",
"navigate-down": "chevron-down-outline.svg",
"navigate-left": "chevron-back-outline.svg",
"navigate-right": "chevron-forward-outline.svg",
"navigate-up": "chevron-up-outline.svg",
"people": "people-outline.svg",
"play": "play-outline.svg",
"radio": "radio-outline.svg",
"save": "save-outline.svg",
"school": "school-outline.svg",
"search": "search-outline.svg",
"seeder": "swap-vertical.svg",
"settings": "settings-outline.svg",
"tv": "tv-outline.svg",
},
svgo_opts: sxng_icon_opts,
},
// some of the ionicons are not suitable for a dark theme, we fixed the svg
// manually in src/svg/ionicons
// - https://github.com/searxng/searxng/pull/4284#issuecomment-2680550342
{
base: resolve(HERE, "src/svg/ionicons"),
set: {
"information-circle": "information-circle-outline.svg",
"newspaper": "newspaper-outline.svg",
},
svgo_opts: sxng_icon_opts,
}
];
jinja_svg_sets(dest, searxng_jinja_macros, simple_icons);

View File

@@ -0,0 +1,84 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/**
* Generate icons.html for the jinja templates of the simple theme.
*/
import { dirname, resolve } from "node:path";
import { argv } from "node:process";
import type { Config as SvgoConfig } from "svgo";
import { type IconSet, type JinjaMacro, jinja_svg_sets } from "./tools/jinja_svg_catalog.ts";
const HERE = `${dirname(argv[1] || "")}/`;
const dest: string = resolve(HERE, "../../searx/templates/simple/icons.html");
const searxng_jinja_macros: JinjaMacro[] = [
{ name: "icon", class: "sxng-icon-set" },
{ name: "icon_small", class: "sxng-icon-set-small" },
{ name: "icon_big", class: "sxng-icon-set-big" }
];
const sxng_icon_opts: SvgoConfig = {
multipass: true,
plugins: [
"removeTitle",
"removeXMLNS",
{
name: "addAttributesToSVGElement",
params: {
attributes: [{ "aria-hidden": "true" }]
}
}
]
};
const simple_icons: IconSet[] = [
{
base: resolve(HERE, "node_modules/ionicons/dist/svg"),
set: {
alert: "alert-outline.svg",
appstore: "apps-outline.svg",
book: "book-outline.svg",
close: "close-outline.svg",
download: "download-outline.svg",
"ellipsis-vertical": "ellipsis-vertical-outline.svg",
"file-tray-full": "file-tray-full-outline.svg",
film: "film-outline.svg",
globe: "globe-outline.svg",
heart: "heart-outline.svg",
image: "image-outline.svg",
layers: "layers-outline.svg",
leecher: "arrow-down.svg",
location: "location-outline.svg",
magnet: "magnet-outline.svg",
"musical-notes": "musical-notes-outline.svg",
"navigate-down": "chevron-down-outline.svg",
"navigate-left": "chevron-back-outline.svg",
"navigate-right": "chevron-forward-outline.svg",
"navigate-up": "chevron-up-outline.svg",
people: "people-outline.svg",
play: "play-outline.svg",
radio: "radio-outline.svg",
save: "save-outline.svg",
school: "school-outline.svg",
search: "search-outline.svg",
seeder: "swap-vertical.svg",
settings: "settings-outline.svg",
tv: "tv-outline.svg"
},
svgo_opts: sxng_icon_opts
},
// some of the ionicons are not suitable for a dark theme, we fixed the svg
// manually in src/svg/ionicons
// - https://github.com/searxng/searxng/pull/4284#issuecomment-2680550342
{
base: resolve(HERE, "src/svg/ionicons"),
set: {
"information-circle": "information-circle-outline.svg",
newspaper: "newspaper-outline.svg"
},
svgo_opts: sxng_icon_opts
}
];
jinja_svg_sets(dest, searxng_jinja_macros, simple_icons);

View File

@@ -1,78 +0,0 @@
import fs from "fs";
import path from "path";
import sharp from "sharp";
import { optimize as svgo } from "svgo";
/**
* @typedef {object} Src2Dest - Mapping of src to dest
* @property {string} src - Name of the source file.
* @property {string} dest - Name of the destination file.
*/
/**
* Convert a list of SVG files to PNG.
*
* @param {Src2Dest[]} items - Array of SVG files (src: SVG, dest:PNG) to convert.
*/
async function svg2png (items) {
items.forEach(
async (item) => {
try {
fs.mkdir(path.dirname(item.dest), { recursive: true }, (err) => {
if (err)
throw err;
});
const info = await sharp(item.src).png({
force: true,
compressionLevel: 9,
palette: true,
}).toFile(item.dest);
console.log(
`[svg2png] created ${item.dest} -- bytes: ${info.size}, w:${info.width}px, h:${info.height}px`
);
} catch (err) {
console.error(`ERROR: ${item.dest} -- ${err}`);
throw(err);
}
}
);
}
/**
* Optimize SVG images for WEB.
*
* @param {import('svgo').Config} svgo_opts - Options passed to svgo.
* @param {Src2Dest[]} items - Array of SVG files (src:SVG, dest:SVG) to optimize.
*/
async function svg2svg(svgo_opts, items) {
items.forEach(
async (item) => {
try {
fs.mkdir(path.dirname(item.dest), { recursive: true }, (err) => {
if (err)
throw err;
});
const raw = fs.readFileSync(item.src, "utf8");
const opt = svgo(raw, svgo_opts);
fs.writeFileSync(item.dest, opt.data);
console.log(
`[svg2svg] optimized: ${item.dest} -- src: ${item.src}`
);
} catch (err) {
console.error(`ERROR: optimize src: ${item.src} -- ${err}`);
throw(err);
}
}
);
}
export { svg2png, svg2svg };

View File

@@ -0,0 +1,69 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import fs from "node:fs";
import path from "node:path";
import sharp from "sharp";
import type { Config } from "svgo";
import { optimize as svgo } from "svgo";
// Mapping of src to dest
export type Src2Dest = {
// Name of the source file.
src: string;
// Name of the destination file.
dest: string;
};
/**
* Convert a list of SVG files to PNG.
*
* @param items - Array of SVG files (src: SVG, dest:PNG) to convert.
* @param width - (optional) width of the PNG pictures
* @param height - (optional) height of the PNG pictures.
*/
export const svg2png = (items: Src2Dest[], width?: number, height?: number): void => {
for (const item of items) {
fs.mkdirSync(path.dirname(item.dest), { recursive: true });
sharp(item.src)
.png({
force: true,
compressionLevel: 9,
palette: true
})
.resize(width, height, {
fit: "contain"
})
.toFile(item.dest)
.then((info) => {
console.log(`[svg2png] created ${item.dest} -- bytes: ${info.size}, w:${info.width}px, h:${info.height}px`);
})
.catch((error) => {
console.error(`ERROR: ${item.dest} -- ${error}`);
throw error;
});
}
};
/**
* Optimize SVG images for WEB.
*
* @param items - Array of SVG files (src:SVG, dest:SVG) to optimize.
* @param svgo_opts - Options passed to svgo.
*/
export const svg2svg = (items: Src2Dest[], svgo_opts: Config): void => {
for (const item of items) {
try {
fs.mkdirSync(path.dirname(item.dest), { recursive: true });
const raw = fs.readFileSync(item.src, "utf8");
const opt = svgo(raw, svgo_opts);
fs.writeFileSync(item.dest, opt.data);
console.log(`[svg2svg] optimized: ${item.dest} -- src: ${item.src}`);
} catch (error) {
console.error(`ERROR: optimize src: ${item.src} -- ${error}`);
throw error;
}
}
};

View File

@@ -1,4 +1,6 @@
{{--
SPDX-License-Identifier: AGPL-3.0-or-later
This is a EDGE https://edgejs.dev/ template to generate a HTML Jinja template
for the backend. Example output of this EDGE template:
- https://github.com/searxng/searxng/blob/master/searx/templates/simple/icons.html

View File

@@ -1,132 +0,0 @@
import fs from "fs";
import { resolve, dirname } from "path";
import { Edge } from 'edge.js';
import { optimize as svgo } from "svgo";
import { fileURLToPath } from 'url';
const __dirname = dirname(fileURLToPath(import.meta.url));
const __jinja_class_placeholder__ = "__jinja_class_placeholder__";
// -- types
/**
* @typedef {object} IconSet - A set of icons
* @property {object[]} set - Array of SVG icons, where property name is the
* name of the icon and value is the src of the SVG (relative to base).
* @property {string} base - Folder in which the SVG src files are located.
* @property {import("svgo").Config} svgo_opts - svgo options for this set.
*/
/**
* @typedef {object} IconSVG - Mapping of icon name to SVG source file.
* @property {string} name - Name of the icon isource file.
* @property {string} src - Name of the destination file.
* @property {import("svgo").Config} svgo_opts - Options passed to svgo.
*/
/**
* @typedef {object} JinjaMacro - Arguments to create a jinja macro
* @property {string} name - Name of the jinja macro.
* @property {string} class - SVG's class name (value of XML class attribute)
*/
// -- functions
/**
* Generate a jinja template with a catalog of SVG icons that can be
* used in in other HTML jinja templates.
*
* @param {string} dest - filename of the generate jinja template.
* @param {JinjaMacro} macros - Jinja macros to create.
* @param {IconSVG[]} items - Array of SVG items.
*/
function jinja_svg_catalog(dest, macros, items) {
const svg_catalog = {};
const edge_template = resolve(__dirname, "jinja_svg_catalog.html.edge");
items.forEach(
(item) => {
/** @type {import("svgo").Config} */
// JSON.stringify & JSON.parse are used to create a deep copy of the
// item.svgo_opts object
const svgo_opts = JSON.parse(JSON.stringify(item.svgo_opts));
svgo_opts.plugins.push({
name: "addClassesToSVGElement",
params: {
classNames: [__jinja_class_placeholder__]
}}
);
try {
const raw = fs.readFileSync(item.src, "utf8");
const opt = svgo(raw, svgo_opts);
svg_catalog[item.name] = opt.data;
} catch (err) {
console.error(`ERROR: jinja_svg_catalog processing ${item.name} src: ${item.src} -- ${err}`);
throw(err);
}
}
);
fs.mkdir(dirname(dest), { recursive: true }, (err) => {
if (err) throw err;
});
const ctx = {
svg_catalog: svg_catalog,
macros: macros,
edge_template: edge_template,
__jinja_class_placeholder__: __jinja_class_placeholder__,
// see https://github.com/edge-js/edge/issues/162
open_curly_brace : "{{",
close_curly_brace : "}}"
};
const jinjatmpl = Edge.create().renderRawSync(
fs.readFileSync(edge_template, "utf-8"),
ctx
);
fs.writeFileSync(dest, jinjatmpl);
console.log(`[jinja_svg_catalog] created: ${dest}`);
}
/**
* Calls jinja_svg_catalog for a collection of icon sets where each set has its
* own parameters.
*
* @param {string} dest - filename of the generate jinja template.
* @param {JinjaMacro} macros - Jinja macros to create.
* @param {IconSet[]} sets - Array of SVG sets.
*/
function jinja_svg_sets(dest, macros, sets) {
/** @type IconSVG[] */
const items = [];
const all = [];
for (const obj of sets) {
for (const [name, file] of Object.entries(obj.set)) {
if (all.includes(name)) {
throw new Error(`ERROR: ${name} has already been defined`);
}
items.push({
name: name,
src: resolve(obj.base, file),
svgo_opts: obj.svgo_opts,
});
}
jinja_svg_catalog(dest, macros, items);
}
}
// -- exports
export {
jinja_svg_sets,
jinja_svg_catalog,
};

View File

@@ -0,0 +1,118 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import fs from "node:fs";
import { dirname, resolve } from "node:path";
import { Edge } from "edge.js";
import { type Config as SvgoConfig, optimize as svgo } from "svgo";
const __jinja_class_placeholder__ = "__jinja_class_placeholder__";
// A set of icons
export type IconSet = {
// Object of SVG icons, where property name is the name of the icon and value is the src of the SVG (relative to base)
set: Record<string, string>;
// Folder in which the SVG src files are located
base: string;
// svgo options for this set
svgo_opts: SvgoConfig;
};
// Mapping of icon name to SVG source file
type IconSVG = {
// Name of the icon isource file
name: string;
// Name of the destination file
src: string;
// Options passed to svgo
svgo_opts: SvgoConfig;
};
// Arguments to create a jinja macro
export type JinjaMacro = {
// Name of the jinja macro
name: string;
// SVG's class name (value of XML class attribute)
class: string;
};
/**
* Generate a jinja template with a catalog of SVG icons that can be
* used in other HTML jinja templates.
*
* @param dest - filename of the generate jinja template.
* @param macros - Jinja macros to create.
* @param items - Array of SVG items.
*/
export const jinja_svg_catalog = (dest: string, macros: JinjaMacro[], items: IconSVG[]): void => {
const svg_catalog: Record<string, string> = {};
const edge_template = resolve(import.meta.dirname, "jinja_svg_catalog.html.edge");
for (const item of items) {
// JSON.stringify & JSON.parse are used to create a deep copy of the item.svgo_opts object
const svgo_opts: SvgoConfig = JSON.parse(JSON.stringify(item.svgo_opts));
svgo_opts.plugins?.push({
name: "addClassesToSVGElement",
params: {
classNames: [__jinja_class_placeholder__]
}
});
try {
const raw = fs.readFileSync(item.src, "utf8");
const opt = svgo(raw, svgo_opts);
svg_catalog[item.name] = opt.data;
} catch (error) {
console.error(`ERROR: jinja_svg_catalog processing ${item.name} src: ${item.src} -- ${error}`);
throw error;
}
}
fs.mkdirSync(dirname(dest), { recursive: true });
const ctx = {
svg_catalog: svg_catalog,
macros: macros,
edge_template: edge_template,
__jinja_class_placeholder__: __jinja_class_placeholder__,
// see https://github.com/edge-js/edge/issues/162
open_curly_brace: "{{",
close_curly_brace: "}}"
};
const jinjatmpl = Edge.create().renderRawSync(fs.readFileSync(edge_template, "utf-8"), ctx);
fs.writeFileSync(dest, jinjatmpl);
console.log(`[jinja_svg_catalog] created: ${dest}`);
};
/**
* Calls jinja_svg_catalog for a collection of icon sets where each set has its
* own parameters.
*
* @param dest - filename of the generate jinja template.
* @param macros - Jinja macros to create.
* @param sets - Array of SVG sets.
*/
export const jinja_svg_sets = (dest: string, macros: JinjaMacro[], sets: IconSet[]): void => {
const items: IconSVG[] = [];
const all: string[] = [];
for (const obj of sets) {
for (const [name, file] of Object.entries(obj.set)) {
if (all.includes(name)) {
throw new Error(`ERROR: ${name} has already been defined`);
}
all.push(name);
items.push({
name: name,
src: resolve(obj.base, file),
svgo_opts: obj.svgo_opts
});
}
}
jinja_svg_catalog(dest, macros, items);
};

View File

@@ -1,41 +0,0 @@
/**
* Custom vite plugins to build the web-client components of the simple theme.
*
* HINT:
*
* This is an inital implementation for the migration of the build process
* from grunt to vite. For fully support (vite: build & serve) more work is
* needed.
*/
import { svg2png } from "./img.js";
import { svg2svg } from "./img.js";
/**
* Vite plugin to convert a list of SVG files to PNG.
*
* @param {import('./img.js').Src2Dest} items - Array of SVG files (src: SVG, dest:PNG) to convert.
*/
function plg_svg2png(items) {
return {
name: 'searxng-simple-svg2png',
apply: 'build', // or 'serve'
async writeBundle() { svg2png(items); },
};
}
/**
* Vite plugin to optimize SVG images for WEB.
*
* @param {import('svgo').Config} svgo_opts - Options passed to svgo.
* @param {import('./img.js').Src2Dest} items - Array of SVG files (src:SVG, dest:SVG) to optimize.
*/
function plg_svg2svg(svgo_opts, items) {
return {
name: 'searxng-simple-svg2png',
apply: 'build', // or 'serve'
async writeBundle() { svg2svg(items, svgo_opts); },
};
}
export { plg_svg2png, plg_svg2svg };

View File

@@ -0,0 +1,47 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/**
* Custom vite plugins to build the web-client components of the simple theme.
*
* HINT:
* This is an initial implementation for the migration of the build process
* from grunt to vite. For fully support (vite: build & serve) more work is
* needed.
*/
import type { Config } from "svgo";
import type { Plugin } from "vite";
import { type Src2Dest, svg2png, svg2svg } from "./img.ts";
/**
* Vite plugin to convert a list of SVG files to PNG.
*
* @param items - Array of SVG files (src: SVG, dest:PNG) to convert.
* @param width - (optional) width of the PNG picture
* @param height - (optional) height of the PNG picture
*/
export const plg_svg2png = (items: Src2Dest[], width?: number, height?: number): Plugin => {
return {
name: "searxng-simple-svg2png",
apply: "build",
writeBundle: () => {
svg2png(items, width, height);
}
};
};
/**
* Vite plugin to optimize SVG images for WEB.
*
* @param items - Array of SVG files (src:SVG, dest:SVG) to optimize.
* @param svgo_opts - Options passed to svgo.
*/
export const plg_svg2svg = (items: Src2Dest[], svgo_opts: Config): Plugin => {
return {
name: "searxng-simple-svg2svg",
apply: "build",
writeBundle: () => {
svg2svg(items, svgo_opts);
}
};
};

View File

@@ -0,0 +1,39 @@
{
"$schema": "https://json.schemastore.org/tsconfig.json",
"compilerOptions": {
"lib": ["DOM", "DOM.Iterable", "ES2022"],
"module": "ESNext",
"moduleResolution": "Bundler",
"target": "ES2022",
"allowImportingTsExtensions": true,
"allowJs": true,
"checkJs": true,
"esModuleInterop": true,
"incremental": true,
"noEmit": true,
"resolveJsonModule": true,
"skipLibCheck": true,
"strict": true,
"allowUnreachableCode": false,
"allowUnusedLabels": false,
"exactOptionalPropertyTypes": false,
"forceConsistentCasingInFileNames": true,
"isolatedModules": true,
"noFallthroughCasesInSwitch": true,
"noImplicitOverride": true,
"noImplicitReturns": true,
"noPropertyAccessFromIndexSignature": false,
"noUncheckedIndexedAccess": true,
"noUncheckedSideEffectImports": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"verbatimModuleSyntax": true,
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.tsbuildinfo",
"types": ["vite/client"]
},
"include": ["./"],
"exclude": ["./node_modules/"]
}

View File

@@ -1,185 +0,0 @@
/**
* CONFIG: https://vite.dev/config/
*/
import { resolve } from "node:path";
import { defineConfig } from "vite";
import stylelint from "vite-plugin-stylelint";
import { viteStaticCopy } from "vite-plugin-static-copy";
import { plg_svg2png } from "./tools/plg.js";
import { plg_svg2svg } from "./tools/plg.js";
const ROOT = "../.."; // root of the git reposetory
const PATH = {
dist: resolve(ROOT, "searx/static/themes/simple"),
// dist: resolve(ROOT, "client/simple/dist"),
src: "src",
modules: "node_modules",
brand: "src/brand",
static: resolve(ROOT, "client/simple/static"),
leaflet: resolve(ROOT, "client/simple/node_modules/leaflet/dist"),
templates: resolve(ROOT, "searx/templates/simple"),
};
const svg2svg_opts = {
plugins: [
{ name: "preset-default" },
"sortAttrs",
"convertStyleToAttrs",
]
};
const svg2svg_favicon_opts = {
plugins: [
{ name: "preset-default" },
"sortAttrs",
]
};
export default defineConfig({
root: PATH.src,
mode: "production",
// mode: "development",
// FIXME: missing CCS sourcemaps!!
// see: https://github.com/vitejs/vite/discussions/13845#discussioncomment-11992084
//
// what I have tried so far (see config below):
//
// - build.sourcemap
// - esbuild.sourcemap
// - css.preprocessorOptions.less.sourceMap
css: {
devSourcemap: true,
preprocessorOptions: {
less: {
// FIXME: missing CCS sourcemaps!!
sourceMap: {
outputSourceFiles: true,
sourceMapURL: (name) => { const s = name.split('/'); return s[s.length - 1] + '.map'; },
},
// env: 'development',
// relativeUrls: true,
// javascriptEnabled: true,
},
},
}, // end: css
esbuild : {
// FIXME: missing CCS sourcemaps!!
sourcemap: true
},
build: {
manifest: "manifest.json",
emptyOutDir: true,
assetsDir: "",
outDir: PATH.dist,
// FIXME: missing CCS sourcemaps!!
sourcemap: true,
// https://vite.dev/config/build-options.html#build-cssminify
cssMinify: true,
// cssMinify: "esbuild",
minify: "esbuild",
rollupOptions: {
input: {
// build CSS files
"css/searxng.min.css": PATH.src + "/less/style-ltr.less",
"css/searxng-rtl.min.css": PATH.src + "/less/style-rtl.less",
"css/rss.min.css": PATH.src + "/less/rss.less",
// build JS files
"js/searxng.head.min": PATH.src + "/js/searxng.head.js",
"js/searxng.min": PATH.src + "/js/searxng.js",
},
// file naming conventions / pathnames are relative to outDir (PATH.dist)
output: {
entryFileNames: "[name].js",
chunkFileNames: "[name].js",
assetFileNames: "[name].[ext]",
// Vite does not support "rollupOptions.output.sourcemap".
// Please use "build.sourcemap" instead.
// sourcemap: true,
},
},
}, // end: build
plugins: [
stylelint({
build: true,
emitWarningAsError: true,
fix: true,
}),
// Leaflet
viteStaticCopy({
targets: [
{ src: PATH.leaflet + "/leaflet.{js,js.map}", dest: PATH.dist + "/js" },
{ src: PATH.leaflet + "/images/*.png", dest: PATH.dist + "/css/images/" },
{ src: PATH.leaflet + "/*.{css,css.map}", dest: PATH.dist + "/css" },
{ src: PATH.static + "/**/*", dest: PATH.dist },
]
}),
// -- svg images
plg_svg2svg(
[
{ src: PATH.src + "/svg/empty_favicon.svg", dest: PATH.dist + "/img/empty_favicon.svg" },
{ src: PATH.src + "/svg/select-dark.svg", dest: PATH.dist + "/img/select-dark.svg" },
{ src: PATH.src + "/svg/select-light.svg", dest: PATH.dist + "/img/select-light.svg" },
],
svg2svg_opts,
),
// SearXNG brand (static)
plg_svg2png(
[
{ src: PATH.brand + "/searxng-wordmark.svg", dest: PATH.dist + "/img/favicon.png" },
{ src: PATH.brand + "/searxng.svg", dest: PATH.dist + "/img/searxng.png" },
],
),
// -- svg
plg_svg2svg(
[
{ src: PATH.brand + "/searxng.svg", dest: PATH.dist + "/img/searxng.svg" },
{ src: PATH.brand + "/img_load_error.svg", dest: PATH.dist + "/img/img_load_error.svg" },
],
svg2svg_opts,
),
// -- favicon
plg_svg2svg(
[ { src: PATH.brand + "/searxng-wordmark.svg", dest: PATH.dist + "/img/favicon.svg" } ],
svg2svg_favicon_opts,
),
// -- simple templates
plg_svg2svg(
[
{ src: PATH.brand + "/searxng-wordmark.svg", dest: PATH.templates + "/searxng-wordmark.min.svg" },
],
svg2svg_opts
),
] // end: plugins
});

View File

@@ -0,0 +1,210 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
/**
* CONFIG: https://vite.dev/config/
*/
import { resolve } from "node:path";
import { constants as zlibConstants } from "node:zlib";
import browserslistToEsbuild from "browserslist-to-esbuild";
import { browserslistToTargets } from "lightningcss";
import type { PreRenderedAsset } from "rolldown";
import type { Config } from "svgo";
import type { UserConfig } from "vite";
import analyzer from "vite-bundle-analyzer";
import manifest from "./package.json" with { type: "json" };
import { plg_svg2png, plg_svg2svg } from "./tools/plg.ts";
const ROOT = "../../"; // root of the git repository
const PATH = {
brand: "src/brand/",
dist: resolve(ROOT, "searx/static/themes/simple/"),
modules: "node_modules/",
src: "src/",
templates: resolve(ROOT, "searx/templates/simple/")
} as const;
const svg2svg_opts: Config = {
plugins: [{ name: "preset-default" }, "sortAttrs", "convertStyleToAttrs"]
};
const svg2svg_favicon_opts: Config = {
plugins: [{ name: "preset-default" }, "sortAttrs"]
};
export default {
base: "./",
publicDir: "static/",
build: {
target: browserslistToEsbuild(manifest.browserslist),
assetsDir: "",
outDir: PATH.dist,
manifest: "manifest.json",
emptyOutDir: true,
sourcemap: true,
rolldownOptions: {
input: {
// entrypoint
core: `${PATH.src}/js/index.ts`,
// stylesheets
ltr: `${PATH.src}/less/style-ltr.less`,
rtl: `${PATH.src}/less/style-rtl.less`,
rss: `${PATH.src}/less/rss.less`
},
// file naming conventions / pathnames are relative to outDir (PATH.dist)
output: {
entryFileNames: "sxng-[name].min.js",
chunkFileNames: "chunk/[hash].min.js",
assetFileNames: ({ names }: PreRenderedAsset): string => {
const [name] = names;
switch (name?.split(".").pop()) {
case "css":
return "sxng-[name].min[extname]";
default:
return "sxng-[name][extname]";
}
},
sanitizeFileName: (name: string): string => {
return name
.normalize("NFD")
.replace(/[^a-zA-Z0-9.-]/g, "_")
.toLowerCase();
},
comments: {
legal: true
}
}
}
}, // end: build
plugins: [
// -- bundle analyzer
analyzer({
enabled: process.env.VITE_BUNDLE_ANALYZE === "true",
analyzerPort: "auto",
summary: true,
reportTitle: manifest.name,
// sidecars with max compression
gzipOptions: {
level: zlibConstants.Z_BEST_COMPRESSION
},
brotliOptions: {
params: {
[zlibConstants.BROTLI_PARAM_QUALITY]: zlibConstants.BROTLI_MAX_QUALITY
}
}
}),
// -- svg images
plg_svg2svg(
[
{
src: `${PATH.src}/svg/empty_favicon.svg`,
dest: `${PATH.dist}/img/empty_favicon.svg`
},
{
src: `${PATH.src}/svg/select-dark.svg`,
dest: `${PATH.dist}/img/select-dark.svg`
},
{
src: `${PATH.src}/svg/select-light.svg`,
dest: `${PATH.dist}/img/select-light.svg`
}
],
svg2svg_opts
),
// SearXNG brand (static)
plg_svg2png([
{
src: `${PATH.brand}/searxng-wordmark.svg`,
dest: `${PATH.dist}/img/favicon.png`
},
{
src: `${PATH.brand}/searxng.svg`,
dest: `${PATH.dist}/img/searxng.png`
}
]),
// SearXNG PWA Icons (static)
plg_svg2png(
[
{
src: `${PATH.brand}/searxng-wordmark.svg`,
dest: `${PATH.dist}/img/512.png`
}
],
512,
512
),
plg_svg2png(
[
{
src: `${PATH.brand}/searxng-wordmark.svg`,
dest: `${PATH.dist}/img/192.png`
}
],
192,
192
),
// -- svg
plg_svg2svg(
[
{
src: `${PATH.brand}/searxng.svg`,
dest: `${PATH.dist}/img/searxng.svg`
},
{
src: `${PATH.brand}/img_load_error.svg`,
dest: `${PATH.dist}/img/img_load_error.svg`
}
],
svg2svg_opts
),
// -- favicon
plg_svg2svg(
[
{
src: `${PATH.brand}/searxng-wordmark.svg`,
dest: `${PATH.dist}/img/favicon.svg`
}
],
svg2svg_favicon_opts
),
// -- simple templates
plg_svg2svg(
[
{
src: `${PATH.brand}/searxng-wordmark.svg`,
dest: `${PATH.templates}/searxng-wordmark.min.svg`
}
],
svg2svg_opts
)
], // end: plugins
// FIXME: missing CCS sourcemaps!!
// see: https://github.com/vitejs/vite/discussions/13845#discussioncomment-11992084
//
// what I have tried so far (see config below):
//
// - build.sourcemap
// - esbuild.sourcemap
// - css.preprocessorOptions.less.sourceMap
css: {
transformer: "lightningcss",
lightningcss: {
targets: browserslistToTargets(manifest.browserslist)
},
devSourcemap: true
} // end: css
} satisfies UserConfig;

15
container/.env.example Normal file
View File

@@ -0,0 +1,15 @@
# Read the documentation before using the `docker-compose.yml` file:
# https://docs.searxng.org/admin/installation-docker.html
#
# Additional ENVs:
# https://docs.searxng.org/admin/settings/settings_general.html#settings-general
# https://docs.searxng.org/admin/settings/settings_server.html#settings-server
# Use a specific version tag. E.g. "latest" or "2026.3.25-541c6c3cb".
#SEARXNG_VERSION=latest
# Listen to a specific address.
#SEARXNG_HOST=[::]
# Listen to a specific port.
#SEARXNG_PORT=8080

View File

@@ -1,100 +0,0 @@
FROM docker.io/library/python:3.13-slim AS builder
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
build-essential \
brotli \
# uwsgi
libpcre3-dev \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /usr/local/searxng/
COPY ./requirements.txt ./requirements.txt
RUN --mount=type=cache,id=pip,target=/root/.cache/pip python -m venv ./venv \
&& . ./venv/bin/activate \
&& pip install -r requirements.txt \
&& pip install "uwsgi~=2.0"
COPY ./searx/ ./searx/
ARG TIMESTAMP_SETTINGS=0
ARG TIMESTAMP_UWSGI=0
RUN python -m compileall -q searx \
&& touch -c --date=@$TIMESTAMP_SETTINGS ./searx/settings.yml \
&& touch -c --date=@$TIMESTAMP_UWSGI ./container/uwsgi.ini \
&& find /usr/local/searxng/searx/static \
\( -name '*.html' -o -name '*.css' -o -name '*.js' -o -name '*.svg' -o -name '*.ttf' -o -name '*.eot' \) \
-type f -exec gzip -9 -k {} + -exec brotli --best {} +
ARG SEARXNG_UID=977
ARG SEARXNG_GID=977
RUN grep -m1 root /etc/group > /tmp/.searxng.group \
&& grep -m1 root /etc/passwd > /tmp/.searxng.passwd \
&& echo "searxng:x:$SEARXNG_GID:" >> /tmp/.searxng.group \
&& echo "searxng:x:$SEARXNG_UID:$SEARXNG_GID:searxng:/usr/local/searxng:/bin/bash" >> /tmp/.searxng.passwd
FROM docker.io/library/python:3.13-slim
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
# healthcheck
wget \
# uwsgi
libpcre3 \
libxml2 \
mailcap \
&& rm -rf /var/lib/apt/lists/*
COPY --chown=root:root --from=builder /tmp/.searxng.passwd /etc/passwd
COPY --chown=root:root --from=builder /tmp/.searxng.group /etc/group
ARG LABEL_DATE="0001-01-01T00:00:00Z"
ARG GIT_URL="unspecified"
ARG SEARXNG_GIT_VERSION="unspecified"
ARG LABEL_VCS_REF="unspecified"
ARG LABEL_VCS_URL="unspecified"
WORKDIR /usr/local/searxng/
COPY --chown=searxng:searxng --from=builder /usr/local/searxng/venv/ ./venv/
COPY --chown=searxng:searxng --from=builder /usr/local/searxng/searx/ ./searx/
COPY --chown=searxng:searxng ./container/ ./container/
LABEL org.opencontainers.image.authors="searxng <$GIT_URL>" \
org.opencontainers.image.created=$LABEL_DATE \
org.opencontainers.image.description="A privacy-respecting, hackable metasearch engine" \
org.opencontainers.image.documentation="https://github.com/searxng/searxng-docker" \
org.opencontainers.image.licenses="AGPL-3.0-or-later" \
org.opencontainers.image.revision=$LABEL_VCS_REF \
org.opencontainers.image.source=$LABEL_VCS_URL \
org.opencontainers.image.title="searxng" \
org.opencontainers.image.url=$LABEL_VCS_URL \
org.opencontainers.image.version=$SEARXNG_GIT_VERSION
ENV CONFIG_PATH=/etc/searxng \
DATA_PATH=/var/cache/searxng
ENV SEARXNG_VERSION=$SEARXNG_GIT_VERSION \
INSTANCE_NAME=searxng \
AUTOCOMPLETE="" \
BASE_URL="" \
BIND_ADDRESS=[::]:8080 \
MORTY_KEY="" \
MORTY_URL="" \
SEARXNG_SETTINGS_PATH=$CONFIG_PATH/settings.yml \
UWSGI_SETTINGS_PATH=$CONFIG_PATH/uwsgi.ini \
UWSGI_WORKERS=%k \
UWSGI_THREADS=4
VOLUME $CONFIG_PATH
VOLUME $DATA_PATH
EXPOSE 8080
HEALTHCHECK CMD wget --quiet --tries=1 --spider http://localhost:8080/healthz || exit 1
ENTRYPOINT ["/usr/local/searxng/container/docker-entrypoint.sh"]

View File

@@ -0,0 +1,34 @@
FROM ghcr.io/searxng/base:searxng-builder AS builder
COPY ./requirements.txt ./requirements-server.txt ./
ENV UV_NO_MANAGED_PYTHON="true"
ENV UV_NATIVE_TLS="true"
ARG TIMESTAMP_VENV="0"
RUN --mount=type=cache,id=uv,target=/root/.cache/uv set -eux -o pipefail; \
export SOURCE_DATE_EPOCH="$TIMESTAMP_VENV"; \
uv venv; \
uv pip install --requirements ./requirements.txt --requirements ./requirements-server.txt; \
uv cache prune --ci; \
find ./.venv/lib/ -type f -exec strip --strip-unneeded {} + || true; \
find ./.venv/lib/ -type d -name "__pycache__" -exec rm -rf {} +; \
find ./.venv/lib/ -type f -name "*.pyc" -delete; \
python -m compileall -q -f -j 0 --invalidation-mode=unchecked-hash ./.venv/lib/; \
find ./.venv/lib/python*/site-packages/*.dist-info/ -type f -name "RECORD" -exec sort -t, -k1,1 -o {} {} \;; \
find ./.venv/ -exec touch -h --date="@$TIMESTAMP_VENV" {} +
COPY --exclude=./searx/version_frozen.py ./searx/ ./searx/
ARG TIMESTAMP_SETTINGS="0"
RUN set -eux -o pipefail; \
python -m compileall -q -f -j 0 --invalidation-mode=unchecked-hash ./searx/; \
find ./searx/static/ -type f \
\( -name "*.html" -o -name "*.css" -o -name "*.js" -o -name "*.svg" \) \
-exec gzip -9 -k {} + \
-exec brotli -9 -k {} + \
-exec gzip --test {}.gz + \
-exec brotli --test {}.br +; \
touch -c --date="@$TIMESTAMP_SETTINGS" ./searx/settings.yml

44
container/dist.dockerfile Normal file
View File

@@ -0,0 +1,44 @@
ARG CONTAINER_IMAGE_ORGANIZATION="searxng"
ARG CONTAINER_IMAGE_NAME="searxng"
FROM localhost/$CONTAINER_IMAGE_ORGANIZATION/$CONTAINER_IMAGE_NAME:builder AS builder
FROM ghcr.io/searxng/base:searxng AS dist
COPY --chown=977:977 --from=builder /usr/local/searxng/.venv/ ./.venv/
COPY --chown=977:977 --from=builder /usr/local/searxng/searx/ ./searx/
COPY --chown=977:977 ./container/ ./
COPY --chown=977:977 ./searx/version_frozen.py ./searx/
ARG CREATED="0001-01-01T00:00:00Z"
ARG VERSION="unknown"
ARG VCS_URL="unknown"
ARG VCS_REVISION="unknown"
LABEL org.opencontainers.image.created="$CREATED" \
org.opencontainers.image.description="SearXNG is a metasearch engine. Users are neither tracked nor profiled." \
org.opencontainers.image.documentation="https://docs.searxng.org/admin/installation-docker" \
org.opencontainers.image.licenses="AGPL-3.0-or-later" \
org.opencontainers.image.revision="$VCS_REVISION" \
org.opencontainers.image.source="$VCS_URL" \
org.opencontainers.image.title="SearXNG" \
org.opencontainers.image.url="https://searxng.org" \
org.opencontainers.image.version="$VERSION"
ENV __SEARXNG_VERSION="$VERSION" \
__SEARXNG_SETTINGS_PATH="$__SEARXNG_CONFIG_PATH/settings.yml" \
GRANIAN_PROCESS_NAME="searxng" \
GRANIAN_INTERFACE="wsgi" \
GRANIAN_HOST="::" \
GRANIAN_PORT="8080" \
GRANIAN_WEBSOCKETS="false" \
GRANIAN_BLOCKING_THREADS="4" \
GRANIAN_WORKERS_KILL_TIMEOUT="30s" \
GRANIAN_BLOCKING_THREADS_IDLE_TIMEOUT="5m"
# "*_PATH" ENVs are defined in base images
VOLUME $__SEARXNG_CONFIG_PATH
VOLUME $__SEARXNG_DATA_PATH
EXPOSE 8080
ENTRYPOINT ["/usr/local/searxng/entrypoint.sh"]

View File

@@ -0,0 +1,28 @@
# Read the documentation before using the `docker-compose.yml` file:
# https://docs.searxng.org/admin/installation-docker.html
name: searxng
services:
core:
container_name: searxng-core
image: docker.io/searxng/searxng:${SEARXNG_VERSION:-latest}
restart: always
ports:
- ${SEARXNG_HOST:+${SEARXNG_HOST}:}${SEARXNG_PORT:-8080}:${SEARXNG_PORT:-8080}
env_file: ./.env
volumes:
- ./core-config/:/etc/searxng/:Z
- core-data:/var/cache/searxng/
valkey:
container_name: searxng-valkey
image: docker.io/valkey/valkey:9-alpine
command: valkey-server --save 30 1 --loglevel warning
restart: always
volumes:
- valkey-data:/data/
volumes:
core-data:
valkey-data:

Some files were not shown because too many files have changed in this diff Show More