We have some packages we would like to break out into their own repos,
but which we don't really want anyone outside of our project to depend
on.

We could, of course, just document that.  But I had this thought that
maybe Go's "internal" semantics could be applied here.  So as a test,
we redirected go-get of `k8s.io/internal` to a different github org
(e.g. go get k8s.io/internal/foo -> github.com/k8s-internal/foo).

This SEEMS to work until vendoring comes in, and we get errors like:

```
package k8s.io/kubernetes/cmd/genkubedocs
imports k8s.io/kubernetes/cmd/kubelet/app
imports k8s.io/kubernetes/pkg/kubelet
imports k8s.io/kubernetes/pkg/kubelet/images
pkg/kubelet/images/image_manager.go:26:2: use of internal package
k8s.io/kubernetes/vendor/k8s.io/internal/distribution/reference not
allowed
```

The code in `k8s.io/kubernetes/pkg/kubelet/images` imports
`k8s.io/internal/distribution/reference` but vendoring renames it
internally and now it fails the "internal" rules.

Is this perceived as a bug or just a case of "too clever for our own good" ?

Tim

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/CAO_RewbsnD4sH5Mqc41du0DYSsSBsnVmGi7nmW0MJpvA06_M5Q%40mail.gmail.com.

Reply via email to