Skip to content

ADD: Some bugfixes to get the unit test to work.#18

Merged
rcjackson merged 1 commit intoARM-Development:mainfrom
rcjackson:nexrad
Mar 5, 2026
Merged

ADD: Some bugfixes to get the unit test to work.#18
rcjackson merged 1 commit intoARM-Development:mainfrom
rcjackson:nexrad

Conversation

@rcjackson
Copy link
Collaborator

Code Bugs Found

  1. radclss_core.py:476 — nexrad_columns.drop() when nexrad=False
    nexrad_columns is None when nexrad=False, but .drop() is called unconditionally.
    nexrad_columns = nexrad_columns.drop(["time_offset", "base_time"]) # crashes if nexrad=False
    Fix: wrap in if nexrad_columns is not None:.

  2. radclss_core.py:409,411 — .resample() not followed by aggregation
    ds_concat[k].resample(time=time_coords) returns a DatasetResample, not a Dataset. Then .reindex() is called on it, which crashes with AttributeError. This code path is hit by test_radclss_serial_with_5min_time.

  3. radclss_core.py — volumes["sonde"] KeyError when sonde not provided
    volumes["sonde"] raises KeyError if sonde files aren't included (e.g. test_radclss_parallel_with_nexrad).
    Fix: volumes.get("sonde").

  4. Will no longer crash on no sonde data.

  5. No need for support for time averaging at this point after coordination with the mentors.

@rcjackson rcjackson merged commit 07aa2d5 into ARM-Development:main Mar 5, 2026
13 of 15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant