问题描述一:
HTTP Host availability check is taking a long time…[!] HTTP Host Availability
HTTP host “https://maven.google.com/” is not reachable.
Reason: An error occurred while checking the HTTP host: 信号灯超时时间已到
解决方案:
1、找到flutter sdk的文件目录,依次找到flutter/packages/flutter_tools/lib/src/http_host_validator.dart文件
2、将https://maven.google.com/ 修改为https://dl.google.com/dl/android/maven2/
3、关闭所有打开了flutterSDK的程序,找到flutter\bin目录下的flutter_tools.snapshot文件,永久删除。
4、Win+R运行cmd命令窗口执行 flutter doctor 问题解决。
问题描述二:
HTTP host "https://pub.dev/" is not reachable.
解决方案:
配置国内的pub插件镜像地址,参数如下
PUB_HOSTED_URL
https://pub.flutter-io.cn
FLUTTER_STORAGE_BASE_URL
https://storage.flutter-io.cn
笔者配置的是Flutter社区的镜像,更多镜像参考
Flutter中文网
问题描述三:
HTTP host "https://cloud.google.com/" is not reachable.
解决方案:
暂时未解决!!!
版权声明:本文为qq_41602125原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。