You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm working on an app that allows users to connect to hardware devices via WiFi. As a result, internet conection is not always available during app use, so to ensure no analytics events / screen views are lost, we're calling
before internet connection is lost. This works for the most part - while we're not connected to the internet, no analytics data is uploaded. But for some reason, when there's a change in the network state (ie when the user disconnects from one of our hardware devices) Segment attempts a flush, regardless of flush policy. This flush usually fails (because normal internet connection hasn't been reestablished) and those events / screen views are then lost. The logs look like this
I can't see a way to avoid this. I can confirm that at the time the above logs are appearing, analytics.getFlushPolicies() returns an empty list. I've also tried using a custom flush policy that is designed to never flush, but the same thing happens.
This is a problem for us as we want our analytics tracking to be as reliable and complete as possible. Any help would be greatly appreciated.
Hi @fergushowe-wa , We have worked on the issue of queued events getting lost and released version 1.1.10 with a patch. We recommend you to please update your SDK and let us know if it fixed your problem. Kindly ensure to use storageJson=true when initializing the analytics client.
Activity
neelkanth-kaushik commentedon Oct 20, 2025
Hi @fergushowe-wa , We have worked on the issue of queued events getting lost and released version 1.1.10 with a patch. We recommend you to please update your SDK and let us know if it fixed your problem. Kindly ensure to use storageJson=true when initializing the analytics client.
fergushowe-wa commentedon Oct 30, 2025
Hi @neelkanth-kaushik thanks very much, we've upgraded to 1.1.10 and tested and it's working perfectly now, appreciate the help.