Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion app/nullius/execution.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,8 @@
``run.sh`` itself.
``restore`` reads those records when Nullius starts and reattaches to what
is still running, waits again where it was paused, and settles what ended
while nobody was looking; one process at a time, by the runs root's lock.
while nobody was looking, once it holds the runs root's lock (``_follow``):
one web UI per runs folder. What is supported: ``docs/concepts.md``.
A record is checked against the part's files and processes on the target
before it is trusted (``_settle``): a part whose pid
was never saved, but which was claimed or started, is followed by the pid it
Expand Down
22 changes: 22 additions & 0 deletions docs/concepts.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,28 @@ A count of runs leaves out the checks. The checks have a count of their own.

The roots holding your runs; the same roots reopen the same workspace. Judgements belong to the job, in every workspace that holds it.

## Concurrency and failures

Several web UIs and commands may use one profile (`NULLIUS_HOME`) at once, within the limits below.

- Each runs folder (`RUNS_DIR`) is followed by one web UI; a second on the same folder refuses to start. Stopping a run goes through the web UI that follows it.
- A job folder has one writer at a time: `standard run`, `standard rerun` or the run itself.
- Leaderboard weights, access tokens, proofs and task flags change under their own lock. Files are replaced whole, never half written.

Supported:

- Nullius killed between any two writes.
- A write that fails: disk full, permission refused.
- Several requests at once in one web UI.

Not supported:

- Two processes changing workspaces or judgements at once.
- Permissions or ownership changed by someone else during an operation.
- A sticky or foreign-owned runs folder.
- Another program renaming, deleting or editing a workspace, run or judgement folder Nullius is writing to.
- Network filesystems' locks.

<div class="grid cards" markdown>

- [Run builder](builder.md)
Expand Down
Loading