Flutter – Error: Unable to ‘pub upgrade’ flutter tool. Retrying in five seconds

flutternumpy

Log:

E:\Flutter>flutter doctor Checking Dart SDK version… Downloading
Dart SDK from Flutter engine ead227f a… Unzipping Dart SDK…
Updating flutter tool… Error: Unable to 'pub upgrade' flutter tool.
Retrying in five seconds…

Waiting for 0 seconds, press CTRL+C to quit … Error: Unable to 'pub
upgrade' flutter tool. Retrying in five seconds…

Waiting for 0 seconds, press CTRL+C to quit … Error: Unable to 'pub
upgrade' flutter tool. Retrying in five seconds…

Waiting for 0 seconds, press CTRL+C to quit … Error: Unable to 'pub
upgrade' flutter tool. Retrying in five seconds…

Waiting for 0 seconds, press CTRL+C to quit … Error: Unable to 'pub
upgrade' flutter tool. Retrying in five seconds…

Waiting for 0 seconds, press CTRL+C to quit … Error: Unable to 'pub
upgrade' flutter tool. Retrying in five seconds…

Android studio log

Best Solution

First Make sure you have a working internet connection and if this issue still exists then, this error may be because the dart sdk may have not been properly downloaded. The simplest solution is to delete the cache folder located in flutter/bin(location where flutter is installed) and then Run flutter doctor

Related Question