|
1 | 1 | # pylint: disable=too-few-public-methods, missing-module-docstring, broad-exception-caught,invalid-name
|
2 | 2 |
|
3 | 3 | from enum import Enum
|
4 |
| -from typing import Optional, Dict, Any, Union, Literal |
| 4 | +from typing import Optional, Dict, Any, Union, Literal, List |
5 | 5 | from dataclasses import dataclass, field
|
6 | 6 | from .version import VERSION
|
7 | 7 |
|
@@ -534,26 +534,26 @@ class RenderStillResponse:
|
534 | 534 | outKey: str
|
535 | 535 |
|
536 | 536 |
|
| 537 | +@dataclass |
537 | 538 | class RenderMediaProgress:
|
538 | 539 | """
|
539 | 540 | Progress of video rendering.
|
540 | 541 | """
|
541 | 542 |
|
542 |
| - def __init__(self): |
543 |
| - self.overallProgress = float() |
544 |
| - self.chunks = int() |
545 |
| - self.done = bool() |
546 |
| - self.encodingStatus = None |
547 |
| - self.costs = None |
548 |
| - self.renderId = str() |
549 |
| - self.renderMetadata = None |
550 |
| - self.outputFile = None |
551 |
| - self.outKey = None |
552 |
| - self.timeToFinish = None |
553 |
| - self.errors = [] |
554 |
| - self.fatalErrorEncountered = bool() |
555 |
| - self.currentTime = int() |
556 |
| - self.renderSize = int() |
557 |
| - self.outputSizeInBytes = None |
558 |
| - self.lambdasInvoked = int() |
559 |
| - self.framesRendered = None |
| 543 | + overallProgress: float = 0.0 |
| 544 | + chunks: int = 0 |
| 545 | + done: bool = False |
| 546 | + encodingStatus: Optional[Any] = None |
| 547 | + costs: Optional[Any] = None |
| 548 | + renderId: str = "" |
| 549 | + renderMetadata: Optional[Any] = None |
| 550 | + outputFile: Optional[Any] = None |
| 551 | + outKey: Optional[str] = None |
| 552 | + timeToFinish: Optional[float] = None |
| 553 | + errors: List[Any] = field(default_factory=list) |
| 554 | + fatalErrorEncountered: bool = False |
| 555 | + currentTime: int = 0 |
| 556 | + renderSize: int = 0 |
| 557 | + outputSizeInBytes: Optional[int] = None |
| 558 | + lambdasInvoked: int = 0 |
| 559 | + framesRendered: Optional[int] = None |
0 commit comments