Skip to content

docs: preserve the METAR hand-ingress anti-example in cw.ingress - #37

Merged
thorwhalen merged 1 commit into
masterfrom
argh-sweep-preserve-metar-antiexample
Sep 4, 2026
Merged

thorwhalen merged 1 commit into
masterfrom
argh-sweep-preserve-metar-antiexample

Conversation

@thorwhalen

Copy link
Copy Markdown
Member

Prerequisite for the deletion sweep (#29).

#29's acceptance criteria say the argh block in i2mint/examples
examples/airport_weather/metar_acquisition.py:80-98 must be preserved in cw's docs
before the file is touched. This does that, in cw/ingress.py's module docstring —
the module whose whole reason for existing is the problem that block gets wrong.

The block is quoted verbatim in a literal (non-doctest) code block, followed by a short
reading of what it does: it defines a shadowing wrapper that coerces airport_ids with
.split(',') and hours_before_now with int(), and then dispatches
_acquire_metar_data — the original, uncoerced function. The wrapper is never called.
Nothing raises. The except ImportError fallback is broken too.

No code change. 952 passed, 2 skipped (unchanged), and --doctest-modules cw/ingress.py
is green — the added block is indented-literal, not a doctest.

Refs #29

The deletion sweep (#29) removes the argh block in i2mint/examples'
metar_acquisition.py. Its acceptance criteria require the block be preserved
first: it is the fleet's clearest motivating example for why string-to-object
conversion belongs to the framework as a declared seam rather than to
hand-written glue at the dispatch call.

Refs #29

Claude-Session: https://claude.ai/code/session_01K6LB3AwUmKDxaFNZ2NqPGr
@thorwhalen
thorwhalen merged commit aa14b7b into master Sep 4, 2026
12 checks passed
@thorwhalen
thorwhalen deleted the argh-sweep-preserve-metar-antiexample branch September 4, 2026 11:12
thorwhalen added a commit to i2mint/examples that referenced this pull request Sep 4, 2026
Part of the fleet-wide argh removal (i2mint/cw#29).

Neither block was reachable: this repo has no packaging metadata at all, so argh
was never declared and never installed alongside these scripts. Both functions
remain importable and callable; only the argh entry points go.

metar_acquisition.py's block was additionally broken on its own terms — it built a
coercing wrapper (`.split(',')`, `int()`) and then dispatched the *original*,
uncoerced function, so the coercion never ran; its `except ImportError` fallback
called the rebound name with no arguments. It is preserved verbatim as the
motivating anti-example in cw's `cw/ingress.py` (i2mint/cw#37) before removal here,
per #29's acceptance criteria.

Refs i2mint/cw#29

Claude-Session: https://claude.ai/code/session_01K6LB3AwUmKDxaFNZ2NqPGr
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