Skip to content

feat(task): add CONFIGURING status for environment setup before execution - #186

Merged
chdominguez merged 1 commit into
mainfrom
task-status-configuring
Sep 2, 2026
Merged

feat(task): add CONFIGURING status for environment setup before execution#186
chdominguez merged 1 commit into
mainfrom
task-status-configuring

Conversation

@chdominguez

@chdominguez chdominguez commented Sep 2, 2026

Copy link
Copy Markdown
Member

Summary

  • Adds TaskStatus.CONFIGURING, between PENDING and RUNNING.
  • BaseTask.run() now sets CONFIGURING on entry instead of jumping straight to RUNNING — previously RUNNING was set the instant the task's coroutine started, before the working directory existed or any environment prep ran.
  • BaseExecutor.execute() (the one @final hook every executor funnels through) flips the status to RUNNING once its generic directory setup is done, right before the executor-specific _execute() begins.
  • Plugin executors (horus-docker, horus-slurm, horus-terraform, etc., not in this repo) can reuse the same status field to report their own slower setup (image build/pull, VM provisioning, queueing) around their own _execute() — no new API needed, status is already a plain mutable field.
  • TUI's exhaustive per-status style/glyph maps updated (the module asserts full coverage, so this was required, not optional).

Ref: temple-compute/tc-os#237

Test plan

  • uv run pytest -q — 734 passed
  • New test: task status is CONFIGURING during _run, before the executor's _execute runs, then COMPLETED on clean exit
  • New test: BaseExecutor.execute sets RUNNING before invoking _execute
  • ruff check clean on all touched files

Docs

  • No documentation update required

…tion

TaskStatus.RUNNING was set the instant a task's coroutine started, before
directory setup or an executor's own environment prep, so anything slower
than a local shell command looked "running" while nothing had actually
started yet. BaseTask.run() now enters CONFIGURING, and
BaseExecutor.execute() flips to RUNNING once its generic directory setup is
done and right before the executor-specific work begins. Plugin executors
can use the same status field to report their own slower setup (image
build/pull, provisioning, queueing).
@chdominguez
chdominguez merged commit 3137226 into main Sep 2, 2026
7 of 8 checks passed
@chdominguez
chdominguez deleted the task-status-configuring branch September 2, 2026 12:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant