GithubHelp home page GithubHelp logo

FlutterGooglePlacesSdk::call error: UnimplementedError: initialize() has not been implemented. about flutter_google_places_sdk HOT 4 CLOSED

matanshukry avatar matanshukry commented on August 14, 2024
FlutterGooglePlacesSdk::call error: UnimplementedError: initialize() has not been implemented.

from flutter_google_places_sdk.

Comments (4)

huesmiles49 avatar huesmiles49 commented on August 14, 2024 1

System: Mac - Ventura 13.0.1
Flutter Version: 3.13.0
Platform: Flutter web

I'm unable to reproduce the issue. It seem to happen randomly. This is the first time I'd experience the issue directly. Another time was when the same problem happen to my coworker. So far, we've only seen this issue on Flutter web.

The only way I know to fix this problem is:

  • run this command dart pub cache clean
  • then run the app
  • then either check or uncheck the Uncaught Exception in VSCode debugger
  • then hard reset the app
    This seems to reset the initialize function when setting the Google Place API key.

To conclude, I applied the fix mentioned and the package is working again.

from flutter_google_places_sdk.

matanshukry avatar matanshukry commented on August 14, 2024 1

@huesmiles49 it sounds like flutter dependencies/caching issues.

But either way glad to hear it's working again!

from flutter_google_places_sdk.

huesmiles49 avatar huesmiles49 commented on August 14, 2024

My other attempt to initialize the package doesn't work either. Code:

final places = FlutterGooglePlacesSdk.platform;
    places.initialize(FlavorConfig().googlePlacesApiKey);
    FindAutocompletePredictionsResponse res =
        await places.findAutocompletePredictions(_searchText);
    setState(() {
      _predictions = res.predictions;
    });
Screenshot 2023-09-26 at 4 31 39 PM

from flutter_google_places_sdk.

matanshukry avatar matanshukry commented on August 14, 2024

@huesmiles49 Looks like something is wrong with the dependencies. Take a look at the example in this project and use it.

If you still have issue, please create a small reproducible example that we can work.

from flutter_google_places_sdk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.