-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
*: change standard "context" package to "golang.org/x/net/context" #2890
Conversation
distsql/distsql.go
Outdated
"io" | ||
"io/ioutil" | ||
"time" | ||
|
||
goctx "golang.org/x/net/context" | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this empty line.
distsql/distsql_test.go
Outdated
"errors" | ||
"io" | ||
"io/ioutil" | ||
"runtime" | ||
"testing" | ||
"time" | ||
|
||
goctx "golang.org/x/net/context" | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this empty line.
store/tikv/coprocessor_slow_test.go
Outdated
@@ -16,11 +16,11 @@ | |||
package tikv | |||
|
|||
import ( | |||
"context" | |||
mocktikv "github.com/pingcap/tidb/store/tikv/mock-tikv" | |||
goctx "golang.org/x/net/context" | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the empty line.
store/tikv/rawkv_test.go
Outdated
@@ -14,7 +14,7 @@ | |||
package tikv | |||
|
|||
import ( | |||
"context" | |||
goctx "golang.org/x/net/context" | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the empty line.
store/tikv/region_cache.go
Outdated
"sync" | ||
|
||
goctx "golang.org/x/net/context" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the empty line.
store/tikv/store_test.go
Outdated
"sync" | ||
"time" | ||
|
||
goctx "golang.org/x/net/context" | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the empty line.
I think we must convert all standard context to golang context now. It is very strange that we use two similar context packages in one project and this it a risk to combine using them together. |
LGTM |
LGTM We can add go 1.6 in travis CI to avoid using wrong context. |
store/tikv should not use both "context" and "golang.org/x/net/context"