Heuristic:869413421 Ai moive studio Warning Deprecated Legacy Video Query
| Knowledge Sources | |
|---|---|
| Domains | Deprecation, Video_Generation |
| Last Updated | 2026-10-23 12:00 GMT |
Overview
Deprecation warning for LegacyVideoQuery — a read-only recovery adapter used only for video tasks submitted before protocol snapshots existed.
Description
The LegacyVideoQuery class in backend/src/services/provider/legacy_video.py is a legacy fallback used by ProviderFactory.resume_video() when a video task lacks a protocol context snapshot. It queries the old Vectorengine API directly without the unified gateway abstraction. New video tasks always include a protocol context and use GatewayProvider instead.
Usage
Apply this warning when maintaining or refactoring the provider factory. Do not extend LegacyVideoQuery with new functionality. When all pre-snapshot video tasks have completed or expired, this class and its fallback path in resume_video() should be removed entirely.
The Insight (Rule of Thumb)
- Action: Do not add new features to LegacyVideoQuery; route all new video tasks through GatewayProvider with protocol context snapshots.
- Value: N/A — this is a deprecation boundary, not a configuration.
- Trade-off: Keeping the fallback allows old tasks to be queried, but adds maintenance burden and a divergent code path.
- Cleanup Trigger: Remove legacy_video.py and the fallback branch in resume_video() once no active video tasks predate protocol snapshots.
Reasoning
The provider unification plan (see docs/model-provider-unification-plan.md) introduced protocol context snapshots so that video task polling can use the same GatewayProvider abstraction as all other generation operations. LegacyVideoQuery exists solely as a bridge for tasks created before this migration. The factory code comment explicitly states: "Only historical tasks lacking a snapshot use the old query contract."