summaryrefslogtreecommitdiff
path: root/searxng_extra
diff options
context:
space:
mode:
Diffstat (limited to 'searxng_extra')
-rwxr-xr-xsearxng_extra/update/update_ahmia_blacklist.py2
-rwxr-xr-xsearxng_extra/update/update_firefox_version.py3
2 files changed, 4 insertions, 1 deletions
diff --git a/searxng_extra/update/update_ahmia_blacklist.py b/searxng_extra/update/update_ahmia_blacklist.py
index 26c485195..a11413f14 100755
--- a/searxng_extra/update/update_ahmia_blacklist.py
+++ b/searxng_extra/update/update_ahmia_blacklist.py
@@ -9,6 +9,7 @@ Output file: :origin:`searx/data/ahmia_blacklist.txt` (:origin:`CI Update data
.. _Ahmia's blacklist: https://ahmia.fi/blacklist/
"""
+# pylint: disable=use-dict-literal
from os.path import join
@@ -21,6 +22,7 @@ URL = 'https://ahmia.fi/blacklist/banned/'
def fetch_ahmia_blacklist():
resp = requests.get(URL, timeout=3.0)
if resp.status_code != 200:
+ # pylint: disable=broad-exception-raised
raise Exception("Error fetching Ahmia blacklist, HTTP code " + resp.status_code)
return resp.text.split()
diff --git a/searxng_extra/update/update_firefox_version.py b/searxng_extra/update/update_firefox_version.py
index 384d0002f..51aec39c5 100755
--- a/searxng_extra/update/update_firefox_version.py
+++ b/searxng_extra/update/update_firefox_version.py
@@ -1,13 +1,13 @@
#!/usr/bin/env python
# lint: pylint
# SPDX-License-Identifier: AGPL-3.0-or-later
-
"""Fetch firefox useragent signatures
Output file: :origin:`searx/data/useragents.json` (:origin:`CI Update data ...
<.github/workflows/data-update.yml>`).
"""
+# pylint: disable=use-dict-literal
import json
import re
@@ -40,6 +40,7 @@ useragents = {
def fetch_firefox_versions():
resp = requests.get(URL, timeout=2.0)
if resp.status_code != 200:
+ # pylint: disable=broad-exception-raised
raise Exception("Error fetching firefox versions, HTTP code " + resp.status_code)
dom = html.fromstring(resp.text)
versions = []