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
12 changes: 8 additions & 4 deletions .github/scripts/run_smoke.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
"""
Run the workspace smoke test suite.

Reads `smoke_tests.txt` from the workspace root and `config/build/env_vars.yaml`
Reads `smoke_tests.txt` from the workspace root and `config/build/profile_smoke.yaml`
for per-script env var overrides, then runs each listed script with the
appropriate environment. Continues through failures and exits non-zero
if any script failed.

The env resolution itself is NOT implemented here: it is PyAutoHands's
`autohands/env_config.py`, imported below. This file used to carry a copy, and
the copy had already drifted (its `load_env_config` hardcoded
`config/build/env_vars.yaml`, so the PR gate was structurally unable to read
the copy had already drifted (its `load_env_config` hardcoded a single
profile path, so the PR gate was structurally unable to read
the release profile — the seed incident's failure mode 4/7). One resolver
means the PR gate and the release runner cannot disagree about what a script's
environment is. See PyAutoHands docs/env_profile_redesign.md §5 (#161 step 2).
Expand All @@ -28,7 +28,11 @@

WORKSPACE = Path(__file__).resolve().parents[2]
SMOKE_FILE = WORKSPACE / "smoke_tests.txt"
ENV_VARS_FILE = WORKSPACE / "config" / "build" / "env_vars.yaml"
# Prefer the canonical profile name; fall back to the legacy env_vars.yaml
# until the stage-3 cleanup removes the fallback (#161 step 6).
ENV_VARS_FILE = WORKSPACE / "config" / "build" / "profile_smoke.yaml"
if not ENV_VARS_FILE.exists():
ENV_VARS_FILE = WORKSPACE / "config" / "build" / "env_vars.yaml"
SCRIPTS_DIR = WORKSPACE / "scripts"

# CI puts PyAutoHands/autohands on PYTHONPATH (PyAutoHeart's reusable
Expand Down
4 changes: 2 additions & 2 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@ scripts/ Integration-test scripts run in CI
legacy/ Euclid VIS heritage (2022-2023, pre-resurrection API — not runnable;
see legacy/README.md)
config/ Current PyAutoCTI config (mirrors autocti_workspace)
config/build/env_vars.yaml Per-script env for smoke runs (PYAUTO_TEST_MODE=2 defaults)
config/build/profile_smoke.yaml Per-script env for smoke runs (PYAUTO_TEST_MODE=2 defaults)
smoke_tests.txt The curated smoke list (small on purpose)
```

## Running

```bash
python .github/scripts/run_smoke.py # the smoke list, with env_vars.yaml applied
python .github/scripts/run_smoke.py # the smoke list, with profile_smoke.yaml applied
python scripts/dataset_1d/model_fit.py # one script, real search (no env applied)
```

Expand Down
File renamed without changes.
Loading