ClientTrace is a set of hooks to run at various stages of an outgoing HTTP request. Any particular hook may be nil. Functions may be called concurrently from different goroutines and some may be called after the request has completed or failed.
To Reproduce
Steps to reproduce the behavior:
When context is canceled nanoseconds after rate limiter allows next request
Describe the bug
Some edge cases when request context is canceled while request with
httptrace.WithClientTrace
is busy can cause data race,https://github.com/cardano-community/koios-go-client/blob/2c4a0061bb604cab2e401129861df57d1e4a0b85/client.go#L195
https://pkg.go.dev/net/http/httptrace#ContextClientTrace
To Reproduce Steps to reproduce the behavior: