From 45c33a4fca5314f7b0ae75a064a9575b034afb25 Mon Sep 17 00:00:00 2001 From: Michal Zukowski Date: Tue, 17 Mar 2026 09:40:51 +0100 Subject: [PATCH] Stop scraping luxor --- app/src/infinite_hashes/settings.py | 21 ++++++++++++--------- app/src/infinite_hashes/validator/tasks.py | 3 +++ 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/app/src/infinite_hashes/settings.py b/app/src/infinite_hashes/settings.py index 4ee91b1..69083e7 100644 --- a/app/src/infinite_hashes/settings.py +++ b/app/src/infinite_hashes/settings.py @@ -332,14 +332,15 @@ def wrapped(*args, **kwargs): "expires": datetime.timedelta(minutes=1).total_seconds(), }, }, - # Luxor hashrate scraper - "scrape_luxor": { - "task": "infinite_hashes.validator.tasks.scrape_luxor", - "schedule": datetime.timedelta(seconds=20), - "options": { - "expires": datetime.timedelta(seconds=40).total_seconds(), - }, - }, + # Disabled temporarily: Luxor scraping is turned off for now, but we are + # keeping the implementation in place so it can be restored quickly if needed. + # "scrape_luxor": { + # "task": "infinite_hashes.validator.tasks.scrape_luxor", + # "schedule": datetime.timedelta(seconds=20), + # "options": { + # "expires": datetime.timedelta(seconds=40).total_seconds(), + # }, + # }, "cleanup_old_luxor_snapshots": { "task": "infinite_hashes.validator.tasks.cleanup_old_luxor_snapshots", "schedule": datetime.timedelta(hours=1), @@ -362,7 +363,9 @@ def wrapped(*args, **kwargs): CELERY_TASK_DEFAULT_ROUTING_KEY = "default" CELERY_TASK_DEFAULT_RATE_LIMIT = "1/s" CELERY_TASK_ROUTES = { - "infinite_hashes.validator.tasks.scrape_luxor": {"queue": "luxor"}, + # Disabled temporarily: Luxor scraping is turned off for now, but we are + # keeping the implementation in place so it can be restored quickly if needed. + # "infinite_hashes.validator.tasks.scrape_luxor": {"queue": "luxor"}, "infinite_hashes.validator.tasks.cleanup_old_luxor_snapshots": {"queue": "luxor"}, "infinite_hashes.validator.tasks.calculate_weights": {"queue": "weights"}, "infinite_hashes.validator.tasks.set_weights": {"queue": "weights"}, diff --git a/app/src/infinite_hashes/validator/tasks.py b/app/src/infinite_hashes/validator/tasks.py index 807a013..f766fd7 100644 --- a/app/src/infinite_hashes/validator/tasks.py +++ b/app/src/infinite_hashes/validator/tasks.py @@ -1339,6 +1339,9 @@ def parse_last_updated(value: Any) -> datetime.datetime | None: raise +# Luxor scraping is currently disabled in Celery beat/routing, but we are +# keeping this task implementation in place temporarily so it can be restored +# quickly if needed. @app.task(autoretry_for=(httpx.HTTPStatusError,)) def scrape_luxor(subaccount_name: str | None = None) -> int: """Celery task to scrape Luxor hashrate data."""