Reputation: 2641
any flutter command I tried running it's showing
Checking Dart SDK version...
Downloading Dart SDK from Flutter engine af51afceb8886cc11e25047523c4e0c7e1f5d408...
Downloading the Dart SDK using the BITS service failed, retrying with WebRequest...
Invoke-WebRequest : The underlying connection was closed: An unexpected error occurred on a send.
At C:\src\flutter\flutter\bin\internal\update_dart_sdk.ps1:68 char:5
+ Invoke-WebRequest -Uri $dartSdkUrl -OutFile $dartSdkZip
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebExc
eption
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand
Error: Unable to update Dart SDK. Retrying...
Waiting for 1 seconds, press CTRL+C to quit ...
Terminate batch job (Y/N)?
I have been learning flutter for 3 months now and it worked fine. Any Suggestion how to fix this problem
Upvotes: 3
Views: 1843
Reputation: 569
Start your VPN and reset console maybe can not access to URI from your country IP, My problem was solved with this solution
Upvotes: 0
Reputation: 775
I hade the same problem. I download the flutter SDK. if you don't see the "flutter_windows_v1.12.13+hotfix.9-stable.zip" button then you need to use free VPN extension. After enabling VPN then you might see this "flutter_windows_v1.12.13+hotfix.9-stable.zip" button. download and extract the flutter SDK. setup env variable.
that's how I solved the problem, hope this will work for you.
Upvotes: 1
Reputation: 721
Looks to be a known issue. Could you check the link? https://github.com/flutter/flutter/issues/27276
Upvotes: 1