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

cmd/go: internal package errors should report the line number #18011

Closed
rakyll opened this issue Nov 22, 2016 · 2 comments
Closed

cmd/go: internal package errors should report the line number #18011

rakyll opened this issue Nov 22, 2016 · 2 comments
Milestone

Comments

@rakyll
Copy link
Contributor

rakyll commented Nov 22, 2016

The error message when trying to import an internal package is not helping to find out which import line is causing the error. Adding the error line to the message would be useful.

$ go test ./...
# github.com/GoogleCloudPlatform/golang-samples/bigquery/snippets
package github.com/GoogleCloudPlatform/golang-samples/bigquery/snippets (test)
	imports cloud.google.com/go/internal/testutil: use of internal package not allowed
FAIL	github.com/GoogleCloudPlatform/golang-samples/bigquery/snippets [setup failed]
@rakyll rakyll added this to the Go1.9 milestone Nov 22, 2016
@JayNakrani
Copy link
Contributor

After golang.org/cl/33631:

$ ../bin/go test cmd/go/testdata/testinternal/p.go 
cmd/go/testdata/testinternal/p.go:3:8: use of internal package not allowed

@gopherbot
Copy link

CL https://golang.org/cl/33631 mentions this issue.

@golang golang locked and limited conversation to collaborators Nov 29, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants