Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cargo treats lack of disk space as "spurious network error" #14964

Open
glandium opened this issue Dec 19, 2024 · 1 comment
Open

Cargo treats lack of disk space as "spurious network error" #14964

glandium opened this issue Dec 19, 2024 · 1 comment
Labels
A-diagnostics Area: Error and warning messages generated by Cargo itself. A-git Area: anything dealing with git A-networking Area: networking issues, curl, etc. C-bug Category: bug S-needs-design Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted.

Comments

@glandium
Copy link
Contributor

glandium commented Dec 19, 2024

Problem

While updating .cargo/git/checkouts, if disk space runs out, cargo handles the situation as if there was a network error, and display:

warning: spurious network error (3 tries remaining): cannot extend packfile '...': Not enough disk space; class=Os (2)

Steps

No response

Possible Solution(s)

No response

Notes

Errors that are not related to the network shouldn't be treated as network errors.

Version

1.83.0
@glandium glandium added C-bug Category: bug S-triage Status: This issue is waiting on initial triage. labels Dec 19, 2024
@epage epage added A-git Area: anything dealing with git A-networking Area: networking issues, curl, etc. labels Dec 19, 2024
@weihanglo
Copy link
Member

Cargo already checked specific error types here. The error message could be rephrased to a general one, like "spurious error". The downside of this is we may lose connections to old issues / stackoverlow questsions.People searching for the new message may not find old issues.

Or, we can have more specific error messages for each case, and leave the old message for real networking issues.

In addition, the current retry mechanism doesn't say what it is retrying. Perhaps the API should require caller to provide a status message so Cargo then displays it like "retrying download X"

@weihanglo weihanglo added A-diagnostics Area: Error and warning messages generated by Cargo itself. S-needs-design Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted. and removed S-triage Status: This issue is waiting on initial triage. labels Dec 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-diagnostics Area: Error and warning messages generated by Cargo itself. A-git Area: anything dealing with git A-networking Area: networking issues, curl, etc. C-bug Category: bug S-needs-design Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted.
Projects
None yet
Development

No branches or pull requests

3 participants