-
Notifications
You must be signed in to change notification settings - Fork 409
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 Google Place Search not working after upgrading to Flutter Version 2 #162
Comments
This same issue was occurring for me as well after upgrading the package to v0.3.0, its dependencies, and Flutter to the current stable channel. Judging by the first error, it looks like the null safety on types, components, and strictbounds is causing this. Here's a fix I included in my PlacesAutocomplete.show() function:
Take a look at the Google Maps docs for this function as well |
@adam-weissert thank you for your hotfix, I already fix this and some other properties having similar issues, I will release another version this weekend so I have a little more time to fix other issues |
The new version will depend on rxdart ^ 0.27.0? I updated to the latest versions of the FlutterFire and GeoFlutterFire packages so they don't conflict. But I get this error:
|
@Adrek you can do a temporary workaround for the problem you are having like below
in your pubspec.yaml file |
This issue will be tracked in #164, expect an update soon. |
[ERROR:flutter/lib/ui/ui_dart_state.cc(186)] Unhandled Exception: Null check operator used on a null value
E/flutter ( 900): #0 PlacesAutocompleteState.doSearch (package:flutter_google_places/src/flutter_google_places.dart:436)
E/flutter ( 900): #1 _rootRunUnary (dart:async/zone.dart:1362)
E/flutter ( 900): #2 _CustomZone.runUnary (dart:async/zone.dart:1265)
E/flutter ( 900): #3 _CustomZone.runUnaryGuarded (dart:async/zone.dart:1170)
E/flutter ( 900): #4 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:341)
E/flutter ( 900): #5 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:271)
E/flutter ( 900): #6 _SyncBroadcastStreamController._sendData (dart:async/broadcast_stream_controller.dart:378)
E/flutter ( 900): #7 _BroadcastStreamController.add (dart:async/broadcast_stream_controller.dart:244)
E/flutter ( 900): #8 _StartWithStreamSink.add (package:rxdart/src/transformers/start_with.dart:15)
E/flutter ( 900): #9 forwardStream... (package:rxdart/src/utils/forwarding_stream.dart:31)
E/flutter ( 900): #10 forwardStream.runCatching (package:rxdart/src/utils/forwarding_stream.dart:21)
E/flutter ( 900): #11 forwardStream.. (package:rxdart/src/utils/forwarding_stream.dart:31)
E/flutter ( 900): #12 _rootRunUnary (dart:async/zone.dart:1362)
E/flutter ( 900): #13 _CustomZone.runUnary (dart:async/zone.dart:1265)
E/flutter ( 900): #14 _CustomZone.runUnaryGuarded (dart:async/zone.dart:1170)
E/flutter ( 900): #15 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:341)
E/flutter ( 900): #16 _DelayedData.perform (dart:async/stream_impl.dart:591)
E/flutter ( 900): #17 _StreamImplEvents.handleNext (dart:async/stream_impl.dart:706)
E/flutter ( 900): #18 _PendingEvents.schedule. (dart:async/stream_impl.dart:663)
E/flutter ( 900): #19 _rootRun (dart:async/zone.dart:1346)
E/flutter ( 900): #20 _CustomZone.run (dart:async/zone.dart:1258)
E/flutter ( 900): #21 _CustomZone.runGuarded (dart:async/zone.dart:1162)
E/flutter ( 900): #22 _CustomZone.bindCallbackGuarded. (dart:async/zone.dart:1202)
E/flutter ( 900): #23 _rootRun (dart:async/zone.dart:1354)
E/flutter ( 900): #24 _CustomZone.run (dart:async/zone.dart:1258)
E/flutter ( 900): #25 _CustomZone.runGuarded (dart:async/zone.dart:1162)
E/flutter ( 900): #26 _CustomZone.bindCallbackGuarded. (dart:async/zone.dart:1202)
E/flutter ( 900): #27 _microtaskLoop (dart:async/schedule_microtask.dart:40)
E/flutter ( 900): #28 _startMicrotaskLoop (dart:async/schedule_microtask.dart:49)
The text was updated successfully, but these errors were encountered: