Skip to content
This repository has been archived by the owner on Sep 9, 2020. It is now read-only.

Handle conflicting constraint errors when solving during init #730

Closed
carolynvs opened this issue Jun 6, 2017 · 3 comments
Closed

Handle conflicting constraint errors when solving during init #730

carolynvs opened this issue Jun 6, 2017 · 3 comments

Comments

@carolynvs
Copy link
Collaborator

Sometimes dep init may fail because of conflicting constraints found during solve. This will get better once we don't use the GOPATH to set initial constraints but may continue to be an issue.

The init command should recognize when solve failed due to conflicting constraints and do something smart. 😉 For example, if -gopath was specified, automatically retry with it turned off, or at least print an error message with suggestions on what to try next.

@sdboyer
Copy link
Member

sdboyer commented Jul 26, 2017

this feels perhaps related to other issues we've opened, or at least what came up in discussion yesterday re: k8s, about not just failing out with no files generated when dep init fails - no?

@carolynvs
Copy link
Collaborator Author

Yes it's related but not exactly the same as the one I opened for still writing out the config when init fails (#909).

I haven't done much with this because while I'd like to do something smart, nothing has jumped out as easy to detect, and concrete enough that init could either automatically do something on your behalf (like rerunning without -gopath), or making an intelligent suggestion.

@sdboyer
Copy link
Member

sdboyer commented Aug 1, 2017

i'd say the minimum thing we can do here is generate the Gopkg.toml anyway, but print a message to the user indicating which projects seem to have a conflict and advise them that they may want to rm Gopkg.toml and start again with dep init from scratch.

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