From 52f4a319af9fd9ff35e39ed8c104c8ebbf469ca7 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Thu, 25 May 2023 22:52:56 +0200 Subject: [PATCH] Continued: - added 'GENERATOR' as "detection mode" - explained NULL in 'detection_mode' --- fba.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/fba.py b/fba.py index 502b9b2..96e7f29 100644 --- a/fba.py +++ b/fba.py @@ -48,7 +48,8 @@ headers = { # written to database. Both arrays must be filled at the same time or else # update_nodeinfos() will fail nodeinfos = { - # Detection mode: AUTO_DISCOVERY or STATIC_CHECKS + # Detection mode: 'AUTO_DISCOVERY', 'STATIC_CHECKS' or 'GENERATOR' + # NULL means all detection methods have failed (maybe still reachable instance) "detection_mode": {}, # Found nodeinfo URL "nodeinfo_url": {}, @@ -468,6 +469,7 @@ def fetch_generator_from_path(domain: str, path: str = "/") -> str: # NOISY-DEBUG: print("DEBUG: Found generator meta tag: ", domain) software = tidyup(tag.get("content")) # NOISY-DEBUG: print(f"DEBUG: software='{software}'") + nodeinfos["detection_mode"] = "GENERATOR" remove_pending_error(domain) except BaseException as e: -- 2.39.5