twine icon indicating copy to clipboard operation
twine copied to clipboard

upload: add connection exceptions to upload retry protocol

Open ashwoods opened this issue 1 year ago • 1 comments

Addresses our intermittent upload issues as described that #1017 was initially trying to address.

Although we are mainly running into "connection reset by peer" exceptions, I've added connection timeouts, and I'd consider adding a sleep between retries.

ashwoods avatar Nov 28 '23 20:11 ashwoods

Sorry, meant to draft this from the start, PR was meant as a rough proposal and there a few things that are still unclear:

  • ~~the original code returns None on error codes (type return mismatch).~~
  • we have been getting Connection errors, but retrying timeouts "might" be a good idea. (yes/no)?
  • should we add a sleep to the retries?

will add a test and a few improvements asap.

ashwoods avatar Nov 29 '23 09:11 ashwoods

This doesn't merge cleanly, doesn't solve the problem at the right layer, and it re-invents a wheel for which there are many good solutions. I'm closing this.

sigmavirus24 avatar May 15 '24 21:05 sigmavirus24