home · contact · privacy
Fix sync script bug of trying to JSONize pathlib.Path objects.
authorChristian Heller <c.heller@plomlompom.de>
Sun, 1 Dec 2024 01:35:21 +0000 (02:35 +0100)
committerChristian Heller <c.heller@plomlompom.de>
Sun, 1 Dec 2024 01:35:21 +0000 (02:35 +0100)
src/ytplom/http.py

index 9cfc48bacd4c9fb60b9e3920201476e0953ad117..24c40b3764c02ed3ce690b9984c93fd23c5ff6c4 100644 (file)
@@ -292,7 +292,7 @@ class _TaskHandler(BaseHTTPRequestHandler):
 
     def _send_missing_json(self) -> None:
         with DbConn() as conn:
-            missing = [f.rel_path for f in VideoFile.get_all(conn)
+            missing = [str(f.rel_path) for f in VideoFile.get_all(conn)
                        if f.missing]
         self._send_http(bytes(json_dumps(missing), 'utf8'),
                         headers=[('Content-type', 'application/json')])