kryten-webqueue 0.2.2__tar.gz → 0.2.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/PKG-INFO +1 -1
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/app.py +1 -1
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/catalog/sync.py +12 -3
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/pyproject.toml +1 -1
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/.github/workflows/python-publish.yml +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/.github/workflows/release.yml +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/.gitignore +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/README.md +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/config.example.json +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/deploy/kryten-webqueue.service +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/deploy/nginx-queue.conf +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/docs/IMPLEMENTATION_SPEC.md +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/docs/IMPL_API_GATE.md +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/docs/IMPL_ECONOMY.md +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/docs/IMPL_KRYTEN_PY.md +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/docs/IMPL_ROBOT.md +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/docs/PRE_PLAN_GAPS.md +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/docs/PRODUCT_PLAN.md +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/__init__.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/__main__.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/api_gate/__init__.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/api_gate/client.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/auth/__init__.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/auth/otp.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/auth/rate_limit.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/auth/session.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/catalog/__init__.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/catalog/db.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/catalog/images.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/config.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/playlists/__init__.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/playlists/fire.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/playlists/importer.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/playlists/scheduler.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/queue/__init__.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/queue/ordering.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/queue/poller.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/queue/shadow.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/routes/__init__.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/routes/admin_playlists.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/routes/admin_queue.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/routes/admin_schedules.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/routes/auth.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/routes/catalog.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/routes/pages.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/routes/queue.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/routes/user.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/static/css/main.css +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/static/js/main.js +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/templates/admin/index.html +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/templates/auth/login.html +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/templates/base.html +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/templates/catalog/browse.html +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/templates/queue/index.html +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/templates/user/dashboard.html +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/ws/__init__.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/ws/handler.py +0 -0
- {kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/ws/manager.py +0 -0
|
@@ -96,7 +96,7 @@ async def lifespan(app: FastAPI):
|
|
|
96
96
|
try:
|
|
97
97
|
await catalog_sync.sync()
|
|
98
98
|
except Exception as e:
|
|
99
|
-
logger.
|
|
99
|
+
logger.exception(f"Catalog sync error: {type(e).__name__}: {e}")
|
|
100
100
|
await asyncio.sleep(interval)
|
|
101
101
|
|
|
102
102
|
async def _otp_cleanup_loop():
|
|
@@ -9,7 +9,13 @@ class CatalogSync:
|
|
|
9
9
|
"""Synchronizes catalog data from MediaCMS."""
|
|
10
10
|
|
|
11
11
|
def __init__(self, *, mediacms_url: str, mediacms_token: str, db):
|
|
12
|
-
|
|
12
|
+
# Strip any accidental /api/v1 suffix — the sync code appends it itself
|
|
13
|
+
url = mediacms_url.rstrip("/")
|
|
14
|
+
for suffix in ("/api/v1", "/api"):
|
|
15
|
+
if url.endswith(suffix):
|
|
16
|
+
url = url[: -len(suffix)]
|
|
17
|
+
break
|
|
18
|
+
self._url = url
|
|
13
19
|
self._token = mediacms_token
|
|
14
20
|
self._db = db
|
|
15
21
|
self._client = httpx.AsyncClient(
|
|
@@ -33,7 +39,10 @@ class CatalogSync:
|
|
|
33
39
|
params={"page": page, "page_size": 50},
|
|
34
40
|
)
|
|
35
41
|
if resp.status_code != 200:
|
|
36
|
-
logger.error(
|
|
42
|
+
logger.error(
|
|
43
|
+
f"MediaCMS API returned {resp.status_code} for URL {resp.url} — "
|
|
44
|
+
f"body: {resp.text[:200]}"
|
|
45
|
+
)
|
|
37
46
|
stats["errors"] += 1
|
|
38
47
|
break
|
|
39
48
|
|
|
@@ -59,7 +68,7 @@ class CatalogSync:
|
|
|
59
68
|
await self._db.finish_sync_log(log_id, stats, "completed")
|
|
60
69
|
logger.info(f"Catalog sync: {stats}")
|
|
61
70
|
except Exception as e:
|
|
62
|
-
logger.
|
|
71
|
+
logger.exception(f"Catalog sync failed: {type(e).__name__}: {e}")
|
|
63
72
|
stats["errors"] += 1
|
|
64
73
|
await self._db.finish_sync_log(log_id, stats, "error")
|
|
65
74
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/templates/catalog/browse.html
RENAMED
|
File without changes
|
|
File without changes
|
{kryten_webqueue-0.2.2 → kryten_webqueue-0.2.4}/kryten_webqueue/templates/user/dashboard.html
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|