Skip to content

type coercion misses options with a bare dest#86

Merged
roed314 merged 1 commit into
roed314:masterfrom
roed-math:fix/config-coercion
Jul 20, 2026
Merged

type coercion misses options with a bare dest#86
roed314 merged 1 commit into
roed314:masterfrom
roed-math:fix/config-coercion

Conversation

@roed-math

Copy link
Copy Markdown

Configuration.get() looks up option types under "<section>_<key>", but the type table is keyed by argparse dest, which for misc-section options is the bare key — so those options skipped coercion entirely and a store_true default came back as the string "False", which is truthy. The lookup now reconstructs the dest for both shapes.


Split out of #60 (one PR per issue). This branch carries only this issue's fix and its tests; the rest of the known-bug inventory stays xfailed, so the full suite is green here and the strict markers guarantee no cross-issue leakage.

Configuration.get() looks up option types under "<section>_<key>", but the type table is keyed by argparse dest, which for misc-section options is the bare key — so those options skipped coercion entirely and a store_true default came back as the string "False", which is truthy. The lookup now reconstructs the dest for both shapes.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@roed314
roed314 merged commit 48b300f into roed314:master Jul 20, 2026
16 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.

2 participants