Skip to content

spec(v4): promote R4-P0-2 KLICKD_E_* user-facing error i18n table to normative (docs-only)#39

Merged
Davincc77 merged 1 commit into
mainfrom
spec/v4-p0-2-error-i18n-table
May 24, 2026
Merged

spec(v4): promote R4-P0-2 KLICKD_E_* user-facing error i18n table to normative (docs-only)#39
Davincc77 merged 1 commit into
mainfrom
spec/v4-p0-2-error-i18n-table

Conversation

@Davincc77
Copy link
Copy Markdown
Owner

Summary

  • Inscribes the normative user-facing error message contract (RFC 2119) for v4 user.klickd writers / readers in FR / EN / DE / LB as the docs-only companion to R4-P0-1 §3.4 (passphrase) and §3.6 (mandatory reload verification).
  • Adds docs/spec/R4-P0-2-error-i18n-table.md covering every KLICKD_E_* code surfaced in the wizard, with: localized message FR/EN/DE/LB, recommended autonomous user action (no "contact support"), severity, recoverability, and a safe-disclosure rule (do not leak whether file vs passphrase failed where unsafe; do not name failing gate / missing field).
  • Adds SPEC.md §33.12 cross-reference (mirrors §33.11 for R4-P0-1) and updates the docs/roadmap/ROAD-TO-V4-GA.md R4-P0-2 entry to reference the new normative artifact (status: contract inscribed).
  • Introduces, docs-only, six new wizard-contract codes not yet in the v3.x SDKs: KLICKD_E_PASS_MISMATCH, KLICKD_E_SAVE_LOCAL, KLICKD_E_LEGACY_VERSION, KLICKD_E_CORRUPT, KLICKD_E_POLICY_LOCKED, KLICKD_E_UNSAFE_QR. SDK alignment is deferred to R4-P0-3 (Python) / R4-P0-4 (TypeScript).

Why this lands now

R4-P0-1 §3.4 and §3.6 already depend on a normative user-facing error contract; the bare v3.x identifiers (KLICKD_E_AUTH, _VERSION, _FORMAT, _KDF, _CIPHER, _WEAK_PASS, _SCHEMA) are unusable to non-developer end-users (anti-pattern A6). This PR closes that dependency without touching SDK / schema / vectors.

Scope (strict)

  • ✅ Docs-only. No on-the-wire field, schema, or vector change.
  • ✅ No SDK code modified (errors.py / errors.ts untouched).
  • ✅ No package version bump, Git tag, GitHub release, npm / PyPI / Zenodo / DOI publication.
  • ✅ No change to SPEC §33.7 forward-compatibility contract or §33.10 privacy invariants.
  • ✅ No app i18n / UI implementation; wizard implementation remains hors-repo (klickd.app).

Coverage (R4-P0-1 wizard contexts)

Wizard context Codes covered
Passphrase creation (R4-P0-1 §3.4) KLICKD_E_WEAK_PASS, KLICKD_E_PASS_MISMATCH
Save / download (§3.5) KLICKD_E_SAVE_LOCAL
Mandatory reload verification (§3.6) KLICKD_E_AUTH, KLICKD_E_FORMAT, KLICKD_E_SCHEMA, KLICKD_E_VERSION, KLICKD_E_KDF, KLICKD_E_CIPHER
Import / decrypt (§3.1 secondary entry) + KLICKD_E_LEGACY_VERSION, KLICKD_E_CORRUPT
Legacy version / migration KLICKD_E_LEGACY_VERSION
Corrupt / unsupported file KLICKD_E_CORRUPT, KLICKD_E_FORMAT, KLICKD_E_KDF, KLICKD_E_CIPHER
Locked policy violation KLICKD_E_POLICY_LOCKED
Unsafe QR / deeplink (V4-ONBOARDING-QR-DEEPLINK.md C1–C7) KLICKD_E_UNSAFE_QR

Safe-disclosure rule (excerpt)

  • KLICKD_E_AUTH message MUST remain ambiguous between wrong-passphrase and tampered-file.
  • KLICKD_E_FORMAT / KLICKD_E_SCHEMA MUST NOT name specific missing envelope / payload fields to the user.
  • KLICKD_E_POLICY_LOCKED MUST NOT name the specific failing gate.
  • KLICKD_E_UNSAFE_QR MUST NOT echo the offending payload.
  • Developer-mode diagnostics MAY include these details — must be opt-in and MUST NOT be auto-sent off-device (preserves §33.10 privacy invariants and R4-P0-1 §3.5 zero-network constraint).

Files changed

  • docs/spec/R4-P0-2-error-i18n-table.mdnew (~486 lines, normative)
  • SPEC.md — +33 lines (§33.12 pointer)
  • docs/roadmap/ROAD-TO-V4-GA.md — R4-P0-2 entry updated

Testing

  • Markdown relative links resolve (verified script).
  • 13 KLICKD_E_* rows, each with FR / EN / DE / LB columns + action + severity + recoverability + safe-disclosure.
  • No new on-the-wire field, schema, or vector introduced (docs-only).
  • SDK errors.py and errors.ts untouched.
  • No package version, Git tag, or release artifact modified.
  • CI: should be green (docs-only — no code paths touched).

Recommended next branch

R4-P0-3examples/v4/personas/ (5 downloadable persona profiles: élève terminale FR, chef de projet PME FR, dev full-stack EN, créateur média preview media.klickd, joueur RPG preview gaming.klickd). R4-P0-3 fixtures can land as preview artefacts referenced by R4-P0-1 §3.1 (the "I already have a user.klickd file → import" secondary path) ahead of strict P0-2 / P0-6 validation.

🤖 Generated with Claude Code

…normative (docs-only)

Inscribes the normative user-facing error message contract for v4
`user.klickd` writers / readers in FR / EN / DE / LB, per RFC 2119.

R4-P0-2 lands now because R4-P0-1 §3.4 (passphrase confirmation) and
§3.6 (mandatory reload verification) already depend on a normative
user-facing error contract that the bare v3.x SDK code identifiers
(`KLICKD_E_AUTH`, `_VERSION`, `_FORMAT`, `_KDF`, `_CIPHER`,
`_WEAK_PASS`, `_SCHEMA`) cannot provide on their own.

What lands (docs-only):

- docs/spec/R4-P0-2-error-i18n-table.md — normative companion to
  R4-P0-1, defining for every `KLICKD_E_*` code surfaced in the
  wizard:
  * user-facing message in FR / EN / DE / LB
  * recommended autonomous user action (no "contact support")
  * severity (error / warning / info) and recoverability class
  * safe-disclosure rule (do not leak whether file vs passphrase
    failed where unsafe; do not name failing gate / missing field)
- Coverage of every R4-P0-1 wizard step: passphrase creation,
  save / download, mandatory reload verification, import / decrypt,
  legacy version / migration, corrupt / unsupported file, locked
  policy violation, and unsafe QR / deeplink (per
  V4-ONBOARDING-QR-DEEPLINK.md C1-C7).
- Codes introduced docs-only for the wizard contract (not yet in
  SDKs): `KLICKD_E_PASS_MISMATCH`, `KLICKD_E_SAVE_LOCAL`,
  `KLICKD_E_LEGACY_VERSION`, `KLICKD_E_CORRUPT`,
  `KLICKD_E_POLICY_LOCKED`, `KLICKD_E_UNSAFE_QR`. SDK alignment is
  deferred to R4-P0-3 (Python) / R4-P0-4 (TypeScript).
- SPEC.md §33.12 added as the cross-reference pointer to the
  R4-P0-2 artifact (mirrors §33.11 for R4-P0-1).
- docs/roadmap/ROAD-TO-V4-GA.md R4-P0-2 entry updated to reference
  the new normative artifact and mark the contract as inscribed.

Strict scope guarantees:

- No on-the-wire field, schema, or vector change.
- No SDK code modified (errors.py / errors.ts untouched).
- No package version bump, Git tag, GitHub release, npm / PyPI /
  Zenodo / DOI publication.
- No change to SPEC §33.7 forward-compatibility contract or §33.10
  privacy invariants.
- No app i18n / UI implementation; wizard implementation remains
  hors-repo (`klickd.app`).
@Davincc77 Davincc77 merged commit 8b95b0b into main May 24, 2026
3 checks passed
@Davincc77 Davincc77 deleted the spec/v4-p0-2-error-i18n-table branch May 24, 2026 18:27
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.

1 participant