feat: add PushStateReporter for push reachability reports - #40
Conversation
|
Note Kodizm (AI-generated). May contain mistakes; verify before acting. The reporter's logic looks correct and well tested, but the package does not yet declare that it needs the newer magic API it now calls. Major
Minor
Tests
CI
|
…ent Notify.pushState in the README, raise the magic floor to ^0.0.22
|
Fixed in 32ebbd1. Major, Minor,
Minor, README missing Backend cross-check against magic-starter-laravel#45 (
Gates, run locally against magic#205's head (89c4daa) through a temporary CI: @kodizm please re-review. |
|
Note Kodizm (AI-generated). May contain mistakes; verify before acting. All three earlier findings are fixed in 32ebbd1, and I found nothing new. The only thing left is the CI failure, which the PR expects until magic 0.0.22 is published. What changed since my last review:
Tests
CI
|
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Summary
PushStateReporter, reached asNotify.pushState. The device tells its backend whether a push can reach it (subscription id, permission, opt-in) and withdraws that on sign-out. Moved here from the one app that had written it.notifications.push_state.report_pathandrelease_pathare null in the install stub, so an app whose backend has no such route sends nothing;external_id_prefixdefaults touser_, matching magic-starter-laravel.isConfiguredtells the wiring code whether to attach;releaseis idempotent and skips a device with no subscription.The matching backend routes are in the magic-starter-laravel PR of this set.
Verification
flutter analyzeclean,flutter test735 passing, format clean.Part of a coordinated set
This PR is one of eight that move reusable, app-agnostic pieces out of Uptizm into the magic framework and its plugins, so any magic app can use them the Laravel way.
Merge order:
fluttersdk/magicfirst: every plugin PR compiles against its new API (SessionScope,Repository,MagicAction,Event.listenAny,ReportsBreadcrumb).magic_deeplink,magic_notifications,magic_paymentsandmagic_sentry, in any order.magic_starter, which uses magic core'sSessionScope,magic_payments'StoreIdentitySyncandmagic_deeplink's gate.magic-starter-laravelis independent of the Flutter side.anilcancakir/uptizmlast.Until magic merges and ships, CI on the plugin PRs resolves the published magic and is expected to be red. Each branch was verified locally against the sibling working trees (analyze, the full test suite, format check).
No version bump, publish or tag is included; a release is a separate step.