
Part of: - https://github.com/flutter/flutter/issues/128251 Currently, when we want to use the analytics instance from `package:unified_analytics`, we are just grabbing it from globals. However, with the legacy analytics instance, there are some things we check to return a no-op version of the instance.. for example, if we are running on bots or a non standard branch, we use a no-op instance This PR uses the same previous checks for the new analytics instance
Flutter reports data to two separate systems:
- Anonymous usage statistics are reported to Google Analytics (for statistics
such as the number of times the
flutter
tool was run within a given time period). The code that manages this is in [usage.dart]. - Crash reports for the
flutter
tool. These are not reports of when Flutter applications crash, but rather when the command-lineflutter
tool itself crashes. The code that manages this is in [crash_reporting.dart].
Opting out
Users can opt out of all reporting in a single place by running
flutter config --no-analytics
.