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

gps: skip hidden directories when looking for packages #1251

Closed
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
3 participants
@vincentbernat

vincentbernat commented Oct 10, 2017

Stuff in hidden directories should stay hidden. In my case, I am using a special GOPATH and I don't want dep to look into it.

@vincentbernat vincentbernat requested a review from sdboyer as a code owner Oct 10, 2017

@googlebot googlebot added the cla: yes label Oct 10, 2017

@sdboyer

This comment has been minimized.

Show comment
Hide comment
@sdboyer

sdboyer Oct 10, 2017

Member

sorry, this can't be how this works. it is valid, even if inadvisable, to import packages under dot dirs, and ListPackages has to model all possibly-valid importable locations when creating its virtual representation of the filesystem.

Member

sdboyer commented Oct 10, 2017

sorry, this can't be how this works. it is valid, even if inadvisable, to import packages under dot dirs, and ListPackages has to model all possibly-valid importable locations when creating its virtual representation of the filesystem.

@sdboyer sdboyer closed this Oct 10, 2017

@vincentbernat

This comment has been minimized.

Show comment
Hide comment
@vincentbernat

vincentbernat Oct 10, 2017

go list also skips hidden directories. Moreover, by the same logic, VCS directories and Godeps shouldn't be skipped. Please, reconsider.

vincentbernat commented Oct 10, 2017

go list also skips hidden directories. Moreover, by the same logic, VCS directories and Godeps shouldn't be skipped. Please, reconsider.

@sdboyer

This comment has been minimized.

Show comment
Hide comment
@sdboyer

sdboyer Oct 10, 2017

Member
Member

sdboyer commented Oct 10, 2017

@vincentbernat

This comment has been minimized.

Show comment
Hide comment
@vincentbernat

vincentbernat Oct 10, 2017

In fact, the additional analysis doesn't bother me much but starting from 242e387 and 19c7f60, pkgtree will recurse into dep itself and choke on invalid tests and I get this kind of error:

ensure ListPackage for project: import path hellogopher/.gopath~/src/github.com/golang/dep/internal/gps/_testdata/src/canon_confl had conflicting import comments: "vanity1", "vanity2"

vincentbernat commented Oct 10, 2017

In fact, the additional analysis doesn't bother me much but starting from 242e387 and 19c7f60, pkgtree will recurse into dep itself and choke on invalid tests and I get this kind of error:

ensure ListPackage for project: import path hellogopher/.gopath~/src/github.com/golang/dep/internal/gps/_testdata/src/canon_confl had conflicting import comments: "vanity1", "vanity2"
@vincentbernat

This comment has been minimized.

Show comment
Hide comment
@vincentbernat

vincentbernat Oct 10, 2017

For context, I am doing stuff like that to get a local GOPATH: https://github.com/vincentbernat/hellogopher/blob/master/Makefile#L26.

This is not something totally alien as some popular developers advertise this way of doing things (well, at least one): https://github.com/cloudflare/hellogopher/blob/master/Makefile.

vincentbernat commented Oct 10, 2017

For context, I am doing stuff like that to get a local GOPATH: https://github.com/vincentbernat/hellogopher/blob/master/Makefile#L26.

This is not something totally alien as some popular developers advertise this way of doing things (well, at least one): https://github.com/cloudflare/hellogopher/blob/master/Makefile.

@sdboyer

This comment has been minimized.

Show comment
Hide comment
@sdboyer

sdboyer Oct 11, 2017

Member

uuuugghh.

yeah, we keep ping-ponging around on these individual package-level errors, as well as what we should be looking at at all (within the root project). this whole model needs improving.

#1253 will be where this can live on, as @darkowlzz is gonna take on making the necessary deeper improvements.

Member

sdboyer commented Oct 11, 2017

uuuugghh.

yeah, we keep ping-ponging around on these individual package-level errors, as well as what we should be looking at at all (within the root project). this whole model needs improving.

#1253 will be where this can live on, as @darkowlzz is gonna take on making the necessary deeper improvements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment