Flutter依赖(引入)蒲公英SDK导致报错

大概会报这几个错

Finished with error: Gradle task assembleDebug failed with exit code 1
G:\FlutterSDK\fluttersdk\.pub-cache\hosted\pub.flutter-io.cn\flutter_pgyer-1.0.1\android\src\main\java\com\crazecoder\flutter.pgyer\FlutterPgyerPlugin.java:214: ����: �Ҳ�������
                        public void downloadSuccessful(File file) {
                                                       ^
  ����: �� File
1 ������

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':flutter_pgyer:compileDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 11s
Finished with error: Gradle task assembleDebug failed with exit code 1

如果在flutter 项目中引入蒲公英SDK报错

那么  大概 用pub的方式引入也就是这样

pub

flutter_pgyer: ^1.0.1

如果用上面这种方法引入蒲公英SDK,那么你的问题就可以在这里得到解决,如果不是,你就可以退出了

解决方法:使用GitHub的方式引入

  flutter_pgyer:
    git:
      url: https://github.com/crazecoder/flutter_pgyer.git

 运行成功,然后就可以写你的更新的逻辑代码了,这里就暂时没有这个代码,因为我也是第一次用,还没写到,等我写好了再更新

猜你喜欢

转载自www.cnblogs.com/inthecloud/p/12304053.html