Simpl-Resultat/docs
le king fu 7d667f7ca3
All checks were successful
PR Check — Frontend / frontend (pull_request) Successful in 1m40s
PR Check — Rust / rust (pull_request) Successful in 8m52s
fix(license): call /v1 routes with product, name server refusals, localize purchase URL
- Activation, deactivation and verify POST to /v1/licenses/* with
  "product":"simpl-resultat" instead of the legacy /licenses/* paths,
  which cost a 308 on every call.
- New LicenseError enum, serialized as {code} like FetchPriceError and
  read from error.code of the /v1 envelope. A 200 {valid:false} from
  verify is now a coded refusal instead of an empty machine list, and an
  HTML error page on a non-2xx maps to server instead of
  invalid_response. Deactivation is idempotent: no_active_activation
  counts as done.
- The three calls live in *_inner functions without AppHandle, tested
  against a mockito server that only declares the /v1 routes.
- useLicenseMachines hook with an exported reducer. The activation error
  survives the list load it triggers (machine_limit_reached opens the
  list), a deactivation removes the machine locally without re-running
  verify (4 requests on the machine-limit path, under the server's
  5/min/IP limit), and refresh() follows every successful activation or
  deactivation.
- license.errors.* in FR and EN; purchaseUrl() opens
  /{fr|en}/produits/simpl-resultat.

test: reproduces #270. Each original defect, reintroduced on the final
tree, turns tests red: legacy activate path 5, missing product 2,
envelope read as a string 3, verify valid:false as an empty list 2,
strict body parse on a non-2xx 2, untrimmed key 1, list load clearing
the activation error 4, verify re-run after deactivation 2, empty state
despite a list error 1, no refresh after activation 3, old purchase
URL 4.

Fixes #270

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-26 09:15:52 -04:00
..
adr fix(deps): resolve the quick-xml advisories, unyank deep-link and spin 2026-08-15 11:51:46 -04:00
archive docs: organize technical documentation into docs/ folder 2026-02-19 07:34:01 -05:00
api-contract-prices.md docs: replace JWT-like Bearer placeholder with <license-token> (#181) 2026-05-02 16:05:20 -04:00
architecture.md fix(license): call /v1 routes with product, name server refusals, localize purchase URL 2026-09-26 09:15:52 -04:00
audit-bilan-2026-05.md feat(balance): audit quick wins — terminology, optional symbol, movable snapshot date (#201) 2026-05-31 21:05:13 +00:00
guide-utilisateur.md docs: architecture, ADR 0019, user guide and changelog for the import format 2026-08-14 11:13:25 -04:00
qa-refonte-seed-categories-ipc.md test(categories): complete test coverage for migration flow (#123) 2026-04-21 19:25:13 -04:00
qa-update-cycle.md docs(qa): the update-cycle trace lives in the release body, not a comment 2026-09-13 14:01:25 -04:00