Skip to content

ADR-017 Appendix B step 2: verify CONSUMER_DOCUMENT_NAME against the registry, then retire the source-read (D3+D4) #238

Description

@Polichinel

Filed by the views-faoapi (consumer) seat, to make the producer half of the ADR-017 delivery-name loop trackable — it currently lives only as prose in ADR-017 Appendix B step 2 and in the closed review #232. I changed nothing in this repo; this is an issue so the step has a home and a gate.

The loop this closes (one shared objective, five states across three repos)

The invisible-delivery failure (ADR-017 §1): you upload each delivery with a store-document name; views-faoapi filters every query on it; if they drift, the upload succeeds, the file is stored and paid for, the endpoint returns empty, and nothing raises. The fix binds both sides to one public authority (the registry) and retires the cross-repo source-read.

  • D1 — declare un_fao in the registry — ✅ done & released (views-appwrite#75, tag appwrite-seam-v1.5.0, [contract.UNFAO_CONSUMER_DOCUMENT_NAME].value = "un_fao").
  • D2 — views-faoapi self-checks its filter name vs the tagged row — views-faoapi#379.
  • D3 + D4this issue.
  • D5 — views-appwrite lifts the row's "not yet an authority" caveat — tracked separately (linked in a comment below).

D3 — verify the producer mirror against the registry (Appendix B step 2)

Switch the check so it reads the public registry instead of views-faoapi's source: assert this repo's mirror (CONSUMER_DOCUMENT_NAME in the unfao product module) equals [contract.UNFAO_CONSUMER_DOCUMENT_NAME].value read from views-appwrite pinned at appwrite-seam-v1.5.0. Runs in CI, needs no faoapi access and no credential (the registry is public; faoapi's source is not read at all).

D4 — retire the source-reading check — GATED on views-faoapi#379

Remove the existing check that reads faoapi's source (managers/api.py APIPathManager(...) arg + managers/prediction/manager.py selection filter). Only once views-faoapi#379 (D2) lands — ADR-017 §5: until the consumer self-checks, this row is "a string a human typed," and a producer-side check against it "would prove only that two values this platform authored agree with each other." So D4 waits on D2; D3 does not.

Scope caveat — do NOT fold in the CRAF'd sibling-fetch removal here

ADR-017 Appendix B step 2 also mentions "in the same change, stop fetching views-crafdapi in CI." That retirement is gated on CRAF'd's registry row existing, which is deferred (CRAF'd's label is not a decided value — views-crafdapi#39; views-appwrite#75 declares FAO only). Coupling it to this FAO-path issue would re-create the "stall the ready half behind the blocked one" trap ADR-017 was written to avoid. Track the crafd-fetch removal with the CRAF'd declaration, not here.

Acceptance

  • CI asserts the producer mirror == the registry row at appwrite-seam-v1.5.0, without reading faoapi's source, no credential.
  • The source-reading check is removed after views-faoapi#379 lands (not before).
  • The crafd-fetch removal is explicitly out of scope (tracked with the CRAF'd row).

Cross-refs: views-appwrite#75 (D1), views-faoapi#379 (D2 — gates D4). D5 linked below.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions