I'm not overly familiar with the corner cases for vendoring, but I
think that this problem below is a different problem than the recent
"A tricky (impossible?) situation with common packages and vendoring"
golang-nuts thread.

The github.com/golang/snappy package defines a canonical import path.
Its package clause looks like:

package snappy // import "github.com/golang/snappy"

This is similar to what the golang.org/x/... packages do, such as:

package webp // import "golang.org/x/image/webp"

There's a PR filed (https://github.com/golang/snappy/pull/28) to
remove that meaningful comment for package snappy, because when
vendoring, "go test ./..." does not work in that directory:

  $ go test ./... can't load package: package
mycode/vendor/github.com/golang/snappy: code in directory
mycode/vendor/github.com/golang/snappy expects import

Is this a bug in the go tool, or is this working as intended, and
there is simply some combination of vendoring, canonical import paths,
and go tool relative paths that combine badly?

You received this message because you are subscribed to the Google Groups "golang-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-dev+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Discussion Posts

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 1 of 3 | next ›
Discussion Overview
groupgolang-dev @
postedApr 3, '16 at 12:00p
activeApr 4, '16 at 1:32a



site design / logo © 2021 Grokbase