Skip to content

Conversation

tcely
Copy link
Contributor

@tcely tcely commented Jun 15, 2025

The idea here is to not use repeat at all.

Instead, the source is evaluated every hour to see if it should be indexed.

This should also let us stop deleting indexing tasks.

[2025-06-16 10:59:13,749] INFO:huey.consumer.Scheduler:208:Enqueueing periodic task sync.tasks.schedule_indexing: 88d70b27-2461-4b7c-9be1-bb7bc7c77e97 exp=1800 p=100.
[2025-06-16 10:59:32,823] INFO:huey:209:Executing sync.tasks.schedule_indexing: 88d70b27-2461-4b7c-9be1-bb7bc7c77e97 exp=1800 (2025-06-16 11:29:13.750442) p=100
[2025-06-16 10:59:32,945] INFO:huey:209:sync.tasks.schedule_indexing: 88d70b27-2461-4b7c-9be1-bb7bc7c77e97 exp=1800 (2025-06-16 11:29:13.750442) p=100 executed in 0.121s
[2025-06-16 12:59:26,448] INFO:huey.consumer.Scheduler:6350:Enqueueing periodic task sync.tasks.schedule_indexing: 6d2f7fcb-1fa1-42d4-aa6e-544bb6108de2 exp=1800 p=100.
[2025-06-16 12:59:40,863] INFO:huey:6351:Executing sync.tasks.schedule_indexing: 6d2f7fcb-1fa1-42d4-aa6e-544bb6108de2 exp=1800 (2025-06-16 13:29:26.451387) p=100
2025-06-16 12:59:40,921 [tubesync/INFO] Scheduling an indexing task for source "@NAME": 2b0d4ae5-85f0-43a9-bfa8-cce3dd83dfa5
[2025-06-16 12:59:41,106] INFO:huey:6351:sync.tasks.schedule_indexing: 6d2f7fcb-1fa1-42d4-aa6e-544bb6108de2 exp=1800 (2025-06-16 13:29:26.451387) p=100 executed in 0.240s
2025-06-16 13:09:47,169 [tubesync/INFO] Deleting completed tasks older than 7 days (run_at before 2025-06-09 13:09:47.169020+00:00)
2025-06-16 13:09:47,198 [tubesync/DEBUG] get_media_info: used date range: 2025-06-08 to 9999-12-31 for URL: https://www.youtube.com/channel/CHANNEL_ID/videos
Index media from source "@NAME"
Queue: "network"
Task locked for: 00:02:18
 Task locked at 2025-06-16 13:09:47
 Task ended at 2025-06-16 13:12:04

Delaying checking all media for database tasks
Queue: "filesystem"
Task locked for: 00:30:13
 Task locked at 2025-06-16 13:11:34
 Task ended at 2025-06-16 13:41:46

Waiting for database tasks to complete
Queue: "network"
Task locked for: 00:29:42
 Task locked at 2025-06-16 13:12:05
 Task ended at 2025-06-16 13:41:47

Checking all media for "@NAME"
Queue: "filesystem"
Task locked for: 00:07:14
 Task locked at 2025-06-16 13:47:32
 Task ended at 2025-06-16 13:54:46

Reminder: the thumbnail downloads are in the filesystem queue. That's why there is a gap of a few minutes before the checking task was locked.

@tcely tcely marked this pull request as ready for review June 15, 2025 17:21
@tcely tcely moved this to In Progress in Status Jun 15, 2025
@tcely tcely moved this from In Progress to Done in Status Jun 15, 2025
@tcely tcely moved this from Done to In Progress in Status Jun 15, 2025
@tcely tcely moved this from In Progress to Ready in Status Jun 15, 2025
@meeb meeb merged commit de0fbfb into meeb:main Jun 18, 2025
6 checks passed
@github-project-automation github-project-automation bot moved this from Ready to Done in Status Jun 18, 2025
@tcely tcely deleted the patch-4 branch June 18, 2025 14:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants