Skip to content

maintenance: purge 50 zero-match no_run.yaml entries + 11 dead env_vars patterns #46

Description

@Jammy2211

Overview

A full census of every config/build/ path-pattern config across all 10 build targets in PyAutoHands/autobuild/config/workspaces.yaml found that 50 of 122 no_run.yaml entries (41%) match zero files, plus 11 dead env_vars.yaml override patterns. The rot is concentrated in three repos — HowToLens (28/30 dead), HowToGalaxy (15/16), autolens_workspace (7/27) — and the cause is not gradual drift but bidirectional copy-paste between the HowTo* repos and their parent workspaces. One entry, plot/visuals, turned out to be an active silent failure rather than cruft: its skip stopped applying a year ago when the file moved, so a script marked "Bugged" has been running in the build unnoticed ever since.

This closes the "~44 zero-match entries remain, needs a deliberate call before purging" item deliberately left open by the 2026-07-22 ell_comps/HowTo no_run sweep (autogalaxy_workspace#143, HowToGalaxy#34/#35, HowToLens#44).

Plan

  • Purge every zero-match entry from no_run.yaml in HowToLens, HowToGalaxy and autolens_workspace, including bare-stem prospective guards — a guard for a script that does not exist is unverifiable, and is exactly what produced this mess.
  • Purge the 11 dead env_vars.yaml / env_vars_release.yaml override patterns in HowToLens, HowToGalaxy, HowToFit and autogalaxy_workspace_test.
  • Drop plot/visuals as stale rather than re-spelling it: the script was tested under the real build env profile and passes clean (exit 0, no output), so the "Bugged" comment is obsolete.
  • Add a header comment to each cleaned no_run.yaml recording the matcher rule and that entries must not be copied between repos — the copy-paste is the actual defect; a purge alone just resets the clock.
  • Verify with the real matcher that every surviving entry matches at least one file, then run the build over the two HowTo repos to confirm nothing that had been skipped starts failing.
Detailed implementation plan

Affected Repositories

  • HowToLens (primary)
  • HowToGalaxy
  • autolens_workspace
  • HowToFit
  • autogalaxy_workspace_test

Branch Survey

Repository Current Branch Dirty? Behind origin/main
./HowToLens main clean 0
./HowToGalaxy main clean 0
./autolens_workspace main clean 0
./HowToFit main clean 1 (pull first)
./autogalaxy_workspace_test main clean 0

Suggested branch: feature/no-run-config-purge
Worktree: ~/Code/PyAutoLabs-wt/no-run-config-purge/

Concurrent claim (human-approved). All five repos are claimed in active.md by the parked rename-autobuild-to-autohands task (blocked on Heart RED, nothing committed). The file sets were verified disjoint: grep -n 'autobuild|PyAutoHands|PyAutoBuild' across every file this task edits returns nothing. The only build config mentioning PyAutoHands is markdown_examples.yaml, which is already renamed on main and is not edited here (it is clean in every repo). Proceeding concurrently on a separate branch and worktree was explicitly approved.

Brain phase-split override (human-approved). The Feature Agent scored this too-large (19) and proposed a 4-phase split (design / core_api / workspace_examples / docs). The score is repo-count-driven; the change is ~61 lines of YAML deleted across 8 files with no code, API or docs surface. Shipping as a single pass.

Census method

Entries were evaluated with the real matcher, should_skip in PyAutoHands/autobuild/build_util.py:143:

  • an entry containing / is a substring match against the full path including extension;
  • an entry without / matches the file stem exactly.

run_all walks only scripts/ (PyAutoHands/autobuild/run_all.py:78).

Per-repo result:

Repo Entries Zero-match
autolens_workspace 27 7
HowToLens 30 28
HowToGalaxy 16 15
autolens_workspace_test 23 0
autogalaxy_workspace 10 0
autogalaxy_workspace_test 9 0
autofit_workspace 5 0
autofit_workspace_test 2 0
HowToFit 0 0
euclid_strong_lens_modeling_pipeline 0 0

markdown_examples.yaml and visualise_notebooks.yaml are clean in every repo.

Root cause: bidirectional copy-paste

Each dead entry was attributed to the repo where its file actually lives:

  • HowToLens' list is a copy of autolens_workspace's. 18 of its 28 dead entries (gui/mask, cluster/modeling, mass_stellar_dark/slam, time_delays, hpc/example_cpu, imaging/features/advanced/subhalo/sensitivity/, …) name real files that exist only in autolens_workspace. HowToLens contains nothing but chapter_*/tutorial_*.py, so none of those paths can ever exist there.
  • HowToGalaxy ← autogalaxy_workspace, same mechanism, 11 of 15.
  • The copy went back the other way too: autolens_workspace carries tutorial_searches, tutorial_5_borders and tutorial_6_model_fit — HowTo tutorial stems that cannot exist in a workspace.
  • Only 3 of the 46 HowTo entries are live: tutorial_searches (both repos) and tutorial_5_borders (HowToLens).

Implementation Steps

  1. Create branch + worktree feature/no-run-config-purge across the five repos. Pull HowToFit first (1 behind origin/main).

  2. HowToLens/config/build/no_run.yaml — delete 28 of 30 entries, keep only tutorial_searches and tutorial_5_borders. Deleted: guides/results/examples/samples, guides/results/examples/samples_via_aggregator, guides/results/examples/queries, guides/results/database/start_here, tutorial_6_model_fit, gui/extra_galaxies_centres, gui/mask_extra_galaxies, gui/lens_light_centre, gui/mask, gui/positions, deflections, deflections_source_snr, fits_make, png_make, time_delays, hpc/example_cpu, examples/searches, data_fitting, cluster/modeling, cluster/start_here, mass_stellar_dark/modeling, mass_stellar_dark/slam, shapelets/modeling, detect/database, imaging/features/advanced/subhalo/sensitivity/, plot/visuals, point_source/features/double_einstein_cross/simulator, dataset/imaging/slacs1430+4105.

  3. HowToGalaxy/config/build/no_run.yaml — delete 15 of 16, keep only tutorial_searches. Deleted: guides/results/start_here, guides/results/examples/galaxies_fit, guides/results/examples/samples, guides/results/examples/models, guides/results/workflow/csv_make, guides/results/database/start_here, gui/light_centre, gui/mask_extra_galaxies, gui/mask, gui/extra_galaxies_centres, fits_make, png_make, examples/searches, data_fitting, ellipse/database.

  4. autolens_workspace/config/build/no_run.yaml — delete the 7 zero-match entries: tutorial_searches, tutorial_5_borders, tutorial_6_model_fit (HowTo stems that leaked in), deflections, deflections_source_snr (no such file in any repo or in history), dataset/imaging/slacs1430+4105 (points outside scripts/, so the walker never sees it — its own comment admits this), and plot/visuals (see step 6). The other 20 entries are live and untouched.

  5. env_vars.yaml siblings — delete 11 dead override patterns:

    • HowToLens/config/build/env_vars.yaml: imaging/start_here, interferometer/start_here, group/start_here, multi/start_here, guides/results/ — all autolens_workspace paths.
    • HowToGalaxy/config/build/env_vars.yaml: guides/results/.
    • HowToFit/config/build/env_vars.yaml: plot/emcee_plotter, plot/zeus_plotter — legacy, those scripts are gone.
    • autogalaxy_workspace_test/config/build/env_vars.yaml: quantity/visualization.py, quantity/visualization_jax; and env_vars_release.yaml: quantity/visualization_jax.
  6. plot/visuals — resolved by test, not by guess. The file moved scripts/plot/visuals.pyscripts/guides/plot/examples/visuals.py in commit 9e1a50dc4 (2025-07-18); the pattern was never updated, so the skip has not applied for a year. Run under the exact build env profile (via autobuild repro_command):

    (cd autolens_workspace && env PYAUTO_TEST_MODE=2 PYAUTO_SKIP_FIT_OUTPUT=1 \
      PYAUTO_SKIP_VISUALIZATION=1 PYAUTO_SKIP_CHECKS=1 PYAUTO_DISABLE_JAX=1 \
      PYAUTO_FAST_PLOTS=1 JAX_ENABLE_X64=True NUMBA_CACHE_DIR=/tmp/numba_cache \
      MPLCONFIGDIR=/tmp/matplotlib python3 scripts/guides/plot/examples/visuals.py)
    

    Result: exit 0, no output, no warnings. The "Bugged, but visuals being refactored soon" comment is obsolete. Entry dropped as stale in both repos; no corrected pattern re-added.

  7. Add a header comment to each cleaned no_run.yaml stating the matcher rule (/ = substring incl. extension, no / = exact stem) and that entries are repo-local and must not be copied between repos.

  8. Verify. Re-run the census script — every surviving entry must match ≥1 file in its own repo. Then autobuild run_all howtolens and autobuild run_all howtogalaxy to confirm nothing that had been skipped now fails.

  9. Ship via ship_workspace → 5 PRs, stopping at PR-open. Heart is currently RED (release validation integrate:fail, 646p/13f/78s, 33 stale parked scripts) — unrelated to this task, but merge stays a human act regardless.

Notes on specific entries

  • tutorial_6_model_fit (HowToLens + autolens_workspace) matches no file in any repo's history. tutorial_8_model_fit.py exists in HowToLens chapter_4, but the intended target is unrecoverable, so the entry is deleted as part of the purge rather than repaired.
  • Bare-stem guards (fits_make, png_make, data_fitting, deflections, examples/searches) are purged too, per explicit decision. If such a script is ever added, the build fails loudly and the entry can be re-added with a real, verifiable reason.
  • dataset/imaging/slacs1430+4105 is inert because it points outside scripts/. The directory itself is untouched — only the useless skip entry is removed.

Key Files

  • HowToLens/config/build/no_run.yaml — 30 entries → 2
  • HowToGalaxy/config/build/no_run.yaml — 16 entries → 1
  • autolens_workspace/config/build/no_run.yaml — 27 entries → 20
  • HowToLens/config/build/env_vars.yaml — 5 dead override patterns removed
  • HowToGalaxy/config/build/env_vars.yaml — 1 removed
  • HowToFit/config/build/env_vars.yaml — 2 removed
  • autogalaxy_workspace_test/config/build/env_vars.yaml — 2 removed
  • autogalaxy_workspace_test/config/build/env_vars_release.yaml — 1 removed
  • PyAutoHands/autobuild/build_util.py:143should_skip, the matcher the census was run against (read-only reference, not edited)

Original Prompt

Click to expand starting prompt

no_run.yaml (and sibling build configs) are 41% dead entries from copy-paste

Type: maintenance
Target: HowToLens
Repos:

  • HowToLens
  • HowToGalaxy
  • autolens_workspace
  • HowToFit
  • autogalaxy_workspace_test
    Difficulty: small
    Autonomy: supervised
    Priority: normal
    Status: formalised

Original request (verbatim)

clean up no_run.yaml fiels in HowTo and other repos, which clearly are not in
sync with their actual contents and have a lot of stuff from legacy old code
etc. do a full census of all configs of this nature.

Census (complete, 2026-07-23)

Evaluated every entry in every config/build/ path-pattern config across all 10
build targets in PyAutoHands/autobuild/config/workspaces.yaml, using the real
matcher (PyAutoHands/autobuild/build_util.py:143 should_skip): an entry
containing / is a substring match against the full path including extension;
an entry without / matches the file stem exactly. run_all walks only
scripts/ (run_all.py:78).

no_run.yaml — 122 entries, 50 zero-match (41%)

Repo Entries Zero-match
autolens_workspace 27 7
HowToLens 30 28
HowToGalaxy 16 15
autolens_workspace_test 23 0
autogalaxy_workspace 10 0
autogalaxy_workspace_test 9 0
autofit_workspace 5 0
autofit_workspace_test 2 0
HowToFit 0 0
euclid_strong_lens_modeling_pipeline 0 0

Root cause: bidirectional copy-paste, not gradual drift

Each dead entry was attributed to the repo where its file actually lives:

  • HowToLens' list is a copy of autolens_workspace's. 18 of its 28 dead
    entries (gui/mask, cluster/modeling, mass_stellar_dark/slam,
    time_delays, hpc/example_cpu,
    imaging/features/advanced/subhalo/sensitivity/, …) name real files that
    exist only in autolens_workspace. HowToLens contains nothing but
    chapter_*/tutorial_*.py, so none of those paths can ever exist there.
  • HowToGalaxy ← autogalaxy_workspace, same mechanism, 11 of 15.
  • The copy went back the other way too: autolens_workspace carries
    tutorial_searches, tutorial_5_borders and tutorial_6_model_fit
    HowTo tutorial stems that cannot exist in a workspace.
  • Only 3 of the 46 HowTo entries are live: tutorial_searches (both) and
    tutorial_5_borders (HowToLens).

One entry is an active silent failure, not cruft

plot/visuals (autolens_workspace + HowToLens), commented "Bugged, but visuals
being refactored soon."
The file moved scripts/plot/visuals.py
scripts/guides/plot/examples/visuals.py in commit 9e1a50dc4 (2025-07-18).
The pattern was never updated, so the skip stopped applying a year ago and the
script has been running in the build ever since. Deleting the entry is the wrong
fix — the pattern must be retested, then corrected or dropped on evidence.

dataset/imaging/slacs1430+4105 is inert for a different reason: it points
outside scripts/, so the walker never sees it. Its own comment admits this.

Siblings are contaminated the same way — 11 more dead entries

Same copy-paste mechanism, in env_vars.yaml / env_vars_release.yaml:

  • HowToLens: imaging/start_here, interferometer/start_here,
    group/start_here, multi/start_here, guides/results/ — autolens_workspace
    paths.
  • HowToGalaxy: guides/results/.
  • HowToFit: plot/emcee_plotter, plot/zeus_plotter — legacy, those
    scripts are gone.
  • autogalaxy_workspace_test: quantity/visualization.py and
    quantity/visualization_jax (the latter in both env_vars files).

markdown_examples.yaml and visualise_notebooks.yaml are clean in every repo.

Scope decisions already taken by the human

  1. Purge every zero-match entry, including bare-stem prospective guards
    (fits_make, png_make, data_fitting, deflections, examples/searches).
    A guard for a script that does not exist is unverifiable and is exactly what
    produced this mess; if such a script is ever added the build fails loudly and
    the entry can be re-added with a real reason.
  2. plot/visuals gets tested, not guessed. Run
    scripts/guides/plot/examples/visuals.py under the build env profile; if it
    passes, drop the entry as stale, if it still fails, re-add a correctly-spelled
    path entry with a fresh reason.

Notes

  • This closes the "~44 zero-match entries remain, needs a deliberate call before
    purging" item left open by the 2026-07-22 ell_comps/HowTo no_run sweep
    (autogalaxy_workspace#143, HowToGalaxy#34/refactor!: point the Colab bootstrap at autonerves (renamed from autoconf) #35, HowToLens#44).
  • tutorial_6_model_fit (HowToLens + autolens_workspace) matches no file in any
    repo's history; it is deleted as part of the purge rather than repaired,
    since the intended target is unrecoverable.
  • Config-only change. No script, notebook or library edits expected, beyond
    whatever the plot/visuals test verdict implies.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions