From cf2027d95b7ab0082359a5ba81e88d72379659fe Mon Sep 17 00:00:00 2001 From: Ethan Dalool Date: Sat, 24 May 2025 10:31:35 -0700 Subject: [PATCH] Update shorts search duration to three minutes. --- frontends/ycdl_flask/backend/common.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/frontends/ycdl_flask/backend/common.py b/frontends/ycdl_flask/backend/common.py index 81ce48e..2d651db 100644 --- a/frontends/ycdl_flask/backend/common.py +++ b/frontends/ycdl_flask/backend/common.py @@ -136,7 +136,7 @@ def ignore_shorts_thread(rate): videos = ycdldb.get_videos_by_sql(''' SELECT * FROM videos LEFT JOIN channels ON channels.id = videos.author_id - WHERE is_shorts IS NULL AND duration < 62 AND state = "pending" AND channels.ignore_shorts = 1 + WHERE is_shorts IS NULL AND duration < 182 AND state = "pending" AND channels.ignore_shorts = 1 ORDER BY published DESC LIMIT 10 ''') @@ -145,6 +145,8 @@ def ignore_shorts_thread(rate): time.sleep(rate) continue + log.debug('Checking %d videos for shorts.', len(videos)) + with ycdldb.transaction: for video in videos: try: