Skip to content

Commit b8ace80

Browse files
Jammy2211claude
authored andcommitted
fix: verify_install Check F loads stale dataset + resolves mixed dev/released stack
Check F (Colab simulation) FAILed while the real install path (A/C/D) was green, failing the whole verify_install_release job (release-validation run 29266305445). 1. F_driver loaded dataset/imaging/simple/*.fits — a path start_here.py no longer uses and which isn't bundled → FileNotFoundError. Load the bundled cosmos_web_ring JWST dataset (pixel_scales=0.06) the current start_here.py actually loads (why Check A passes); no simulator needed. 2. The emulated-Colab install pinned only autolens to the dev version, letting the four sibling deps resolve to the latest final on PyPI. When a version is pinned, pin all five PyAuto packages so Check F exercises a coherent dev stack. Harness-only; Checks A/C/D untouched. Fixes #70 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TDCsgNCXacXqiWAPTswWCt
1 parent 2ef4f85 commit b8ace80

1 file changed

Lines changed: 34 additions & 7 deletions

File tree

heart/checks/verify_install.sh

Lines changed: 34 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -528,9 +528,28 @@ check_f() {
528528
# Emulate the Colab base environment: Colab preinstalls the scientific
529529
# stack and JAX; the injected setup cell installs the PyAuto packages
530530
# --no-deps on top of that.
531-
step "pip install $PIP_INSTALL_TARGET jax (emulating Colab's preinstalled env)"
532-
if ! pip install "${PIP_INDEX_ARGS[@]}" "$PIP_INSTALL_TARGET" jax |& tee /tmp/F_pip.log; then
533-
RESULTS+=("F|FAIL|pip install $PIP_INSTALL_TARGET jax failed")
531+
#
532+
# When a version is pinned (a TestPyPI rehearsal), pin ALL five PyAuto
533+
# packages to it — otherwise pip installs `autolens` at the pinned dev
534+
# version but resolves autoarray/autoconf/autofit/autogalaxy to the latest
535+
# *final* release on PyPI (dev versions are pre-releases pip won't pick for
536+
# a floor-only dependency), leaving Check F exercising an incoherent
537+
# dev/released mix instead of the same wheels as Checks A/C/D. The later
538+
# verbatim `pip install autoconf --no-deps` inside the driver then finds the
539+
# pinned dev autoconf already satisfied, so it can't pull a released one.
540+
local f_targets=("$PIP_INSTALL_TARGET")
541+
if [ -n "$TARGET_VERSION" ]; then
542+
f_targets=(
543+
"autolens==$TARGET_VERSION"
544+
"autoarray==$TARGET_VERSION"
545+
"autoconf==$TARGET_VERSION"
546+
"autofit==$TARGET_VERSION"
547+
"autogalaxy==$TARGET_VERSION"
548+
)
549+
fi
550+
step "pip install ${f_targets[*]} jax (emulating Colab's preinstalled env)"
551+
if ! pip install "${PIP_INDEX_ARGS[@]}" "${f_targets[@]}" jax |& tee /tmp/F_pip.log; then
552+
RESULTS+=("F|FAIL|pip install ${f_targets[*]} jax failed")
534553
tail_log "Check F pip output" "$(cat /tmp/F_pip.log 2>/dev/null)"
535554
deactivate
536555
return
@@ -587,13 +606,21 @@ assert os.path.isdir(os.path.join(WS_DIR, "config")), "workspace config/ missing
587606
assert os.path.isdir(os.path.join(WS_DIR, "dataset")), "workspace dataset/ missing"
588607
589608
# --- one real notebook cell (the top of imaging/start_here) ---
609+
#
610+
# Load the SAME dataset the current imaging/start_here.py loads: the bundled
611+
# `cosmos_web_ring` JWST example (one of the few datasets that ship committed
612+
# with the workspace, cloned above by setup_colab). The old `dataset/imaging/
613+
# simple/*.fits` path was never bundled and is no longer used by start_here —
614+
# after the release dataset `-f` leak fix (PyAutoBuild#150) it would only exist
615+
# if simulated at run time, so loading it here crashed FileNotFoundError while
616+
# Check A (which runs start_here.py) passed.
590617
import autolens as al
591618
592619
dataset = al.Imaging.from_fits(
593-
data_path="dataset/imaging/simple/data.fits",
594-
noise_map_path="dataset/imaging/simple/noise_map.fits",
595-
psf_path="dataset/imaging/simple/psf.fits",
596-
pixel_scales=0.1,
620+
data_path="dataset/imaging/cosmos_web_ring/data.fits",
621+
noise_map_path="dataset/imaging/cosmos_web_ring/noise_map.fits",
622+
psf_path="dataset/imaging/cosmos_web_ring/psf.fits",
623+
pixel_scales=0.06,
597624
)
598625
print(f"cell OK: loaded imaging dataset, shape {dataset.data.shape_native}")
599626
PYEOF

0 commit comments

Comments
 (0)