-
Notifications
You must be signed in to change notification settings - Fork 18k
x/vgo: support module path without dot #24100
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
Comments
Asking in the ML the answer is quitte evident.
I let open this issue to maybe put it in the FAQ. |
I disagree with the assertions does in that ML thread. vgo should support pure local development just like the go tool does. And mylib could also well be an internal server, even if it doesn't contain a dot. This is a bug. |
Using dotless import paths for your own projects is just as bad of an idea as using the |
I'm agree but dotless import path is in many places in the official documentation for a starting project... Also mentioned as a practice at Google ! Without GOPATH it can be more tempting also. |
@flibustenet Those links very much encourage the (Side note, Google internal usage is probably irrelevant, as as far as we on the outside know they don't use the go build system anyway.) |
The go build system already assumes in some places the dotless prefixes mark the standard library, so @tv42 is right that using it places you on thin ice. At the same time, I don't think this specific failure is too hard to fix, so we can look into fixing it. |
If it's too hard to fix, though, we'll just mark it working as intended. |
Change https://golang.org/cl/107661 mentions this issue: |
What version of Go are you using (
go version
)?go version go1.10 linux/amd64 vgo:2018-02-20.1
What did you do?
Trying to work with local packages with my own apps and libs.
Because they are locals i didn't put a package path with dot
My app is under
./app
my lib is under./mylib
The package of
mylib
is justmylib
vgo doesn't find
../mylib
Now if i change
mylib
bylibs.me\mylib
it worksWhat did you expect to see?
I expect it could work with a simple package path without dot
However it's not a problem for me if a dot is mandatory when it's best practice, I just want to be sure I didn't missed something.
The text was updated successfully, but these errors were encountered: