Flutter and Sentry

2021-03-31T02:32:01.000Z

I’ve been using Sentry with Flutter for a while, perhaps since the first Flutter support was added. The recent 4.0 upgrade has been one if the best upgrades in a while, firstly the setup is now much simpler and cleaner.

See the full docs here.

While adding context was always possible the new syntax and documentation have cleared up how to add context. Adding the context is extremely useful when trying to find the edge case bugs that just don’t seem possible and you wonder just how did the user manage to do that!

Hopefully some of those long stating bugs will now be squashed, or at least I’ll be able to identify the subset of users experiencing the problem.

Make sure you wrap your widget with runApp(MyApp()) as shown or you’ll just get a blank screen and no error.