From 4c0a050ee24beb399b11c48829522e48f8d0b98a Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Fri, 13 Jul 2018 09:53:36 +0200 Subject: [PATCH 1/2] Remove stray uses of "golang.org/x/net/context" Signed-off-by: Sebastiaan van Stijn --- client/build_cancel.go | 3 +-- client/hijack_test.go | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/client/build_cancel.go b/client/build_cancel.go index 4cf8c980a9..74df495089 100644 --- a/client/build_cancel.go +++ b/client/build_cancel.go @@ -1,9 +1,8 @@ package client // import "github.com/docker/docker/client" import ( + "context" "net/url" - - "golang.org/x/net/context" ) // BuildCancel requests the daemon to cancel ongoing build request diff --git a/client/hijack_test.go b/client/hijack_test.go index 823bf344f5..d71dc9ea38 100644 --- a/client/hijack_test.go +++ b/client/hijack_test.go @@ -1,6 +1,7 @@ package client import ( + "context" "fmt" "io/ioutil" "net" @@ -12,7 +13,6 @@ import ( "github.com/docker/docker/api/server/httputils" "github.com/docker/docker/api/types" "github.com/pkg/errors" - "golang.org/x/net/context" "gotest.tools/assert" ) From a8b4e04e2f6ae95a5146c4c4d794cda1a725c634 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Fri, 13 Jul 2018 09:54:24 +0200 Subject: [PATCH 2/2] Fix API template to not use "golang.org/x/net/context" Signed-off-by: Sebastiaan van Stijn --- api/templates/server/operation.gotmpl | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/api/templates/server/operation.gotmpl b/api/templates/server/operation.gotmpl index 8bed59d920..cf24aacc5f 100644 --- a/api/templates/server/operation.gotmpl +++ b/api/templates/server/operation.gotmpl @@ -8,10 +8,8 @@ package {{ .Package }} // ---------------------------------------------------------------------------- import ( + "context" "net/http" - - context "golang.org/x/net/context" - {{ range .DefaultImports }}{{ printf "%q" . }} {{ end }} {{ range $key, $value := .Imports }}{{ $key }} {{ printf "%q" $value }}