First attempt at converting "sig" to "activity" for v3

This commit is contained in:
Ian Renton
2026-09-24 07:09:37 +01:00
parent 1d0129f7bb
commit d91fa70655
90 changed files with 822 additions and 496 deletions
+7 -5
View File
@@ -1,6 +1,6 @@
import re
from webserver.handlers.api.spots import APISpotsHandler, APISpotsStreamHandler
from webserver.handlers.api.v2_compatibility import V2APISpotsHandler, V2APISpotsStreamHandler
_GRID_SOURCE_RE = re.compile(r'"dx_location_source":\s*"GRID"')
_LEGACY_PARAM_TO_HEADER_MAP = {
@@ -24,8 +24,9 @@ def _handle_legacy_params(handler):
handler.request.headers[header] = value
class V1APISpotsHandler(APISpotsHandler):
"""API request handler for /api/v1/spots (GET). Included in early Spothole v2 for backwards compatibility."""
class V1APISpotsHandler(V2APISpotsHandler):
"""API request handler for /api/v1/spots (GET). Included in Spothole v2 onwards for backwards
compatibility."""
def prepare(self):
_handle_legacy_params(self)
@@ -37,8 +38,9 @@ class V1APISpotsHandler(APISpotsHandler):
super().write(chunk)
class V1APISpotsStreamHandler(APISpotsStreamHandler):
"""API request handler for /api/v1/spots/stream (SSE). Included in early Spothole v2 for backwards compatibility."""
class V1APISpotsStreamHandler(V2APISpotsStreamHandler):
"""API request handler for /api/v1/spots/stream (SSE). Included in Spothole v2 onwards for backwards
compatibility."""
def prepare(self):
_handle_legacy_params(self)