From b45bff2a374a6b80e85136385a054a948fe87cd0 Mon Sep 17 00:00:00 2001 From: wangguangyuan Date: Wed, 8 Jul 2026 17:52:45 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E8=BF=9B=E5=BA=A6=E6=8A=A5=E9=94=99?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/tasks.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/tasks.py b/app/tasks.py index a919e28..56e0777 100644 --- a/app/tasks.py +++ b/app/tasks.py @@ -277,9 +277,10 @@ def analyze_video_file( processed_frames += 1 progress = int((frame_count / total_frames) * 100) - + + current_progress = self.request.meta.get('progress', 0) if hasattr(self.request, 'meta') else 0 # 更新进度(每10%更新一次) - if progress % 10 == 0 and progress != self.request.meta.get('progress', 0): + if progress % 10 == 0 and progress != current_progress: self.update_state( state='PROCESSING', meta={