Now that rust-lang/cargo#2396 is merged Cargo will soon start attempting to retry what appears to be spurious network requests when they fail. This should get released with the next nightly soon!
One part about this PR is that we don’t want to just blindly retry random failures but rather only those that look like network failures. Along those lines only some errors actually trigger a retry, but the logic may be subtly wrong! If you see Cargo retry for an error that’s impossible to fix or not retry on an error it should fix, please file an issue against Cargo! Hopefully we have enough contextual information to add in these cases over time.
And as always, feel free to file any other bugs you have against Cargo you find