Your flutter checkout has local changes that would be erased by upgrading. If you want to keep these changes, it is recommended that you stash them via "git stash" or else
commit the changes to a local branch. If it is okay to remove local changes, then re-run this command with --force.
在使用第三方庫的時候,說是flutter sdk版本不夠,於是我輸入 flutter upgrade指令,以上就是報錯信息
解決方法:加上--force,強制升級
flutter upgrade --force