use standard context package instead of x/net/context #174
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Following up on our conversation in #149
This PR modifies the source files to use the standard
context
package instead ofx/net/context
. This means that this repository will not be compatible with Go 1.6 and earlier anymore. The README does not mention the minimum Go version currently supported so I'm not sure if this is going to be a deal-breaker or not.If we need support for Go 1.6 we can probably figure out a way to support either packages with a compile-time check, but it could introduce lots of complexity in the code.
I was concerned that
x/net/http2
may have usedx/net/context
directly but it seems they have moved to the standardcontext
package already, there's only one leftover in a test:There are two places where
x/net/context
is still referenced after this change:I tried re-generating those files but they kept importing
x/net/context
, I'm not super familiar with the build process here so I could take a pointer or two on how to fix this.