Reputation: 35
final List image = await imageLabeler.processImage(inputImage); // <---Error Exception
I am using an android.
I have seen a person with the same exact issue, but they were running on the web, and it is not implemented to run on the web. I am using an android, so there should be no problems.
Is there a way to fix this issue?
import 'package:google_ml_kit/google_ml_kit.dart';
import 'package:google_mlkit_image_labeling/google_mlkit_image_labeling.dart';
import 'package:google_mlkit_commons/google_mlkit_commons.dart';
final List image = await imageLabeler.processImage(inputImage);
the example shown above was taken from a youtube video, word for word, so there should be zero problems.
https://www.youtube.com/watch?v=giVk7yGUkas&t=244s&ab_channel=LearnwithJahangirJadi
EDIT i tried closing editor/ doing a flutter clean/ and closing my app, I encountered another proble
Exception has occurred.
FirebaseException ([cloud_firestore/unavailable] The service is currently unavailable. This is a most likely a transient condition and may be corrected by retrying with a backoff.)
adding these to the pubspec.yaml files causes this error
google_ml_kit:
google_mlkit_image_labeling:
google_mlkit_commons:
removing them fixes the error.
what am I doing wrong?
Upvotes: 0
Views: 193
Reputation: 15
Sometimes this happens to me, try to run these steps:
flutter clean
flutter pub get
close your code editor, your app/emulator, and try again.
Upvotes: 1