CI (pull_request) for 220/merge #534
GitHub Actions / QA Test Results
failed
Mar 13, 2025 in 0s
1 fail, 2 skipped, 9 pass in 0s
12 tests 9 ✅ 0s ⏱️
1 suites 2 💤
1 files 1 ❌
Results for commit f0514a5.
Annotations
Check warning on line 0 in qa.test_access_om3_config.TestAccessOM3
github-actions / QA Test Results
test_access_om3_manifest_exe_in_release_spack_location (qa.test_access_om3_config.TestAccessOM3) failed
./test_report.xml [took 0s]
Raw output
AssertionError: Failed to download spack.location from https://github.com/ACCESS-NRI/ACCESS-OM3/releases/download/2025.01.1/spack.location
assert 404 == 200
+ where 404 = <Response [404]>.status_code
self = <test_access_om3_config.TestAccessOM3 object at 0x7f3939ac5e90>
config = {'collate': False, 'exe': 'access-om3-MOM6-CICE6', 'input': ['/g/data/vk83/prerelease/configurations/inputs/access-om3...inputs/access-om3/mom/surface_salt_restoring/global.025deg/2025.01.30/salt_sfc_restore.nc', ...], 'jobfs': '10GB', ...}
control_path = PosixPath('/home/runner/work/access-om3-configs/access-om3-configs')
def test_access_om3_manifest_exe_in_release_spack_location(
self, config, control_path
):
> check_manifest_exes_in_spack_location(
model_module_name="access-om3",
model_repo_name="ACCESS-OM3",
control_path=control_path,
config=config,
)
/opt/hostedtoolcache/Python/3.11.0/x64/lib/python3.11/site-packages/model_config_tests/qa/test_access_om3_config.py:19:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
model_module_name = 'access-om3', model_repo_name = 'ACCESS-OM3'
control_path = PosixPath('/home/runner/work/access-om3-configs/access-om3-configs')
config = {'collate': False, 'exe': 'access-om3-MOM6-CICE6', 'input': ['/g/data/vk83/prerelease/configurations/inputs/access-om3...inputs/access-om3/mom/surface_salt_restoring/global.025deg/2025.01.30/salt_sfc_restore.nc', ...], 'jobfs': '10GB', ...}
def check_manifest_exes_in_spack_location(
model_module_name, model_repo_name, control_path, config
):
"""This compares executable paths in the executable manifest, and checks
they match an install path in the spack.location release artefact. The
version defined in the module configuration in config.yaml, is used
to find the relevant release version.
This is called in model-specific config tests.
Parameters
----------
model_module_name: str
Expected module name in the config.yaml file. This is used to find the version of the model
model_repo_name: str
Name of the ACCESS-NRI model repository. This is used to retrieve released spack.location
control_path: Path
The path to configuration directory
config: Dict[str, Any]
The contents of the config.yaml file
"""
help_msg = (
"Expected module for the model is added to loaded modules in config.yaml. "
"The module also requires a released version. E.g.\n"
" modules:\n"
" use:\n"
f" - {RELEASE_MODULE_LOCATION}\n"
" load:\n"
f" - {model_module_name}/<version>\n"
"Model executable paths can then be filenames that found in paths added by loaded module"
)
# Check module is defined in configuration file
assert "modules" in config and "load" in config["modules"], help_msg
loaded_modules = config["modules"]["load"]
modules = [m for m in loaded_modules if m.startswith(f"{model_module_name}/")]
assert len(modules) == 1, help_msg
# Extract out the version
_, module_version = modules[0].split("/")
# Use the module version to download spack.location file
url = (
f"https://github.com/ACCESS-NRI/{model_repo_name}/"
f"releases/download/{module_version}/spack.location"
)
# Check there is a released spack.location file for the module version
response = requests.get(url)
> assert response.status_code == 200, f"Failed to download spack.location from {url}"
E AssertionError: Failed to download spack.location from https://github.com/ACCESS-NRI/ACCESS-OM3/releases/download/2025.01.1/spack.location
E assert 404 == 200
E + where 404 = <Response [404]>.status_code
/opt/hostedtoolcache/Python/3.11.0/x64/lib/python3.11/site-packages/model_config_tests/qa/test_config.py:311: AssertionError
Loading