Repository navigation
Description
Overview
Follow-up to #1767. A live probe on a RAL compute node (jobs 415133/415134) showed that a job submitted with --export=NONE and sourcing activate.sh still gets TMPDIR=/tmp. Slurm sets TMPDIR to its TmpFS itself when the submit environment has none, so the ${TMPDIR:-...} added in phase A never fires. Caches were already right; only temp files are affected.
Plan
- In the five phase-A
activate.shfiles, replaceTMPDIRwhen it is unset, empty or exactly/tmp; any other value still wins. - Same rule in PyAutoFit's generated campaign job scripts (
cache_root:), with a test for the/tmpcase. - The four claimed repos pick this up in phase B (Mind draft
hpc_keep_temp_off_home_phase_b.md).
Tier: glance — merge mode: auto-merge on green if the Witness passes, post-merge summary
Detailed implementation plan
Affected Repositories
- PyAutoFit (primary):
autofit/campaign/scheduler/slurm.py_cache_exports;test_autofit/campaign/test_slurm.py - autofit_assistant, autofit_inference, autogalaxy_assistant, autolens_inference, autocti_assistant:
activate.sh
Branch
feature/hpc-tmpdir-slurm-default; worktree ~/Code/PyAutoLabs-wt/hpc-tmpdir-slurm-default/
Implementation Steps
_cache_exports: emitif [ -z "${TMPDIR:-}" ] || [ "$TMPDIR" = /tmp ]; then export TMPDIR="<root>/tmp"; fiinstead of the fill-if-unset line; keep the other variables as they are.- Tests: under bash,
TMPDIR=/tmp→ replaced;TMPDIR=/scratch→ kept; unset → replaced. activate.sh×5: the sameifaround the TMPDIR export; comment names the Slurm cause.- Verify by sourcing under
env -iwithTMPDIR=/tmp,/scratchand unset.
Original Prompt
Click to expand starting prompt
Treat Slurm's default TMPDIR=/tmp as unset in activate.sh and campaign job scripts
Type: maintenance
Target: PyAutoFit
Repos:
- PyAutoFit
- autofit_assistant
- autofit_inference
- autogalaxy_assistant
- autolens_inference
- autocti_assistant
Difficulty: small
Autonomy: supervised
Priority: high
Status: formalised
Consequence: glance
Witness: a job with--export=NONEthat sources a fixed activate.sh (or runs a PyAutoFit cache_root script) gets TMPDIR on the shared disk, not /tmp; a TMPDIR set to anything other than /tmp still wins; tests cover the /tmp case.
Review-minutes: 3
Filed: 2026-11-12
Follow-up to complete/2026/11/hpc-keep-off-home.md (PyAutoFit#1767). Live probe jobs
415133/415134 on euclid-ral-compute-1: with --export=NONE,... + source activate.sh the
caches were right but TMPDIR=/tmp, because Slurm sets TMPDIR to its TmpFS (/tmp) when
the submit environment has none, so phase A's ${TMPDIR:-...} never fires.
Human (2026-11-12): "fix the TMPDIR=/tmp gap now too".
Fix: treat TMPDIR that is unset, empty or exactly /tmp as unset —
- the TMPDIR block in the five phase-A activate.sh files;
- PyAutoFit
autofit/campaign/scheduler/slurm.py_cache_exports, with a test for the
/tmpcase.
The four claimed repos stay indraft/maintenance/workspaces/hpc_keep_temp_off_home_phase_b.md.
Activity
Jammy2211 commentedon Nov 12, 2026
Shipped under a Heart RED development override (2026-11-12). PRs:
Heart RED development override
Authorized live by the human on 2026-11-12 for this task (PyAutoFit#1769): "Override, ship + merge". That covers opening these PRs and merging them in the same turn once every required check is green. Heart remains RED for release purposes; this branch does not claim to fix Heart.
Exact RED reasons at ship time:
Branch gates passed: full PyAutoFit suite 4288 passed / 2 skipped / 1 xfailed; bash -n + three-case env -i source test (unset, /tmp, /scratch) of each activate.sh.
Merge not done: the merge grant lapsed when the shipping turn ended while the test suite ran, so per AUTONOMY.md the human runs
/prmonce CI is green (PyAutoFit first).Jammy2211 commentedon Nov 12, 2026
Shipped, merged 2026-11-12 on the human's explicit merge command under the Heart RED development override (every check green): #1771 (pending release), PyAutoLabs/autofit_assistant#64, PyAutoLabs/autofit_inference#20, PyAutoLabs/autogalaxy_assistant#47, PyAutoLabs/autolens_inference#66, PyAutoLabs/autocti_assistant#41. A
TMPDIRthat is unset, empty or Slurm's default/tmpnow becomes the shared-disktmp/; any other value wins. The four repos still claimed by other tasks get this through phase B (Mind drafthpc_keep_temp_off_home_phase_b.md).