tephpy.io.wyoming#
University of Wyoming sounding archive reader (spec §3.4).
fetch() requests one ascent from the archive’s post-2024 wsgi
interface in its machine-readable TEXT:CSV form — bare, self-describing
CSV (verified 2026-07-27) — over stdlib urllib behind a function-local
import, and hands the body to a pure, transport-free parser. Network
failures, HTTP errors, and the archive’s “no data” replies raise
TephpyIOError summarising the upstream
response; the parsed sounding passes the ordinary ingest validation
(spec §6).
Functions#
|
Fetch one sounding from the University of Wyoming archive. |
Module Contents#
- tephpy.io.wyoming.fetch(station: str, time: datetime.datetime | str, *, timeout: float | None = None) tephpy.sounding.Sounding[source]#
Fetch one sounding from the University of Wyoming archive.
- Parameters:
- station
str The WMO station identifier, e.g.
"72357".- time
datetime.datetimeorstr The nominal launch time; a string is read with
datetime.datetime.fromisoformat(), and a naive value is read as UTC (theSoundingconvention).- timeout
float, optional The request timeout in seconds (default
WYOMING_TIMEOUT).
- station
- Returns:
- Raises:
TephpyIOErrorFor network failures, HTTP errors (including the archive’s “no data at that time” and “unknown station” replies), or a response the parser does not recognise.
TypeErrorIf time is neither a datetime nor a string.
ValueErrorIf a time string is not ISO 8601.