fix: make source_ms optional for backward compatibility with existing jobs
Existing jobs in the database don't have source_ms field. Making it optional allows the API to load these jobs without validation errors. The re-render task already handles the fallback to original_ms when source_ms is None. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
a6cd4cde07
commit
f47820a6a4
3 changed files with 3 additions and 3 deletions
|
|
@ -69,7 +69,7 @@ class PausePointData(BaseModel):
|
|||
"""Pause point timing data for accessible video editing during QC."""
|
||||
cue_index: int # AD cue index this pause point belongs to
|
||||
original_ms: float # Rendered timeline position (ms) - for UI display
|
||||
source_ms: float # Source video cut point (ms) - for re-rendering
|
||||
source_ms: Optional[float] = None # Source video cut point (ms) - for re-rendering (None = use original_ms)
|
||||
adjusted_ms: Optional[float] = None # User-adjusted timestamp (ms), None = use original
|
||||
min_bound_ms: float # Minimum allowed value (end of previous AD segment)
|
||||
max_bound_ms: float # Maximum allowed value (start of next AD segment)
|
||||
|
|
|
|||
|
|
@ -131,7 +131,7 @@ class PausePointResponse(BaseModel):
|
|||
"""Pause point timing data for QC editing."""
|
||||
cue_index: int = Field(..., description="AD cue index this pause point belongs to")
|
||||
original_ms: float = Field(..., description="Rendered timeline position (ms) - for display")
|
||||
source_ms: float = Field(..., description="Source video cut point (ms) - for re-rendering")
|
||||
source_ms: Optional[float] = Field(None, description="Source video cut point (ms) - for re-rendering (None = use original_ms)")
|
||||
adjusted_ms: Optional[float] = Field(None, description="User-adjusted timestamp (ms)")
|
||||
min_bound_ms: float = Field(..., description="Minimum allowed value (ms)")
|
||||
max_bound_ms: float = Field(..., description="Maximum allowed value (ms)")
|
||||
|
|
|
|||
|
|
@ -337,7 +337,7 @@ export interface ReviewNotesListResponse {
|
|||
export interface PausePointData {
|
||||
cue_index: number;
|
||||
original_ms: number; // Rendered timeline position (for display)
|
||||
source_ms: number; // Source video cut point (for re-rendering)
|
||||
source_ms: number | null; // Source video cut point (for re-rendering), null = use original_ms
|
||||
adjusted_ms: number | null;
|
||||
min_bound_ms: number;
|
||||
max_bound_ms: number;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue