kkrunner.runs.Executor

class kkrunner.runs.Executor[source]

Bases: object

Execution backend. It never knows application readers or result types.

name = None
supports_result_file_retrieval = False
fetch_result_files(run, files, *, destinations=None)[source]

Retrieve files, optionally staging each canonical local path.

destinations maps requested local paths to alternate local targets; the requested paths still select the remote sources. The caller owns verification and publication of staged downloads.

submission_directory(spec)[source]
Parameters:

spec (ExecutionSpec)

Return type:

str

resolve_mpi(mpi=None)[source]
status(*runs)[source]
Return type:

Tuple[RunStatus, …]

recover_submission(run_id, submission, *, submitted_at=None)[source]
Return type:

RunStatus | None

create_managed_run(spec, *, run_id, callback=None)[source]

Create backend execution for a caller-supplied persistent run ID.

RunManager owns the durable record; project membership is optional. Backends can override this hook to provide supervision and receipts.

Parameters:
Return type:

Runner

create_run(spec, callback=None)[source]
Parameters:

spec (ExecutionSpec)

Return type:

Runner

attach(run, callback=None, output_listener=None, start=True)[source]
Return type:

Runner