devfeedbackhub_analytics 3.0.0
devfeedbackhub_analytics: ^3.0.0 copied to clipboard
Lightweight analytics SDK for DevFeedbackHub - track tester behavior and goal completion in your app.
3.0.0 #
Fixed #
- Device identity (critical). 2.0.0 generated a fresh random UUID as the
device id on every launch, so the server could never match the tester
(
users.device_id) and no goal completion or credit reward could ever fire. The SDK now resolvesSettings.Secure.ANDROID_ID- the same value the DevFeedbackHub app stores - and persists a stable UUID fallback when it is unavailable. - Authorization. Requests carried no auth header, so the
track-analyticsendpoint rejected every call with401 UNAUTHORIZED_NO_AUTH_HEADER. The project's public anon key is now sent asapikey/Authorization. - Unbounded retry queue. Permanently failing responses (400/401/403/404/422) were re-queued forever, growing memory on every flush. They are now dropped; only transient failures (429/5xx/network) are retried, with exponential backoff capped at 5 minutes, and the queue is bounded at 200 events.
dispose()now clears the pending queue.
Changed #
- BREAKING: requires Flutter. Reading
ANDROID_IDneeds a platform plugin, so the package depends onflutter,android_idandshared_preferencesagain (as in 1.x). Pure-Dart projects can no longer depend on this package. - BREAKING:
debugnow defaults tokDebugModeinstead oftrue, so release builds stay quiet. Passdebug: trueto force logging. - Logging uses
debugPrintinstead ofprint.
Added #
DFHAnalytics.isInitializedandDFHAnalytics.deviceIdgetters.- Debug log noting
tester_matched: false, the usual cause of "no credits".
2.0.0 #
- Add recurring goal tracking support (
onRecurringProgresscallback) - Add
RecurringProgressItemmodel for daily progress data - Event batching (5s interval, 20 max batch)
- Auto-retry on network failure
- Improved debug logging with recurring progress details
Note (added retroactively): 2.0.0 contained two defects that made the SDK non-functional end to end - a randomized device id and a missing auth header. It also removed
DFHNotificationConfig,DFHPositionand theshowNotification/notificationConfig/messengerKeyparameters ofinit()without a migration note, and changedtrack()fromFuture<bool>tovoid. Upgrade to 3.0.0.
1.0.0 #
- Initial release
DFHAnalytics.init()- Initialize with request IDDFHAnalytics.track()- Track events- One-time goal completion callbacks
- Auto device ID generation
- Debug logging support