runtraj.execution.Backend#

class runtraj.execution.Backend[source]#

A place a project’s releases run: a scheduler that starts runtraj run --task i/N tasks.

A subclass sets name and config_class and writes submit(). A backend that can wait for what it started (runtraj run) sets waits and writes run(); one that can list its jobs for runtraj status writes jobs().

Attributes#

config_class

The class of its block, a runtraj.execution.BackendConfig.

here

Whether the releases run in this process, with no tasks to start.

name

The name of its block under execution, such as slurm.

takes_releases

Whether submit() takes a list of releases and skip_existing=False.

waits

Whether run() waits for the tasks, so runtraj run can use it.

Methods#

describe(waits)

Return the line runtraj run and runtraj submit print on what they do next.

jobs(project, execution)

Return the project's jobs for runtraj status, oldest first, or None when it lists none.

run(project, releases, execution, *, ...)

Run releases and wait for them, then return their status table (runtraj.Project.status()).

submit(project, releases, execution, *, ...)

Start the tasks that run releases, and return what names them, such as a job id.