简体   繁体   English

未找到在通道插件上写入方法的实现。it_nomads.com/flutter_secure_storage

[英]No implementation found for method write on channel plugins.it_nomads.com/flutter_secure_storage

I was trying to store the login credentials of a user upon login, but I'm getting this error again and again.我试图在登录时存储用户的登录凭据,但我一次又一次地收到此错误。 Things I've tried:我尝试过的事情:

  1. Restarting app重启应用
  2. Uninstalling and reinstalling app卸载并重新安装应用程序
  3. updating the flutter_secure_storage to the latest version更新 flutter_secure_storage 到最新版本

Here's the flutter doctor summary这是flutter医生总结

    • Flutter version 1.17.5 at /home/piyush/flutter
    • Framework revision 8af6b2f038 (12 days ago), 2020-06-30 12:53:55 -0700
    • Engine revision ee76268252
    • Dart version 2.8.4

 
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
    • Android SDK at /home/piyush/Android/Sdk
    • Platform android-29, build-tools 29.0.3
    • Java binary at: /home/piyush/Downloads/android-studio/jre/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
    • All Android licenses accepted.

[✓] Android Studio (version 4.0)
    • Android Studio at /home/piyush/Downloads/android-studio
    • Flutter plugin version 47.1.2
    • Dart plugin version 193.7361
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)

[✓] VS Code (version 1.46.1)
    • VS Code at /usr/share/code
    • Flutter extension version 3.12.2

[✓] Connected device (1 available)
    • RMX1851 • 580c132b • android-arm64 • Android 10 (API 29)```

"MissingPluginException" or "Implementation not found" errors thrown by plugins usually occurs when the plugin wasn't properly "installed" in the Flutter project.插件抛出的“MissingPluginException”或“Implementation not found”错误通常发生在插件未正确“安装”到 Flutter 项目中时。

These solutions may not be able to inject plugin dependencies into the platform-specific parts of the app.这些解决方案可能无法将插件依赖项注入应用程序的特定平台部分。 What you can do here is run flutter clean and flutter pub gets to rebuild the dependencies used in the project.您在这里可以做的是运行 flutter clean 和 flutter pub gets 来重建项目中使用的依赖项。

Also check that if that package supports your platform or not.if platform is not supported than find another package with your platform support.还要检查 package 是否支持您的平台。如果不支持该平台,请查找另一个支持您的平台的 package。

I have stopped the debug the app and restarted the full application, It works for me我已停止调试应用程序并重新启动整个应用程序,它对我有用

When you add a new plugin, you need to re-build the application, the hot re-start doesn't build the application and your newly added is not included in your project unless built again.添加新插件时,需要重新构建应用程序,热重启不会构建应用程序,除非重新构建,否则新添加的插件不会包含在项目中。 for that you should run为此你应该跑

flutter clean flutter 清洁

flutter pub get flutter 酒吧得到

flutter run flutter 跑

if still not solved add read this如果仍未解决,请阅读内容

Generally this problem occurs when 2 or more plugins are incompatible with each other or with the current sdk version To fix this change you kt code to this通常,当 2 个或更多插件彼此不兼容或与当前 sdk 版本不兼容时,会出现此问题。要解决此问题,请将代码更改为此

package com.pharmdel_business package com.pharmdel_business

import io.flutter.embedding.android.FlutterFragmentActivity导入 io.flutter.embedding.android.FlutterFragmentActivity

class MainActivity: FlutterFragmentActivity() { } class MainActivity: FlutterFragmentActivity() { }

******but if any of you other plugin that only support FlutterActivity will stop working If you face that issue then go to that plugin file and replace FlutterActivity with FlutterFragmentActivity ******但是如果你们中任何其他只支持 FlutterActivity 的插件将停止工作如果你遇到这个问题然后 go 到那个插件文件并将 FlutterActivity 替换为 FlutterFragmentActivity

enter image description here在此处输入图像描述

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Flutter 插件不起作用(在通道 flutter.plugins.io/Y 上找不到方法 X 的实现) - Flutter plugins not working (No implementation found for method X on channel flutter.plugins.io/Y) Flutter:在通道插件上找不到方法 getApplicationDocumentsDirectory 的实现。flutter.io/path_provider - Flutter: No implementation found for method getApplicationDocumentsDirectory on channel plugins.flutter.io/path_provider 未处理的异常:MissingPluginException(在通道插件上找不到方法 X 的实现。flutter.io/Y) - Unhandled Exception: MissingPluginException(No implementation found for method X on channel plugins.flutter.io/Y) MissingPluginException(在通道 plugins.flutter.io/path_provider 上找不到方法 getApplicationDocumentsDirectory 的实现) - MissingPluginException(No implementation found for method getApplicationDocumentsDirectory on channel plugins.flutter.io/path_provider) MissingPluginException(MissingPluginException(在通道 plugins.flutter.io/firebase_core 上找不到方法 Firebase#initializeCore 的实现) - MissingPluginException (MissingPluginException(No implementation found for method Firebase#initializeCore on channel plugins.flutter.io/firebase_core) 缺少插件异常(在通道插件上找不到方法 firebase#initializecore 的实现。flutter.io/firebase_core) - missingpluginexception(no implementation found for method firebase#initializecore on channel plugins.flutter.io/firebase_core) MissingPluginException(未在通道插件上找到方法 init 的实现。flutter.io/google_sign_in) - MissingPluginException(No implementation found for method init on channel plugins.flutter.io/google_sign_in) MissingPluginException(在 Android 上找不到方法 Firebase#initializeCore 在通道插件上的实现。flutter.io/firebase_core) - MissingPluginException(No implementation found for method Firebase#initializeCore on channel plugins.flutter.io/firebase_core) on Android Flutter MissingPluginException(在通道 flutter.baseflow.com/permissions/methods 上找不到方法 init 的实现) - Flutter MissingPluginException(No implementation found for method init on channel flutter.baseflow.com/permissions/methods) Flutter Unhandled Exception: MissingPluginException(No implementation found for method pickImage on channel plugins.flutter.io/image_picker) 错误 - Flutter Unhandled Exception: MissingPluginException(No implementation found for method pickImage on channel plugins.flutter.io/image_picker) Error
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM