Module talk:CalibrationCycle
Calibration Report - 2026-07-13
Reviewer: Sovereign Review Type: Self-Assessment
Summary of Changes
- Hardened date validation: the date-parsing check previously only verified the year component (`not y`) was present; month and day could still be nil and crash `os.time()` with a malformed date string. Now all three components are checked before proceeding.
- Added a defensive check after `os.time()` itself, in case an invalid date (e.g. an out-of-range month) produces a bad result rather than erroring cleanly.
- Added support for indirect invocation via a parent template frame (`frame:getParent().args`), allowing this module to work correctly whether called directly via `#invoke` or through a template that passes arguments through — relevant given how deeply templates are nested across this wiki.
- Wrapped the `getParent()` call in a `pcall` via a new `getArg()` helper, so a missing parent frame degrades gracefully to `nil` instead of risking an uncaught Lua error — the same defensive pattern used to fix Module:IsAdmin's earlier `mw.user` nil-crash bug. This was a proactive hardening, not a response to an observed failure — no crash from this specific cause has been seen in practice, but the failure mode is structurally identical to one already found and fixed elsewhere.
instrument_grade: Development → Confirmed
calibration_rationale: This module has now been directly exercised through today's extensive namespace bug hunt (used repeatedly across multiple test pages, both broken and working, as part of diagnosing the SMW Template-namespace issue) and had a real latent validation bug found and fixed as a result of that testing. The defensive hardening applied here mirrors a pattern already proven necessary in a sibling module (IsAdmin), which increases confidence this is addressing a real class of risk rather than a hypothetical one. Upgraded from Development to Confirmed — self-assessed, but backed by genuine exercise under real conditions today, not just review on paper. review_confidence: High
Validation: Low → Moderate
Previously untested beyond initial construction. Today's bug hunt exercised this module across numerous real page loads under varying conditions (working pages, broken pages, direct test pages), which constitutes real, if informal, field use. Not yet High, since it hasn't been independently reviewed or stress-tested with deliberately malformed date inputs.
Fields Changed
instrument_grade: Development → Confirmed validation: Low → Moderate Version: 0.1 (implicit) → 0.2
Open Items
- Not yet tested with deliberately malformed `review_date` values (e.g. "2026-13-45") to confirm the hardened validation actually catches them gracefully rather than just theoretically.
- Consider whether this module should also get an entry in the future "Known Site Issues & Fixes" page, given it was central to today's namespace bug diagnosis, even though the module itself wasn't the root cause.
See the Game. Refuse the Game. Build Better.