我最近将flutter升级到1.20.4,当我尝试在android studio中创建一个新项目时出现此错误
下载失败。网址:https://storage.googleapis.com/flutter_infra/flutter/d1bc06f032f9d6c148ea6b96b48261d6f545004f/flutter_patched_sdk.zip错误:禁止使用403
和android studio不知道我的android设备
当我运行flutter doctor -v
时,我开始下载flutter_patched_sdk tools
但无法下载
C:\Users\raZor>flutter doctor -v
Downloading flutter_patched_sdk tools...
Download failed.
URL:
https://storage.googleapis.com/flutter_infra/flutter/d1bc06f032f9d6c148ea6b96b48261d6f545004f/flutter_patched_sdk.zip
Error: 403 Forbidden
#0 throwToolExit (package:flutter_tools/src/base/common.dart:14:3)
#1 Net._attempt (package:flutter_tools/src/base/net.dart:148:9)
<asynchronous suspension>
#2 Net.fetchUrl (package:flutter_tools/src/base/net.dart:63:33)
#3 Cache.downloadFile (package:flutter_tools/src/cache.dart:492:16)
#4 CachedArtifact._downloadArchive.<anonymous closure>(package:flutter_tools/src/cache.dart:640:23)
#5 CachedArtifact._downloadArchive.<anonymous closure> (package:flutter_tools/src/cache.dart:636:55)
#6 CachedArtifact._withDownloadFile (package:flutter_tools/src/cache.dart:670:26)
#7 CachedArtifact._downloadArchive (package:flutter_tools/src/cache.dart:636:12)
#8 CachedArtifact._downloadZipArchive (package:flutter_tools/src/cache.dart:657:12)
#9 EngineCachedArtifact.updateInner (package:flutter_tools/src/cache.dart:795:13)
#10 _rootRunUnary (dart:async/zone.dart:1198:47)
#11 _CustomZone.runUnary (dart:async/zone.dart:1100:19)
#12 _FutureListener.handleValue (dart:async/future_impl.dart:143:18)
#13 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)
#14 Future._propagateToListeners (dart:async/future_impl.dart:725:32)
#15 Future._completeWithValue (dart:async/future_impl.dart:529:5)
#16 _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:40:15)
#17 _completeOnAsyncReturn (dart:async-patch/async_patch.dart:311:13)
#18 CachedArtifact._withDownloadFile (package:flutter_tools/src/cache.dart)
#19 _rootRunUnary (dart:async/zone.dart:1198:47)
#20 _CustomZone.runUnary (dart:async/zone.dart:1100:19)
#21 _FutureListener.handleValue (dart:async/future_impl.dart:143:18)
#22 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)
#23 Future._propagateToListeners (dart:async/future_impl.dart:725:32)
#24 Future._completeWithValue (dart:async/future_impl.dart:529:5)
#25 Future._asyncCompleteWithValue.<anonymous closure> (dart:async/future_impl.dart:567:7)
#26 _rootRun (dart:async/zone.dart:1190:13)
#27 _CustomZone.run (dart:async/zone.dart:1093:19)
#28 _CustomZone.runGuarded (dart:async/zone.dart:997:7)
#29 _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:1037:23)
#30 _microtaskLoop (dart:async/schedule_microtask.dart:41:21)
#31 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50:5)
#32 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:118:13)
#33 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:169:5)
有人看到吗?
答案 0 :(得分:0)
根据我作为受到多项制裁的伊朗人的经验,此问题似乎与您的连接问题有关。对于像伊朗这样受到美国制裁的国家,Google 限制或阻止了对其许多服务的访问。
尝试使用代理服务器并再次测试。
另一个问题可能与您的 ISP 阻止访问谷歌服务器有关。