Plan: the appeal filing window and hearing office are per program (#3394)
Status: Done (2026-11-24) — both units built; the bounds and the agreement check are in canopy-appeals and canopy-notices
Closes: #3394 (by U2)
Issues: #3394 (parent) · U1 #3553 · U2 #3554 · relates to #2426
This is a Design + Scope plan: GitLab owns tracking, the unit issues carry the implementer brief, and the plan freezes when U1 starts.
Problem
canopy-appeals has one filing window and one hearing office for every program, and a late request is refused citing SNAP law whatever the program:
-
services/canopy-appeals/src/config.rs:AppealsConfig.appeal_window_daysandhearing_office_nameare single values. -
services/canopy-appeals/src/api/mod.rs,validate_appeal_window: "Appeal request is outside the {n}-day window (7 CFR 273.15(g))", for a TANF, Medicaid, WIC or child care appeal alike. -
The deadline a letter prints is a second key,
[notices].appeal_deadline_daysor[notices.program.<p>].appeal_deadline_days(canopy-notices). Nothing makes it agree with the window canopy-appeals enforces. Georgia’s and the fixture packs' WIC letters print 60 days while[appeals]states 90. -
The window is checked only for a filing bound to an enrollment adverse action that was noticed (
resolve_action_binding,validate_appeal_window). A filing with no action, or an action never noticed, has no anchor date and is not windowed. This plan keeps that. -
The federal layer’s
hearing-request-windows.jsonholds one floor (WIC, 60 days), read only by canopy-notices against the printed deadline. A pack can set the enforced window below SNAP’s 90 days, or a Medicaid window above 90, and boot.
Programs differ. Texas’s agent reports a child care appeal window of 14 calendar days to a Local Workforce Development Board (40 TAC 823; its report, not read here), against 90 days for HHSC programs.
Decisions (maintainer, 2026-11-23)
-
The window is required for every enabled program, each with its own citation.
[appeals].appeal_window_daysis removed. -
The hearing office is required in the same per-program row;
[appeals].hearing_office_nameis removed. A first-level review before the hearing (Texas’s Board step) is its own issue. -
This plan enforces the federal bounds on the filing window only. The rest of #2426 (postponement cap, notice windows) stays with the &139 plan.
-
A pack whose printed deadline for an enabled program differs from that program’s filing window is refused at boot by canopy-appeals and by canopy-notices, naming both keys.
Federal law (read from eCFR, 2026-11-23)
| Program | Text | Bound |
|---|---|---|
SNAP |
7 CFR 273.15(g): "A household shall be allowed to request a hearing on any action by the State agency or loss of benefits which occurred in the prior 90 days." |
at least 90 days |
WIC |
7 CFR 246.9(e): "such time limit is not less than 60 days from the date the agency mails or gives the applicant or participant the notice of adverse action." |
at least 60 days (already in the file) |
Medicaid |
42 CFR 431.221(d): "a reasonable time, not to exceed 90 days from the date that notice of action is mailed, to request a hearings." |
at most 90 days |
No bound is added for TANF, child care or CHIP: none was read for them, and a row is a later data edit.
Design
The pack shape
[appeals.program.snap]
filing_window_days = 90
filing_window_citation = "7 CFR 273.15(g)"
hearing_office_name = "the Office of State Administrative Hearings (OSAH)"
[appeals.program.wic]
filing_window_days = 60
filing_window_citation = "7 CFR 246.9(e)"
hearing_office_name = "the Office of State Administrative Hearings (OSAH)"
One complete row per program, nothing inherited from another row, as [notices.program.<p>] works. All three keys are required; an unknown key in a row refuses the load. A row is required for every program in [jurisdiction].enabled_programs; a row for a program that is not enabled is allowed and unused, as a decision_clock_days entry is. filing_window_days joins check_day_counts (1 to 366). The citation and the office name must be non-blank.
AppealsConfig gains program: HashMap<Program, ProgramAppeals> and loses appeal_window_days and hearing_office_name. Per the pre-1.0 rule there is no fallback to the old keys; a pack that still carries them boots, since [appeals] tolerates unknown keys today, and they are read by nothing.
canopy-appeals behaviour
-
One lookup,
AppealsConfig::program_row(program) → Result<&ProgramAppeals, ApiError>: a program with no row is 422program_not_deployed, the codedecision_due_datealready gives a program with no decision clock. -
file_appealcalls it first, beforeresolve_contested, for every filing: action-bound or not, noticed or not. So no appeal is filed for a program with no row, whichever path it takes. -
validate_appeal_windowis handed that row. Which filings it windows is unchanged (see Problem). The refusal stays a 400: "Appeal request is outside the {n}-day filing window for {program} ({citation}). Deadline: …, request date: …". -
withdraw_appealcalls the lookup for the stored appeal’s program before it writes, at either stage, and thepost_submissiontext names that row’s office. An appeal whose program lost its row after filing is therefore 422program_not_deployedon any withdrawal, with nothing written. -
The doc comment of
DismissalBasis::UntimelyRequest(crates/canopy-contracts-appeals/src/appeals.rs) stops naming 90 days and 273.15(g).
Federal bounds and the letter (U2)
A new module canopy_reference::hearing_request_windows replaces canopy-notices' private HearingRequestWindows, so both services read one type. It lives in canopy-reference because that crate owns Program and already depends on canopy-config, serde_json and toml (its medicaid_classes loader is the precedent); canopy-common does not depend on canopy-reference, and no crate edge is added.
-
A row of the file gains an optional
max_daysbeside a now-optionalmin_days, with itsauthority; a row with neither bound refuses the load. The federal layer’s file gainssnap(min_days90) andmedicaid(max_days90); the federal agent writes it, andfixtures/config/test-federal/hearing-request-windows.jsonis kept identical. -
check(program, days, key) → Result: refuses a value outside the program’s bound, naming the key, the value, the bound and the authority. -
canopy-appeals holds each enabled program’s
filing_window_daysto it at boot. -
canopy-notices holds each enabled program’s printed deadline to it, through the shared type and for ceilings too. Today it checks every program the file lists, enabled or not; with SNAP and Medicaid rows that would hold a WIC-only pack’s
[notices]fallback to both. The loader of canopy-notices therefore reads[jurisdiction].enabled_programs, as the loader of canopy-appeals does.
Agreement, one function in the same module, called at boot by both services over the parsed jurisdiction.toml: for every enabled program, the printed deadline ([notices.program.<p>].appeal_deadline_days when that table exists, else [notices].appeal_deadline_days) must equal [appeals.program.<p>].filing_window_days. A difference refuses the boot naming both keys and both values. A program-less notice has no program and is not checked.
Fixture packs under the agreement rule: every fixture’s enabled programs print 90 except WIC’s 60 (default, test-max), so their rows are 90 and WIC 60. To keep the two packs different, test-max gains a complete [notices.program.caps] identity with appeal_deadline_days = 14, its citations.toml rows, and a child care row of 14; default keeps child care at 90.
Order with the config repositories
-
U1. Georgia adds its six rows as a held commit, keeping the old keys (both shapes boot on
main). Verified from an archive, merged, pinned as its own commit before the code. Georgia’s WIC row states 60 or its WIC letters move to 90: its own choice on its own evidence (see Risks). Georgia removes the two old keys after U1 merges. -
U2. The federal file’s new rows are a held commit; pinned as its own commit first in U2’s MR, with the code that reads the new shape in the same MR, because canopy-notices on
mainrefuses a row withoutmin_days. -
Texas is not pinned. It is told the shape; its child care row and a matching
[notices.program.caps]table are its own work.
Tests
| Category | Tests |
|---|---|
Unit (config) |
|
Unit (route logic) |
|
Routed (postgres) |
|
Unit (bounds) |
|
Unit (agreement) |
|
Boot |
canopy-appeals and canopy-notices each: |
Contract |
The federal file and its fixture copy parse into the shared type; the existing floor tests of canopy-notices pass through it unchanged in meaning. |
Regression |
|
Not run locally (the car’s): the tests/ stack targets of canopy-appeals and canopy-notices, and the e2e appeal journeys.
Risks
| Risk | Mode | Mitigation |
|---|---|---|
A pack enables a program and forgets its row. |
fail-closed |
The load refuses, naming the program; |
Georgia’s WIC letters print 60 days and |
silent |
It is announced to Georgia with both values; the choice is Georgia’s on its evidence, made in its held commit and stated on the MR and in the changelog. |
A pack restates a wrong citation. |
silent |
The citation is pack data with its |
The federal file’s new shape reaches a canopy that reads only |
fail-closed |
That canopy-notices refuses to boot; the pin and the reader land in one MR, pin first. |
A federal bound is missing for a program that has one (CHIP, TANF). |
fail-open |
The 1-to-366 range still holds; the plan states which were read, and a row is a data edit in the federal repository. |
A program is disabled while its appeals are open. |
fail-closed |
A withdrawal of such an appeal is 422 |
A filing with no noticed action is not windowed, so a late one is accepted. |
fail-open |
Unchanged from today and out of this issue’s scope: there is no date to count from. |
The pack check ( |
fail-closed |
The services refuse at boot; a held pack commit is verified here by running the config tests on the swapped-in archive before "merge". #3557 adds the checks. |
Scope
| Unit | Work | Status |
|---|---|---|
U1 |
|
Done (2026-11-24) |
U2 |
The shared bounds type in canopy-reference; the federal file’s ceiling shape and its pin; canopy-notices scopes its check to enabled programs; canopy-appeals holds windows to their bounds; the letter-and-window agreement check in both services; closes #3394. |
Done (2026-11-24) |
Out of scope, each its own issue: a first-level review before the hearing (#3555); good-cause exceptions to the filing window (#3556); a pack check for these refusals (#3557); a window for filings with no noticed action (#3558). The rest of #2426 stays with &139.
Delivery
-
Doc pages:
api/canopy-appeals.adoc(the refusal, the 422),rulesets.adoc(the row, the removed keys, the agreement rule),federal-requirements.adoc(the SNAP, Medicaid and WIC rows),jurisdiction-onboarding.adoc. -
CHANGELOG.adoc== Unreleased: one entry per unit; U1’s names the removed keys and Georgia’s WIC change. -
This plan page with its nav entry, merged before U1.
-
Config agents told on
canopy/rulesat approval: the shape, the direction of each bound, the agreement rule, and what each must write. -
The close: U2’s MR closes #3394; the merge SHAs are noted on it, and #2426 is noted with what this took from it.
Errata
-
Erratum (2026-11-24): Georgia’s held commit also gave TANF, Medicaid, PeachCare and CAPS their own
[notices.program.<p>]tables, so those letters print 30, 30, 30 and 14 days in place of 90. The plan expected only the WIC figure to move. -
Erratum (2026-11-24): the unit tests of the bounds and of the agreement rule are in
canopy_reference::hearing_request_windows; each service has the boot tests. canopy-appeals addsa_pack_above_the_medicaid_ceiling_does_not_loadanda_row_for_a_program_that_is_not_enabled_is_held_to_nothing, and the module addsan_enabled_program_with_no_row_cannot_be_shown_to_agree. -
Erratum (2026-11-24): two existing range tests set a one-day window, which the SNAP floor and the agreement rule now refuse; each was narrowed to the range alone (canopy-notices through
NoticeConfig::parse, canopy-appeals on child care with a matching printed deadline).