Repository navigation
Description
Split out of #535, which built the report. The report is correct and reads zero, because nothing collects the data.
core.eeo_self_identification has 0 rows on local, dev, preview and prod. There is no form, no API write path, and no point in the application flow where a candidate is offered the question. The screen says so explicitly rather than implying a clean bill of health, but that is a disclosure, not a fix.
Why this was not done in #535
The self-identification wording is a product and legal decision, not an implementation detail. EEO self-ID forms carry required language about voluntariness, about the data not affecting the hiring decision, and about who can see it. Writing that copy from a PR would be inventing legal text.
What already exists
- The table, with CHECK constraints fixing the vocabulary:
ethnicity(7 categories +declined),gender(male/female/non_binary/declined),veteran_status,disability_status. Alsocollection_methodandform_version, which exist so a change in wording is auditable — use them. - Grants, since migration 343:
authenticatedhasSELECT, INSERTand deliberately noUPDATEorDELETE. A self-identification is an audit record, not an editable field. Do not "fix" that. - RLS:
auth.uid() = user_id. An applicant reaches their own row and nobody else's. - The aggregation and report:
GET /v1/employer/eeo-report(feat(compliance): wire the EEO report to real data #567). It will start producing real figures the moment rows exist — no reporting work is needed here.
Work
- Legal/product sign-off on the form copy, including the voluntariness statement and the disclosure about who sees the data.
- A candidate-facing form, offered at a point in the flow where declining is genuinely costless and visibly separate from the application itself.
- A write path.
INSERTonly — the grants already enforce this, so an "edit" affordance would fail at the database and should not be built. - Set
form_versionfrom the approved copy version, so a later wording change is distinguishable in the data rather than silently blended into it.
Acceptance
- A candidate can self-identify, decline, or ignore the form entirely, and the application proceeds identically in all three cases.
- Rows land with
form_versionset. /v1/employer/eeo-reportreturns non-zero figures without any change to the reporting code.- No surface anywhere exposes an individual response to an employer.
One thing to get right
declined is a real answer and must be stored as such. Storing nothing when someone declines makes "declined" and "never asked" indistinguishable, and the report needs them separate — a declined respondent is in the denominator.
Not agent-ready: step 1 is a human decision.
Activity