flutter遇到的问题归纳

版本升级篇:

问题一:

Failed to retrieve the Dart SDK from: https://storage.Flutter-io.cnexport/Flutter_infra/Flutter/2f0af3715217a0c2ada72c717d4ed9178d68f6ed/dart-sdk-darwin-x64.zip
If you're located in China, please see this page:
  https://Flutter.dev/community/china


解决办法:

先执行命令

export PUB_HOSTED_URL=https://pub.Flutter-io.cn

export FlutteR_STORAGE_BASE_URL=https://storage.Flutter-io.cn

完成后,再执行命令

Flutter doctor

问题二:

运行时出现:

Exception: Gradle task assembleDebug Failed with exit code 1

解决办法:

在android工程的build.gradle,如下图

加入 

maven { url 'http://download.Flutter.io' }

如下图

相关文章

这篇文章主要讲解了“FlutterComponent动画的显和隐怎么实现...
这篇文章主要讲解了“flutter微信聊天输入框功能如何实现”,...
本篇内容介绍了“Flutter之Navigator的高级用法有哪些”的有...
这篇文章主要介绍“Flutter怎么使用Android原生播放器”,在...
Flutter开发的android端如何修改APP名称,logo,版本号,具体...
Flutter路由管理初识路由概念一.路由管理1.1.Route1.2.Mater...