When opted in users start the app for the first time after install/upgrade, the app should send a 'session_start' event to the MobileWikiAppiOSSessions table, and take a snapshot of the user configuration and send it to the MobileWikiAppiOSUserHistory table at the same time. However, in 18.104.22.1681, there are 324793 unique app IDs in MobileWikiAppiOSSessions table, but only 194487 unique app IDs in MobileWikiAppiOSUserHistory table. About 40% of apps didn't send their snapshots!
After some investigation, there are 2 issues may be related to this bug:
1, Events are not being queued over multiple sessions. Currently, it seems the events are only queued for the last session, but not older sessions.
Steps to reproduce:
- Clean install 22.214.171.1241
- Set up Charles proxy to allow throttling. In throttle settings, change the bandwidth to 0kbps
- Start the app for the first time, opt in to send usage report. Of course, we can't see any feed other than the education cards
- Take the app to the background to end this session. Then, turn on the app to start a 2nd session, and turn off again.
- Stop throttling
- Take the app to the foreground again to start the 3rd session. From Charles proxy, we only see the queued 'session_end' events from last session, but no snapshots and other events occured during the first session.
2, Users from target countries are not being identified correctly.
After breaking down the tables by countries, we found that out of the users who sent eventlogging to other tables but not sent snapshots, 17.6% are Germany, 9% are Italy, 8% are France, 6.4% are Japan, 4% are Spain, 4% are Russia, 3.7% are Netherlands, 3.6% are Switzerland, 3.4% are US, 2.7% are Sweden, etc. Because this distribution of the problematic users is not proportional to our user population (we have ~30% user from US, 8.5% from Germany, 7% from UK...), this doesn't seem random and may have something to do with our target countries identification.