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

Function shouldRetry

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

Source from the content-addressed store, hash-verified

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

Callers 1

uploadWithDeleteFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected