Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch from x/net/context to context #2140

Merged
merged 2 commits into from
Apr 24, 2018
Merged

Conversation

kolyshkin
Copy link
Contributor

Since Go 1.7, "context" is a standard package, superceding the "x/net/context". Since Go 1.9, the latter only provides type aliases from the former. Therefore, it makes sense to switch to the standard package, and the change is not disruptive in any sense.

Similar PRs: moby/moby#36904, containerd/containerd#2305

This version includes "x/net/context" which is fully compatible with
the standard Go "context" package, so the two can be mixed together.

Signed-off-by: Kir Kolyshkin <[email protected]>
Since Go 1.7, context is a standard package. Since about Go 1.9 time,
all x/net/context provides is a few aliases to types in context, meaning
"x/net/context" and "context" can be mixed freely.

Some vendored packages still use x/net/context, so vendor entry remains
for now.

Signed-off-by: Kir Kolyshkin <[email protected]>
Copy link

@fcrisciani fcrisciani left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@codecov-io
Copy link

Codecov Report

❗ No coverage uploaded for pull request base (master@51812c9). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #2140   +/-   ##
=========================================
  Coverage          ?   40.42%           
=========================================
  Files             ?      139           
  Lines             ?    22488           
  Branches          ?        0           
=========================================
  Hits              ?     9091           
  Misses            ?    12058           
  Partials          ?     1339

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 51812c9...c4d30f8. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants