Skip to content

Conversation

@Sainan
Copy link

@Sainan Sainan commented Aug 31, 2025

Possibly the number one 'issue' I hear from users who are following our guides is that "DepotDownloader just throws a bunch of errors."

I've went ahead and refined the messages here based on the values I've observed (status codes always being an enumeration string, and exception messages always ending in a period).

Copy link
Member

@yaakov-h yaakov-h left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM but could be a little more refined (see suggestions)

}

Console.WriteLine("Encountered error downloading depot manifest {0} {1}: {2}", depot.DepotId, depot.ManifestId, e.StatusCode);
Console.WriteLine("Encountered {2} for depot manifest {0} {1}. Retrying.", depot.DepotId, depot.ManifestId, e.StatusCode);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Console.WriteLine("Encountered {2} for depot manifest {0} {1}. Retrying.", depot.DepotId, depot.ManifestId, e.StatusCode);
Console.WriteLine("Encountered HTTP {2:D} for depot manifest {0} {1}. Retrying.", depot.DepotId, depot.ManifestId, e.StatusCode);

{
cdnPool.ReturnBrokenConnection(connection);
Console.WriteLine("Encountered error downloading manifest for depot {0} {1}: {2}", depot.DepotId, depot.ManifestId, e.Message);
Console.WriteLine("Error downloading manifest for depot {0} {1}: {2} Retrying.", depot.DepotId, depot.ManifestId, e.Message);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Console.WriteLine("Error downloading manifest for depot {0} {1}: {2} Retrying.", depot.DepotId, depot.ManifestId, e.Message);
Console.WriteLine("Error downloading manifest for depot {0} {1}: {2} Retrying...", depot.DepotId, depot.ManifestId, e.Message);

}

Console.WriteLine("Encountered error downloading chunk {0}: {1}", chunkID, e.StatusCode);
Console.WriteLine("Encountered {1} for chunk {0}. Retrying.", chunkID, e.StatusCode);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Console.WriteLine("Encountered {1} for chunk {0}. Retrying.", chunkID, e.StatusCode);
Console.WriteLine("Encountered HTTP {1:D} for chunk {0}. Retrying...", chunkID, e.StatusCode);

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is definitely not gonna be work out, because StatusCode is a value like ServiceUnavailable or NotFound from what I've observed.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you want the integer value (:D e.g. 503), or the enum name (:G eg ServiceUnavailable)?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think Encountered ServiceUnavailable makes more sense and keeps it roughly identical to what it was. Encountered HTTP 503 doesn't mean a whole lot to anyone who hasn't studied the HTTP RFCs.

{
cdnPool.ReturnBrokenConnection(connection);
Console.WriteLine("Encountered unexpected error downloading chunk {0}: {1}", chunkID, e.Message);
Console.WriteLine("Error downloading chunk {0}: {1} Retrying.", chunkID, e.Message);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Console.WriteLine("Error downloading chunk {0}: {1} Retrying.", chunkID, e.Message);
Console.WriteLine("Error downloading chunk {0}: {1} Retrying...", chunkID, e.Message);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants