Severity: major (a full model run can complete entirely on fabricated data with no signal)
Where: src/nhflodata/get_paths.py:96 — get_abs_data_path(..., location="get_from_env").
Problem. With location="get_from_env" and NHFLODATA_LOCATION unset or empty, get_abs_data_path silently resolves every dataset to the packaged mockup tree, whose data is by its own documentation "altered". There is no warning-level signal, so a model script (e.g. 09pwnmodel2) runs to completion built entirely from mockup data. NHFLODATA_LOCATION was found unset in a normal dev environment, so this is easy to hit.
Suggested fix. Emit a logger.warning (or raise, behind an opt-out) in get_abs_data_path when location=="get_from_env" falls back to the mockup tree; and/or recommend a production guard in consuming scripts (assert "mockup" not in data_path.parts).
From a systematic review of modelscripts/09pwnmodel2/01_pwnmodel2.py and its dependency stack (nhflotools, nhflodata, nlmod), July 2026. Every finding was traced through the actual code and adversarially verified before filing.
Severity: major (a full model run can complete entirely on fabricated data with no signal)
Where:
src/nhflodata/get_paths.py:96—get_abs_data_path(..., location="get_from_env").Problem. With
location="get_from_env"andNHFLODATA_LOCATIONunset or empty,get_abs_data_pathsilently resolves every dataset to the packaged mockup tree, whose data is by its own documentation "altered". There is no warning-level signal, so a model script (e.g.09pwnmodel2) runs to completion built entirely from mockup data.NHFLODATA_LOCATIONwas found unset in a normal dev environment, so this is easy to hit.Suggested fix. Emit a
logger.warning(or raise, behind an opt-out) inget_abs_data_pathwhenlocation=="get_from_env"falls back to the mockup tree; and/or recommend a production guard in consuming scripts (assert "mockup" not in data_path.parts).From a systematic review of
modelscripts/09pwnmodel2/01_pwnmodel2.pyand its dependency stack (nhflotools, nhflodata, nlmod), July 2026. Every finding was traced through the actual code and adversarially verified before filing.