-
-
Notifications
You must be signed in to change notification settings - Fork 239
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Flutter multiview support #2225
Comments
hey, thx for the issue, I'll have a look here |
hey we're making a short doc on how to make sentry flutter compatible with multiview: getsentry/sentry-docs#11308 there are a couple things that currently do not work/need to be disabled by you with multiview such as user interaction integration, screenshots etc.. more info will follow |
@p-mazhnik The root causes are, that the Until the docs are updated, here is a summary:
import 'package:sentry_flutter/src/integrations/widgets_binding_integration.dart';
...
SentryFlutter.init(
(options) {
...
final integration = options.integrations
.firstWhere((element) => element is WidgetsBindingIntegration);
options.removeIntegration(integration);
},
// Init your App.
appRunner: appRunner,
); Just for completeness, here is a link to the Flutter docs explaining the basics and how to enable |
Docs have been merged |
Platform
Flutter Web
Obfuscation
Disabled
Debug Info
Disabled
Doctor
Version
8.7.0
Flutter 3.24 introduced multiview support in web: https://docs.flutter.dev/platform-integration/web/embedding-flutter-web#enable-multi-view-mode.
This makes code that uses
WidgetsBinding.instance.window
incompatible with this Flutter version when multiview is enabled. Note thatwindow
getter was already marked as deprecated and warning is currently ignored in Sentry codebase:sentry-dart/flutter/lib/src/widgets_binding_observer.dart
Lines 41 to 42 in 21562c5
Steps to Reproduce
Reproduction code: https://github.com/p-mazhnik/sentry-dart/tree/multiview-issue/flutter/example (based on
flutter/example
package from this repo)Expected Result
No error, app is launched successfully
Actual Result
App is not loaded, error in console
Are you willing to submit a PR?
None
The text was updated successfully, but these errors were encountered: