flutter_cached_network_image icon indicating copy to clipboard operation
flutter_cached_network_image copied to clipboard

No implementation found for method getDatabasesPath

Open Isra0210 opened this issue 2 years ago β€’ 3 comments

πŸ› Bug Report

I am trying to use this code

CachedNetworkImage( imageUrl: "http://via.placeholder.com/200x150", imageBuilder: (context, imageProvider) => Container( decoration: BoxDecoration( image: DecorationImage( image: imageProvider, fit: BoxFit.cover, colorFilter: ColorFilter.mode(Colors.red, BlendMode.colorBurn)), ), ), placeholder: (context, url) => CircularProgressIndicator(), errorWidget: (context, url, error) => Icon(Icons.error), ),

but I am getting this error erro

E/flutter ( 8610): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: MissingPluginException(No implementation found for method getDatabasesPath on channel com.tekartik.sqflite) E/flutter ( 8610): #0 MethodChannel._invokeMethod platform_channel.dart:308 E/flutter ( 8610): E/flutter ( 8610): #1 invokeMethod sqflite_impl.dart:16 E/flutter ( 8610): E/flutter ( 8610): #2 wrapDatabaseException exception_impl.dart:7 E/flutter ( 8610): E/flutter ( 8610): #3 SqfliteDatabaseFactoryMixin.getDatabasesPath factory_mixin.dart:177 E/flutter ( 8610):

Expected behavior

Reproduction steps

Configuration

Doctor summary (to see all details, run flutter doctor -v): [βœ“] Flutter (Channel stable, 3.10.6, on Microsoft Windows [versΓ†o 10.0.22621.1992], locale en-US) [βœ“] Windows Version (Installed version of Windows is version 10 or higher) [βœ“] Android toolchain - develop for Android devices (Android SDK version 33.0.2) [βœ“] Chrome - develop for the web [βœ“] Visual Studio - develop for Windows (Visual Studio Build Tools 2019 16.11.27) [βœ“] Android Studio (version 2022.2) [βœ“] VS Code (version 1.81.0) [βœ“] Connected device (4 available) [βœ“] Network resources

β€’ No issues found!

Version: Flutter 3.10.6 β€’ channel stable β€’ https://github.com/flutter/flutter.git Framework β€’ revision f468f3366c (4 weeks ago) β€’ 2023-07-12 15:19:05 -0700 Engine β€’ revision cdbeda788a Tools β€’ Dart 3.0.6 β€’ DevTools 2.23.1

Platform:

  • [ ] :iphone: iOS
  • [x] :robot: Android

Isra0210 avatar Aug 08 '23 21:08 Isra0210

You're trying to run it on an Android device or as a Windows app?

renefloor avatar Sep 25 '23 15:09 renefloor

You're trying to run it on an Android device or as a Windows app?

Android device

Isra0210 avatar Oct 02 '23 13:10 Isra0210

It's been a while, so you've probably already discovered how to fix it, but just in case, I will say what worked for me. My similar code didn't work right away when I installed flutter_cached_network_image while already debugging. All I needed to do was stop debugging and build the app again. I guess that otherwise the dependency may not have the necessary permissions to handle cache properly.

thetabrus avatar Feb 03 '24 20:02 thetabrus