To clear your system cache with an older SDK, you can manually delete the PUB_CACHE folder .
Read moreHow do I clear my pub-cache?
Delete ~/. pub-cache/hosted and/or ~/. pub-cache/git (for Git dependencies) . This requires running flutter packages to get in all active projects on your machine afterward.
Read more