INNER CODE UNIT · Python

Job

renezander030/capcut-cli · python/capcut/__init__.py:237

class Job:
    """One line of the ``capcut serve`` JSONL queue."""

    cmd: str
    project: Optional[str] = None
    args: Sequence[Any] = field(default_factory=list)
    id: Optional[str] = None
    retries: Optional[int] = None
    timeout: Optional[int] = None

    def to_dict(self) -> dict:
        job: dict = {"cmd": self.cmd}
        if self.project is not None:
            job["project"] = self.project
        if self.args:
            job["args"] = [str(a) for a in self.args]
        if self.id is not None:
            job["id"] = self.id

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…