fix(worker): 修复 render_edit_plan 素材下载 + 总时长日志 + video_processing 导入链
CI/CD Pipeline / Validate Code Quality And Tests (pull_request) Failing after 42s
CI/CD Pipeline / Production Browser E2E (pull_request) Failing after 1574h44m6s
CI/CD Pipeline / Staging API Integration Tests (pull_request) Failing after 1574h44m8s
CI/CD Pipeline / Staging E2E Tests (pull_request) Failing after 1574h44m8s
CI/CD Pipeline / Build Production Runtime Images (pull_request) Failing after 1574h44m10s
CI/CD Pipeline / Build & Push Staging (Watchtower auto-deploy) (pull_request) Failing after 1574h44m10s
CI/CD Pipeline / Integration Tests (pull_request) Has been skipped
CI/CD Pipeline / Frontend Lint (pull_request) Has been skipped
CI/CD Pipeline / Deploy Production (pull_request) Failing after 1575h15m43s

3 个修复:
1. render_edit_plan 素材下载路径错误:直接传 asset_id 给 download_asset,
   改为先查 assets 表拿 file_url(storage_key) 再下载
2. 总时长=0.0s 日志误导:_build_plan_and_clips_from_task 中 _VirtualClip
   的 duration 未赋值导致日志永远显示 0s,改为用 probe_duration 预探测
3. video_processing/__init__.py 导入链副作用:顶层导入 render_adapter 等
   重依赖模块,导致只想用 oss_helpers/ffmpeg_utils 等轻量工具的地方也
   被迫拉进 packages/DB 全量依赖。改为只导出轻量工具模块,渲染组件
   按需从子模块导入
This commit is contained in:
CI Bot
2026-07-13 00:36:23 +08:00
parent fdcf48103e
commit c5ee72d1fd
3 changed files with 36 additions and 13 deletions
+6 -10
View File
@@ -1,21 +1,17 @@
"""
视频处理模块
轻量工具(ffmpeg_utils / oss_helpers / dedup_helpers)顶层直接导出,
无额外依赖。渲染相关组件(UnifiedRenderService / RenderAdapter /
VideoProcessor 等)按需从子模块导入,避免 __init__ 阶段引入
packages / DB 等重依赖。
"""
# 共享工具模块(供 editing_modes / generation / edit_plan_generation 等复用)
# 共享工具模块(零外部依赖,供 editing_modes / generation / edit_plan_generation 等复用)
from . import dedup_helpers, ffmpeg_utils, oss_helpers
from .processor import VideoProcessor, VideoResult
from .render_adapter import RenderAdapter, RenderAdapterResult
from .unified_render_service import RenderResult, UnifiedRenderService
__all__ = [
"VideoProcessor",
"VideoResult",
"ffmpeg_utils",
"oss_helpers",
"dedup_helpers",
"UnifiedRenderService",
"RenderResult",
"RenderAdapter",
"RenderAdapterResult",
]