【问题标题】:Problem with url_launcher package (Flutter)url_launcher 包的问题(Flutter)
【发布时间】:2020-02-17 20:32:09
【问题描述】:

我正在开发一个 Flutter 项目。我从柜台应用开始。如果使用以下软件包,我没有任何问题:

cupertino_icons: ^0.1.3
flutter_markdown: ^0.3.3
google_fonts: ^0.3.9
google_maps_flutter: ^0.5.23+1
intl: ^0.16.1
provider: ^4.0.4
rive: ^0.0.1
rxdart: ^0.23.1
shared_preferences: ^0.5.6+1

但是如果我使用url_launcher: ^5.4.1 包,我会收到这个错误:

Launching lib\main.dart on Android SDK built for x86 in debug mode...

FAILURE: Build failed with an exception.

* What went wrong:
Could not determine the dependencies of task ':url_launcher:compileDebugAidl'.
> Could not resolve all task dependencies for configuration ':url_launcher:debugCompileClasspath'.
   > Could not resolve androidx.annotation:annotation:1.1.0.
     Required by:
         project :url_launcher
      [...]

我该如何解决?谢谢!

【问题讨论】:

  • 只有在完全重建应用程序后才会出现该错误。
  • 你可以降级到5.3.0。效果很好
  • 添加输出:颤振通道
  • 也尝试flutter clean,然后再次构建您的项目。
  • @hoangquyy 我对版本5.2.7有同样的问题。

标签: gradle flutter


【解决方案1】:

使用包的版本5.4.2,问题似乎得到了解决。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2022-10-17
    • 2022-09-29
    • 1970-01-01
    • 1970-01-01
    • 2021-03-24
    • 2021-06-29
    • 2021-09-07
    • 1970-01-01
    相关资源
    最近更新 更多