Hi all,
I've recently learned about oauth2 and started to convert some of my "manual" code using net/http to use an underlying oauth2.Transport for executing authenticated requests and token refresh.
As a result, my application now sometimes shows
// For compatibility, the Client will also use the deprecated
// CancelRequest method on Transport if found. New
// RoundTripper implementations should use the Request's Context
// for cancellation instead of implementing CancelRequest.
Timeout time.Duration
I would read this as: if you have an http.Client with an underlying oauth2.Transport and the request times out, the oauth2.Transport's CancelRequest method will *always* be called and hence show the undesired warning.
Is that correct?
Thanks,
Andreas