skip to Main Content

firebase core initialize error I started getting this error after updating flutter

''' Launching lib/main.dart on sdk gphone64 arm64 in debug mode... : Error: The method 'initializeCore' isn't defined for the class 'FirebaseCoreHostApi'. - 'FirebaseCoreHostApi' is from 'package:firebase_core_platform_interface/src/pigeon/messages.pigeon.dart' ('../../.pub-cache/hosted/pub.dev/firebase_core_platform_interface-4.5.3/lib/src/pigeon/messages.pigeon.dart'). Try correcting the name to the name of an existing method, or defining…

VIEW QUESTION

flutter pub get failed in macos

Running "flutter pub get" in General... Resolving dependencies... (13.9s) Connection closed before full header was received pub get failed command: "/Users/zhangyicheng/Developer/flutter/bin/cache/dart-sdk/bin/dart __deprecated_pub --color --directory . get --example" pub env: { "FLUTTER_ROOT": "/Users/zhangyicheng/Developer/flutter", "PUB_ENVIRONMENT": "flutter_cli:get", "PUB_CACHE": "/Users/zhangyicheng/.pub-cache", } exit code: 69

VIEW QUESTION

How to retrieve data from Firestore in flutter

I have made a collection in this way: var res = FirebaseFirestore.instance.collection("hotels"); var response =await res.doc(res.id).collection(data.email).doc(data.hotelName).collection(data.hotelName).doc().collection('hotel_details').add( 'hotel_name': data.hotelName, 'hotel_email': data.email,}); This is the code to retrive I have used: final res = FirebaseFirestore.instance.collection("hotels"); final response = await res.doc(res.id).collection(email).get(); I am…

VIEW QUESTION

call hive in graphql – Flutter

I would like to retrieve sessionToken and authToken from Hive, then put it inside GraphQLClient main.dart GetIt sl = GetIt.instance; void main() async { // Register Service locator await initAuthServiceLocator(sl); .... await sl.allReady(); runApp(...); } initAuthServiceLocator Future<void> initAuthServiceLocator( GetIt sl,…

VIEW QUESTION

Flutter Shared Preferences cannot use async/await, so I must use a then

void _authKey() { Hmac hmacSha = new Hmac(sha256, utf8.encode("604ec80ffa552786f409590994dc89cfef040b72")); String hashValue = ""; List<String> sortedKeys = _datas.keys.toList()..sort(); sortedKeys.forEach((f) => hashValue += _datas[f]! + "+"); print("waw"); SharedPreferences.getInstance().then((prefs) => () { print("wow"); String? token = prefs.getString('apitoken'); print("the auth key is " +…

VIEW QUESTION
Back To Top
Search