feat: gate auto-updates behind license entitlement (#48) #58
No reviewers
Labels
No labels
source:analyste
source:defenseur
source:human
source:medic
status:approved
status:blocked
status:in-progress
status:needs-fix
status:ready
status:review
status:triage
type:bug
type:feature
type:infra
type:refactor
type:schema
type:security
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: maximus/Simpl-Resultat#58
Loading…
Reference in a new issue
No description provided.
Delete branch "issue-48-gate-auto-updates"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fixes #48
Depends on #46 (chain-branched from
issue-46-license-commands-entitlements).Summary
useUpdater.tscallscheck_entitlement('auto-update')before fetching update metadata; newnotEntitledstatusErrorPage.tsx(recovery screen) also gates the manual update check for consistencysettings.updates.notEntitledanderror.updateNotEntitled(FR + EN)Architecture note
The gate name (
'auto-update') maps to the centralizedFEATURE_TIERSlist incommands/entitlements.rs. To move auto-updates to a different tier later, edit the single mapping in that module — no need to touch components.Test plan
Review (sprint inline) — APPROVE
Points vérifiés
useUpdaterET dansErrorPage— pas de chemin de contournement'auto-update') match exactement la clé dansFEATURE_TIERS(entitlements.rs)commands/entitlements.rs::FEATURE_TIERSnotEntitledajouté au reducer + UI block dans SettingsPagenotEntitled), donc l'utilisateur voit un vrai message d'erreur, pas un faux paywallSuggestion non bloquante
check_entitlementest dupliqué dansuseUpdater.tsetErrorPage.tsx(~3 lignes chacun). Acceptable pour 2 callsites, mais si une 3e arrive, refactor en helperuseEntitlement(feature)ouentitlementService.ts.Aucun problème critique.
174c07de51to6d67ab8935