refactor(checkpoints): Add DeviceDimensionProvider (#3943)
### Description Adds the first dimension provider, so rule predicates have something to read: `device.appVersion`, `device.locale`, `device.platform`, `device.platformVersion` and `device.sdkVersion`. <!-- CURSOR_SUMMARY --> --- > [!NOTE] > **Medium Risk** > Enables real checkpoint audience matching on device/locale/platform fields; camelCase dimension keys are a new predicate contract, though behavior is additive with tests covering provider and platform mapping. > > **Overview** > **Local rules can now read device context.** `PurchasesFactory` wires `DeviceDimensionProvider` into `LocalRulesEvaluator` (replacing an empty provider list), so checkpoint predicates can target `device.appVersion`, `device.locale`, `device.platform`, `device.platformVersion`, and `device.sdkVersion`. > > `DeviceDimensionProvider` snapshots most values at configure time but **re-reads locale** on each evaluation (normalized to lowercase `en_us`), omits empty string dimensions, and maps Amazon vs other stores via shared `Store.platformName`. That same extension replaces `HTTPClient`'s private `X-Platform` mapping so headers and rules stay aligned. > > Dimension key documentation and resolver tests move from **snake_case to camelCase** (`appVersion` vs `app_version`) to match the nested `device.*` paths the engine resolves. > > <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit d52917764ec5bf1b8d1fc0eb864fb189777fff62. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> <!-- /CURSOR_SUMMARY --> Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
T
Toni Rico committed
826c49f8a9c9e2c6cb71bddc1c9e42cd4fcbcdce
Parent: 2ce1db2
Committed by GitHub <noreply@github.com>
on 8/13/2026, 8:24:23 AM