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
Issue occurs on: web
Plugin name: connectivity_plus
Plugin version: 1.0.1
Flutter doctor output:
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel dev, 2.2.0-11.0.pre.2, on Microsoft Windows [Version 10.0.19042.985], locale en-AU)
[√] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[√] Chrome - develop for the web
[√] Android Studio (version 3.6)
[√] VS Code (version 1.56.2)
[√] Connected device (3 available)
Steps to Reproduce
Have a web enabled flutter app.
Have an existing transitive dependency to the connectivity package (for example using graphql_flutter: ^5.0.0-nullsafety.5) which itself depends on connectivity_for_web.
Add connectivity_plus as a direct dependency to the app.
Let the automatically generated file generated_plugin_registrant.dart be generated and open it.
An error is generated in because registerPlugins in generated_plugin_registrant.dart tries to register both ConnectivityPlugin from two different packages, one from connectivity_for_web and one from connectivity_plus_web.
Ideally, the naming collision should be avoided by connectivity_plus as we cannot expect all packages depending on connectivity to migrate to connectivity_plus.
The name 'ConnectivityPlugin' is defined in the libraries 'package:connectivity_for_web/connectivity_for_web.dart' and 'package:connectivity_plus_web/connectivity_plus_web.dart'.
Try using 'as prefix' for one of the import directives, or hiding the name from all but one of the imports.
The text was updated successfully, but these errors were encountered:
System info
Issue occurs on: web
Plugin name: connectivity_plus
Plugin version: 1.0.1
Flutter doctor output:
Steps to Reproduce
connectivity
package (for example using graphql_flutter: ^5.0.0-nullsafety.5) which itself depends onconnectivity_for_web
.connectivity_plus
as a direct dependency to the app.generated_plugin_registrant.dart
be generated and open it.An error is generated in because
registerPlugins
ingenerated_plugin_registrant.dart
tries to register bothConnectivityPlugin
from two different packages, one fromconnectivity_for_web
and one fromconnectivity_plus_web
.Ideally, the naming collision should be avoided by
connectivity_plus
as we cannot expect all packages depending onconnectivity
to migrate toconnectivity_plus
.pubspec.yaml:
main.dart (default app):
generated_plugin_registrant.dart:
Analysis Error
The text was updated successfully, but these errors were encountered: