# mypy: disable-error-code="misc, override, attr-defined, no-redef, assignment"

import BaseFarmPlugin as BaseFarmPlugin
import FarmAPI.FarmPluginManager
from _typeshed import Incomplete
from typing import ClassVar, Set, Tuple

class BaseFarmPlugin:
    class InstallationMetadata:
        def __init__(self, katanaRoot: str, renderPluginDsoPaths, renderbootCommand: Incomplete | None = ...) -> None: ...
    def copyRenderFiles(self, filenames: list[str], renderContextName: str): ...
    def createTemporaryDirectory(self, renderContextName: str) -> str: ...
    def getEnvironmentForJob(self, renderContextName: str): ...
    def getJobState(self, jobId: str) -> str: ...
    def getJobs(self, filters: list) -> list: ...
    def getRemoteInstallationMetadata(self) -> BaseFarmPlugin.InstallationMetadata: ...
    def getRenderLogFilename(self, jobId: str) -> str | None: ...
    def startJob(self, jobId: str): ...
    def stopJob(self, jobId: str): ...
    def submitJob(self, jobRequest: FarmAPI.FarmPluginManager.JobRequest) -> str: ...

class FarmPluginException(Exception): ...

class Job:
    class State:
        kAllStates: ClassVar[tuple] = ...
        kCancelled: ClassVar[str] = ...
        kCompleted: ClassVar[str] = ...
        kFailed: ClassVar[str] = ...
        kRunning: ClassVar[str] = ...
        kWaiting: ClassVar[str] = ...
    def __init__(self, jobId: str, name: str, startTime: int, endTime: int, state: str, renderLogFilename: str) -> None: ...

class JobNotFoundException(FarmPluginException):
    def __init__(self, jobId: str, contextMessage: str) -> None: ...
