From f652ab6cb1b36dc889b6f5ec8aaff968f0a95944 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Mon, 10 Jul 2023 21:30:40 +0200 Subject: [PATCH] Continued: - handle over proper severity level --- fba/commands.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/fba/commands.py b/fba/commands.py index e4ae221..4f7e688 100644 --- a/fba/commands.py +++ b/fba/commands.py @@ -954,6 +954,9 @@ def fetch_oliphant(args: argparse.Namespace) -> int: },{ "blocker": "union.place", "csv_url": "mastodon/union.place.csv", + },{ + "blocker": "oliphant.social", + "csv_url": "mastodon/birdsite.csv", } ) @@ -968,9 +971,6 @@ def fetch_oliphant(args: argparse.Namespace) -> int: elif args.domain in domains: logger.debug("args.domain='%s' already handled - SKIPPED!", args.domain) continue - elif instances.is_recent(block["blocker"]): - logger.debug("block[blocker]='%s' has been recently crawled - SKIPPED!", block["blocker"]) - continue # Fetch this URL logger.info("Fetching csv_url='%s' for blocker='%s' ...", block["csv_url"], block["blocker"]) @@ -1051,7 +1051,7 @@ def fetch_oliphant(args: argparse.Namespace) -> int: processed = utils.process_domain(domain, block["blocker"], inspect.currentframe().f_code.co_name) logger.debug("processed='%s'", processed) - if utils.process_block(block["blocker"], domain, None, "reject") and config.get("bot_enabled"): + if utils.process_block(block["blocker"], domain, None, severity) and config.get("bot_enabled"): logger.debug("Appending blocked='%s',reason='%s' for blocker='%s' ...", domain, block["block_level"], block["blocker"]) blockdict.append({ "blocked": domain, -- 2.39.5