MCPcopy Create free account
hub / github.com/cli/cli / shouldRetry

Function shouldRetry

pkg/cmd/release/shared/upload.go:134–141  ·  view source on GitHub ↗
(err error)

Source from the content-addressed store, hash-verified

132}
133
134func shouldRetry(err error) bool {
135 var networkError errNetwork
136 if errors.As(err, &networkError) {
137 return true
138 }
139 var httpError api.HTTPError
140 return errors.As(err, &httpError) && httpError.StatusCode >= 500
141}
142
143// Allow injecting backoff interval in tests.
144var retryInterval = time.Millisecond * 200

Callers 1

uploadWithDeleteFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected