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

Adding UX output to dep init #1176

Merged
merged 1 commit into from
Oct 26, 2017
Merged

Adding UX output to dep init #1176

merged 1 commit into from
Oct 26, 2017

Conversation

xmattstrongx
Copy link
Contributor

What does this do / why do we need it?

Provides some output during dep init to help soften the user experience where people think the tool is hanging.

What should your reviewer look out for in this PR?

For now this WIP PR is just to start the discussion of how to bring back functionality similar to what was added before in.
https://github.com/golang/dep/pull/194/files#diff-b14a2eb16f1efbc6aa9f1ffdad724265R241

Do you need help or clarification on anything?

Yes. For now I just have something very rudimentary that displays when a new direct dep found. To regain functionality from #194 there also needs to be output when transitive deps are discovered. I believed this should be done in s.Solve(). Still digging in.

Which issue(s) does this PR fix?

fixes #1144

DEMO

dep init
HEAD is now at 6a17370 Removing godeps for testing without godep init
Cached github.com/emicklei/go-restful
Cached github.com/go-kit/kit
Cached github.com/stretchr/testify
Cached gopkg.in/mgutz/dat.v1

@carolynvs
Copy link
Collaborator

carolynvs commented Sep 27, 2017

Sorry this took so long to look at!

Remember when we chatted and were like "it seems like a 1 line fix but maybe we are missing something?" 😀 I've realized that these log messages aren't in the right spot. For a small codebase, it looks right but after running on a bigger one (e.g. run dep init --skip-tools on the kubernetes repo), or one with slow remote repository you'll see that the "is dep hanging moment" is happening later.

The log message alone won't be enough, here's a bit of context on why and what's really happening:

  • getDirectDependencies used to call sm.SyncSourceFor. This would clone and update all the direct dependencies, so adding log messages here used to make sense. Without the call to sync, however our messages about having cached a repo aren't true (since the caching happens later).
  • getDirectDependencies no longer knows the right source to pass in to sm.SyncSourceFor so we cant' just add that call back. The reason why is that there may be existing configuration from glide/govendor/etc that overrides the source for a dependency.
  • When init kicks off an import, the direct dependencies end up being cached as a side-effect:
    m, l, err := i.Import(dir, pr)
  • If there isn't anything to import, then everything is cloned during solve:
    soln, err := s.Solve()

Since the goal is to give feedback, maybe we can ignore the import pathway because dep is already printing information about each dependency as it is imported. There isn't a long period of time where the importer does work but doesn't print anything.

The problem area is when we aren't importing anything, then when we call solve during init, it first syncs everything and we get a long period of no output.

I suggest that you look into doing an explicit prefetch when we aren't doing an import (that would be when rootM is nil in the function below), making sure to follow Sam's original suggestions on concurrency which are in the original issue (and his comment linked from that issue).

func (a *rootAnalyzer) InitializeRootManifestAndLock(dir string, pr gps.ProjectRoot) (rootM *dep.Manifest, rootL *dep.Lock, err error) {
if !a.skipTools {
rootM, rootL, err = a.importManifestAndLock(dir, pr, false)
if err != nil {
return
}
}
if rootM == nil {
rootM = dep.NewManifest()
}
if rootL == nil {
rootL = &dep.Lock{}
}
return

If this is more than you have time to work on, I realize that I was really late in catching this... Just let me know and I can throw this issue back up for grabs.

@carolynvs carolynvs removed the request for review from sdboyer September 27, 2017 21:41
@xmattstrongx
Copy link
Contributor Author

@carolynvs I should have some time to look in to this deeper this weekend.

@xmattstrongx
Copy link
Contributor Author

@carolynvs I have the basic functionality working. I just need to wrap with concurrency and use golang.org/x/sync/errgroup as Sam mentioned.

logger := a.ctx.Err

syncDep := func(pr gps.ProjectRoot, sm gps.SourceManager) {
message := fmt.Sprintf("Cached %s", pr)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of using fmt directly here and elsewhere in this file, use a.ctx.Err. This let's us capture/discard output more easily in our tests.

return strings.HasPrefix(s, prefix+"/")
}

func isStdLib(path string) bool {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This function is already defined in github.com/golang/dep/internal/gps/paths as IsStandardImportPath.

logger.Printf(message)
}

for _, v := range pkgT.Packages {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that you can usea.directDeps instead of pkgT, which is the set of repositories represented in by the import paths in pkgT. Then we don't need to pass in pkgT or deal with parsing project roots, or skipping duplicates.

@xmattstrongx
Copy link
Contributor Author

@carolynvs So Ive added the suggested changes as well as the concurrency with max 4 go routines firing the cache calls. For small projects it works well, and fast. However with the kubernetes project I am seeing a bug that I am still working to identify. It seems to fail and hang when trying to get https://bitbucket.org/bertimus9/systemstat. Ive waited for 30+ minutes and it still continues to hang. Output below showing the issue I am describing. Still looking in to it...

Cached github.com/containernetworking/cni
Cached github.com/golang/mock
Cached github.com/docker/distribution
The authenticity of host 'bitbucket.org (2401:1d80:1010::151)' can't be established.
RSA key fingerprint is SHA256:zzXQOXSRBEiUtuE8AikJYKwbHaxvSc0ojez9YXaGp1A.
Are you sure you want to continue connecting (yes/no)? Cached bitbucket.org/ww/goautoneg
Cached github.com/influxdata/influxdb
Cached github.com/coreos/etcd
Cached github.com/docker/docker
Cached k8s.io/kubernetes


Signal received: waiting for 1 ops to complete...
Unable to cache bitbucket.org/bertimus9/systemstat - no valid source could be created:
	failed to set up sources from the following URLs:
https://bitbucket.org/bertimus9/systemstat
: remote repository at https://bitbucket.org/bertimus9/systemstat does not exist, or is inaccessible
	failed to set up sources from the following URLs:
ssh://hg@bitbucket.org/bertimus9/systemstat
: remote repository at ssh://hg@bitbucket.org/bertimus9/systemstat does not exist, or is inaccessible
	failed to set up sources from the following URLs:
http://bitbucket.org/bertimus9/systemstat
: context canceled
	failed to set up sources from the following URLs:
https://bitbucket.org/bertimus9/systemstat
: context canceled
	failed to set up sources from the following URLs:
ssh://git@bitbucket.org/bertimus9/systemstat
: context canceled
	failed to set up sources from the following URLs:
git://bitbucket.org/bertimus9/systemstat
: context canceled
	failed to set up sources from the following URLs:
http://bitbucket.org/bertimus9/systemstat
: context canceled
Cached bitbucket.org/bertimus9/systemstat
this SourceMgr has been released, its methods can no longer be called

@xmattstrongx
Copy link
Contributor Author

Update on the error reported above. While it is hanging if I push enter or type 'yes' then the kubernetes dep https://bitbucket.org/bertimus9/systemstat will download as expected. Is this a known bug with deps that require authenticity and require user input to continue?

Also notice at the end there is also another issue. This seems unrelated to my changes.
No versions of golang.org/x/exp met constraints:

Cached k8s.io/apiextensions-apiserver
Cached github.com/spf13/cobra
The authenticity of host 'bitbucket.org (2401:1d80:1010::151)' can't be established.
RSA key fingerprint is SHA256:zzXQOXSRBEiUtuE8AikJYKwbHaxvSc0ojez9YXaGp1A.
Are you sure you want to continue connecting (yes/no)? Cached github.com/appc/spec
Cached k8s.io/heapster
Cached github.com/vmware/photon-controller-go-sdk
Cached github.com/influxdata/influxdb
Cached github.com/aws/aws-sdk-go
Cached github.com/docker/libnetwork
Cached github.com/coreos/etcd
Cached bitbucket.org/ww/goautoneg
Cached github.com/docker/docker
yCached k8s.io/kubernetes

Please type 'yes' or 'no': yes
Cached bitbucket.org/bertimus9/systemstat
No versions of golang.org/x/exp met constraints:
	master: Could not introduce golang.org/x/exp@master, as its subpackage golang.org/x/exp/inotify does not contain usable Go code (*build.NoGoError).. (Package is required by (root).)

@carolynvs
Copy link
Collaborator

Yes, it is expected that the ca cert is trusted for each repo. I added bitbucket.org to my trusted certs so that I don't see that prompt anymore.

As for k8's actually working with dep, it doesn't, sorry I should have mentioned that... 😞 It is just a good test for a project with lots of dependencies.

I'll take a look in a bit, but if those are the only two issues you ran into, sounds like we are in a good spot! 👍

@xmattstrongx
Copy link
Contributor Author

Awesome! The only thing I havent looked in to yet was Sams mention of golang.org/x/sync/errgroup on the issue. Any clarification on that to get me up to speed would be appreciated.

@carolynvs
Copy link
Collaborator

The reason to use an errgroup is that when an error/timeout occurs, everything is cancelled:

WithContext returns a new Group and an associated Context derived from ctx.
The derived Context is canceled the first time a function passed to Go returns a non-nil error or the first time Wait returns, whichever occurs first.

https://godoc.org/golang.org/x/sync/errgroup#WithContext

Here's an example of how to use errorgroup in the dep codebase:

g, ctx := errgroup.WithContext(context.TODO())

And here's a post that walks through how it all works:

https://www.oreilly.com/learning/run-strikingly-fast-parallel-file-searches-in-go-with-sync-errgroup

@xmattstrongx
Copy link
Contributor Author

@carolynvs Awesome! Thank you for sharing that. Glad to have learned something new and useful 😄

New output from kuberenetes

Package "bitbucket.org/bertimus9/systemstat", analyzing...
Package "github.com/Azure/go-autorest", analyzing...
Package "github.com/elazarl/goproxy", analyzing...
Package "github.com/evanphx/json-patch", analyzing...
Package "github.com/opencontainers/selinux", analyzing...
Package "github.com/prometheus/common", analyzing...
Package "golang.org/x/sys", analyzing...
Package "gopkg.in/gcfg.v1", analyzing...
Package "github.com/docker/libnetwork", analyzing...
Package "github.com/fatih/camelcase", analyzing...
Package "github.com/go-openapi/loads", analyzing...
Package "github.com/gogo/protobuf", analyzing...
Package "github.com/mvdan/xurls", analyzing...
Package "github.com/fsnotify/fsnotify", analyzing...
Package "github.com/golang/protobuf", analyzing...
Package "github.com/miekg/coredns", analyzing...
Package "github.com/storageos/go-api", analyzing...
Package "github.com/Microsoft/hcsshim", analyzing...
Package "github.com/emicklei/go-restful-swagger12", analyzing...
Package "github.com/json-iterator/go", analyzing...
Package "github.com/spf13/afero", analyzing...
Package "github.com/libopenstorage/openstorage", analyzing...
Package "github.com/rancher/go-rancher", analyzing...
Package "github.com/codedellemc/goscaleio", analyzing...
Package "github.com/coreos/go-oidc", analyzing...
Package "github.com/daviddengcn/go-colortext", analyzing...
Package "github.com/ghodss/yaml", analyzing...
Package "github.com/kardianos/osext", analyzing...
Package "github.com/peterbourgon/diskv", analyzing...
Package "github.com/google/cadvisor", analyzing...
Package "github.com/kr/pty", analyzing...
Package "golang.org/x/crypto", analyzing...
Package "github.com/xanzy/go-cloudstack", analyzing...
Package "cloud.google.com/go", analyzing...
Package "github.com/aws/aws-sdk-go", analyzing...
Package "github.com/chai2010/gettext-go", analyzing...
Package "github.com/codegangsta/negroni", analyzing...
Package "github.com/gophercloud/gophercloud", analyzing...
Package "github.com/onsi/gomega", analyzing...
Package "github.com/russross/blackfriday", analyzing...
Package "gopkg.in/yaml.v2", analyzing...
Package "github.com/armon/circbuf", analyzing...
Package "github.com/emicklei/go-restful", analyzing...
Package "github.com/opencontainers/runc", analyzing...
Package "github.com/vmware/photon-controller-go-sdk", analyzing...
Package "k8s.io/code-generator", analyzing...
Package "github.com/coreos/etcd", analyzing...
Package "github.com/go-openapi/validate", analyzing...
Package "github.com/spf13/viper", analyzing...
Package "k8s.io/apimachinery", analyzing...
Package "k8s.io/gengo", analyzing...
Package "github.com/dgrijalva/jwt-go", analyzing...
Package "github.com/influxdata/influxdb", analyzing...
Package "github.com/vishvananda/netlink", analyzing...
Package "k8s.io/kube-aggregator", analyzing...
Package "github.com/davecgh/go-spew", analyzing...
Package "github.com/spf13/pflag", analyzing...
Package "k8s.io/client-go", analyzing...
Package "bitbucket.org/ww/goautoneg", analyzing...
Package "github.com/Azure/azure-sdk-for-go", analyzing...
Package "github.com/clusterhq/flocker-go", analyzing...
Package "github.com/mitchellh/go-wordwrap", analyzing...
Package "gopkg.in/natefinch/lumberjack.v2", analyzing...
Package "vbom.ml/util", analyzing...
Package "github.com/docker/distribution", analyzing...
Package "github.com/elazarl/go-bindata-assetfs", analyzing...
Package "github.com/prometheus/client_golang", analyzing...
Package "github.com/rubiojr/go-vhd", analyzing...
Package "github.com/xyproto/simpleredis", analyzing...
Package "golang.org/x/oauth2", analyzing...
Package "github.com/PuerkitoBio/purell", analyzing...
Package "github.com/gregjones/httpcache", analyzing...
Package "github.com/renstrom/dedent", analyzing...
Package "github.com/robfig/cron", analyzing...
Package "github.com/vmware/govmomi", analyzing...
Package "k8s.io/apiserver", analyzing...
Package "golang.org/x/exp", analyzing...
Package "github.com/d2g/dhcp4", analyzing...
Package "github.com/golang/glog", analyzing...
Package "github.com/google/gofuzz", analyzing...
Package "github.com/howeyc/gopass", analyzing...
Package "github.com/lxn/win", analyzing...
Package "github.com/onsi/ginkgo", analyzing...
Package "github.com/spf13/cobra", analyzing...
Package "github.com/cloudflare/cfssl", analyzing...
Package "github.com/coreos/rkt", analyzing...
Package "github.com/pborman/uuid", analyzing...
Package "github.com/containernetworking/cni", analyzing...
Package "github.com/docker/docker", analyzing...
Package "github.com/heketi/heketi", analyzing...
Package "github.com/miekg/dns", analyzing...
Package "github.com/appc/spec", analyzing...
Package "github.com/docker/go-units", analyzing...
Package "github.com/jonboulle/clockwork", analyzing...
Package "github.com/juju/ratelimit", analyzing...
Package "k8s.io/kube-openapi", analyzing...
Package "github.com/hashicorp/golang-lru", analyzing...
Package "github.com/blang/semver", analyzing...
Package "github.com/golang/mock", analyzing...
Package "github.com/imdario/mergo", analyzing...
Package "github.com/stretchr/testify", analyzing...
Package "golang.org/x/tools", analyzing...
Package "github.com/opencontainers/go-digest", analyzing...
Package "github.com/pkg/errors", analyzing...
Package "github.com/prometheus/client_model", analyzing...
Package "github.com/coreos/go-semver", analyzing...
Package "github.com/coreos/go-systemd", analyzing...
Package "github.com/go-openapi/strfmt", analyzing...
Package "github.com/mitchellh/mapstructure", analyzing...
Package "github.com/quobyte/api", analyzing...
Package "github.com/MakeNowJust/heredoc", analyzing...
Package "github.com/mxk/go-flowrate", analyzing...
Package "github.com/square/go-jose", analyzing...
Package "k8s.io/metrics", analyzing...
Package "github.com/cpuguy83/go-md2man", analyzing...
Package "github.com/go-openapi/spec", analyzing...
Package "github.com/coreos/pkg", analyzing...
Package "github.com/docker/go-connections", analyzing...
Package "github.com/gorilla/mux", analyzing...
Package "k8s.io/api", analyzing...
Package "k8s.io/sample-apiserver", analyzing...
Package "github.com/exponent-io/jsonpath", analyzing...
Package "github.com/golang/groupcache", analyzing...
Package "google.golang.org/grpc", analyzing...
Package "k8s.io/heapster", analyzing...
Package "github.com/godbus/dbus", analyzing...
Package "github.com/googleapis/gnostic", analyzing...
Package "k8s.io/apiextensions-apiserver", analyzing...
Package "k8s.io/kubernetes", analyzing...
Package "github.com/d2g/dhcp4client", analyzing...
Package "github.com/hawkular/hawkular-client-go", analyzing...
Package "golang.org/x/net", analyzing...
Package "gopkg.in/inf.v0", analyzing...
Package "github.com/docker/spdystream", analyzing...
Package "golang.org/x/text", analyzing...
Package "google.golang.org/api", analyzing...
Package "k8s.io/utils", analyzing...
Cached golang.org/x/sys
Cached github.com/Azure/go-autorest
Cached github.com/opencontainers/selinux
Cached gopkg.in/gcfg.v1
Cached github.com/mvdan/xurls
Cached github.com/elazarl/goproxy
Cached github.com/fatih/camelcase
Cached bitbucket.org/bertimus9/systemstat
Cached github.com/miekg/coredns
Cached github.com/go-openapi/loads
Cached github.com/gogo/protobuf
Cached github.com/evanphx/json-patch
Cached github.com/libopenstorage/openstorage
Cached github.com/emicklei/go-restful-swagger12
Cached github.com/Microsoft/hcsshim
Cached github.com/fsnotify/fsnotify
Cached github.com/storageos/go-api
Cached github.com/spf13/afero
Cached github.com/kardianos/osext
Cached github.com/rancher/go-rancher
Cached github.com/codedellemc/goscaleio
Cached github.com/daviddengcn/go-colortext
Cached github.com/coreos/go-oidc
Cached github.com/ghodss/yaml
Cached github.com/chai2010/gettext-go
Cached github.com/peterbourgon/diskv
Cached github.com/golang/protobuf
Cached github.com/xanzy/go-cloudstack
Cached github.com/google/cadvisor
Cached cloud.google.com/go
Cached github.com/aws/aws-sdk-go
Cached github.com/kr/pty
Cached github.com/vmware/photon-controller-go-sdk
Cached github.com/codegangsta/negroni
Cached github.com/russross/blackfriday
Cached github.com/onsi/gomega
Cached github.com/gophercloud/gophercloud
Cached github.com/davecgh/go-spew
Cached k8s.io/code-generator
Cached github.com/prometheus/common
Cached github.com/docker/libnetwork
Cached github.com/emicklei/go-restful
Cached github.com/go-openapi/validate
Cached github.com/spf13/viper
Cached k8s.io/apimachinery
Cached gopkg.in/yaml.v2
Cached github.com/coreos/etcd
Cached golang.org/x/crypto
Cached github.com/elazarl/go-bindata-assetfs
Cached github.com/opencontainers/runc
Cached github.com/spf13/pflag
Cached k8s.io/gengo
Cached github.com/dgrijalva/jwt-go
Cached k8s.io/client-go
Cached github.com/Azure/azure-sdk-for-go
Cached github.com/clusterhq/flocker-go
Cached bitbucket.org/ww/goautoneg
Cached gopkg.in/natefinch/lumberjack.v2
Cached vbom.ml/util
Cached github.com/mitchellh/go-wordwrap
Cached golang.org/x/exp
Cached github.com/docker/distribution
Cached github.com/prometheus/client_golang
Cached github.com/rubiojr/go-vhd
Cached github.com/json-iterator/go
Cached golang.org/x/oauth2
Cached github.com/PuerkitoBio/purell
Cached github.com/gregjones/httpcache
Cached github.com/xyproto/simpleredis
Cached github.com/influxdata/influxdb
Cached github.com/robfig/cron
Cached github.com/renstrom/dedent
Cached github.com/vmware/govmomi
Cached github.com/vishvananda/netlink
Cached k8s.io/apiserver
Cached github.com/jonboulle/clockwork
Cached github.com/heketi/heketi
Cached github.com/miekg/dns
Cached github.com/docker/go-units
Cached github.com/appc/spec
Cached github.com/golang/mock
Cached github.com/docker/docker
Cached github.com/juju/ratelimit
Cached k8s.io/kube-openapi
Cached github.com/hashicorp/golang-lru
Cached github.com/blang/semver
Cached github.com/prometheus/client_model
Cached github.com/imdario/mergo
Cached golang.org/x/tools
Cached github.com/stretchr/testify
Cached github.com/opencontainers/go-digest
Cached github.com/mitchellh/mapstructure
Cached github.com/coreos/go-semver
Cached github.com/armon/circbuf
Cached github.com/coreos/go-systemd
Cached github.com/go-openapi/strfmt
Cached github.com/lxn/win
Cached github.com/d2g/dhcp4
Cached github.com/golang/glog
Cached k8s.io/kube-aggregator
Cached github.com/containernetworking/cni
Cached github.com/google/gofuzz
Cached github.com/howeyc/gopass
Cached github.com/cloudflare/cfssl
Cached github.com/spf13/cobra
Cached github.com/pkg/errors
Cached k8s.io/api
Cached k8s.io/metrics
Cached github.com/cpuguy83/go-md2man
Cached github.com/square/go-jose
Cached github.com/go-openapi/spec
Cached github.com/coreos/pkg
Cached github.com/gorilla/mux
Cached github.com/docker/go-connections
Cached github.com/onsi/ginkgo
Cached github.com/mxk/go-flowrate
Cached k8s.io/utils
Cached gopkg.in/inf.v0
Cached github.com/pborman/uuid
Cached github.com/hawkular/hawkular-client-go
Cached golang.org/x/net
Cached k8s.io/sample-apiserver
Cached github.com/exponent-io/jsonpath
Cached github.com/golang/groupcache
Cached google.golang.org/grpc
Cached github.com/MakeNowJust/heredoc
Cached github.com/godbus/dbus
Cached github.com/d2g/dhcp4client
Cached golang.org/x/text
Cached google.golang.org/api
Cached github.com/googleapis/gnostic
Cached github.com/docker/spdystream
Cached k8s.io/heapster
Cached github.com/quobyte/api
Cached k8s.io/apiextensions-apiserver
Cached github.com/coreos/rkt
Cached k8s.io/kubernetes
Successfully cached all deps.
No versions of golang.org/x/exp met constraints:
	master: Could not introduce golang.org/x/exp@master, as its subpackage golang.org/x/exp/inotify does not contain usable Go code (*build.NoGoError).. (Package is required by (root).)

@xmattstrongx xmattstrongx changed the title WIP Adding UX output to dep init Adding UX output to dep init Oct 9, 2017
"github.com/golang/dep/internal/importers"
)

const concurrency = 4
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's move this definition into cacheDeps. If we end up needing it in more places later, we can extract it out then.

@@ -45,6 +52,9 @@ func (a *rootAnalyzer) InitializeRootManifestAndLock(dir string, pr gps.ProjectR

if rootM == nil {
rootM = dep.NewManifest()
if err := a.cacheDeps(pr); err != nil {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need a comment that explains why we are doing this right here. 😀

// Since we didn't find anything to import, dep's cache is empty.
// We are prefetching dependencies and logging so that the subsequent solve step doesn't spend a long time retrieving dependencies without feedback for the user.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just realized I forgot to push the code with this comment. Will add tonight.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added comment


for ip := range a.directDeps {
logger.Printf("Package %q, analyzing...", ip)
if paths.IsStandardImportPath(ip) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this check

if paths.IsStandardImportPath(ip) {
continue
}
if hasImportPathPrefix(ip, string(pr)) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this check

continue
}

pr, err := a.sm.DeduceProjectRoot(ip)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So removing this guy seems to be breaking the underlying call SyncSourceFor called by the new syncDep func. Im still investigating

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ive been trying to use type conversion to pass a "gps.ProjectRoot" without the call to DeduceProjectRoot.
err := syncDep(gps.ProjectRoot(ip), a.sm)

Doing this causes one of the deps to cache over and over again and then end the entire process. Digging in to this now.

Cached github.com/docker/spdystream
Cached github.com/fsnotify/fsnotify
Cached github.com/fsnotify/fsnotify
Cached github.com/xanzy/go-cloudstack
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Cached github.com/spf13/cobra
Successfully cached all deps.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Odd, that is the right thing to do to cast to a ProjectRoot. I wonder if that's really due to other changes you've made to the code?

I really wish that when I had refactored the importers that I had fixed the type on directDeps and used gps.ProjectRoot instead of string. 😀

return err
}

if _, ok := deps[pr]; ok {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this check

return nil
}

for ip := range a.directDeps {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a.directDeps is a unique set of external project roots. So you don't need to track if they have been evaluated already, check if they are stdlib imports, or deduce the root again.

Check out

func getDirectDependencies(sm gps.SourceManager, p *dep.Project) (pkgtree.PackageTree, map[string]bool, error) {
to see how its calculated.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh I see. Thanks for clarifying. Can definitely remove all of these extra checks then!


deps[pr] = true
}
if err := g.Wait(); err == nil {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see any handling for when err is not nil?

return nil
}

func hasImportPathPrefix(s, prefix string) bool {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this


g.Go(func() error {
select {
case sem <- struct{}{}:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I realize now that the existing usage of using errgroup in dep was not the best/canonical example to have pointed you to.

I would rather not use this extra sem channel to handle bounded parallelism and instead use the pattern from the errgroup documentation:

https://godoc.org/golang.org/x/sync/errgroup#example-Group--Pipeline

In that example, they start a fixed number of goroutines instead of a goroutine per work item (look for numDigesters), and range over a channel of input values (in our case that would be the project roots).

@xmattstrongx
Copy link
Contributor Author

@carolynvs Added in concurrency changes for errGroup.

Demo of latest output when calling dep init on kubernetes.

$ dep init --skip-tools
HEAD is now at cd37a28fa5 Update CHANGELOG.md for v1.5.8.
Package "github.com/cpuguy83/go-md2man", analyzing...
Package "github.com/ghodss/yaml", analyzing...
Package "github.com/influxdata/influxdb", analyzing...
Package "github.com/spf13/viper", analyzing...
Package "google.golang.org/api", analyzing...
Cached github.com/cpuguy83/go-md2man
Package "github.com/golang/protobuf", analyzing...
Cached github.com/ghodss/yaml
Package "github.com/google/gofuzz", analyzing...
Cached github.com/spf13/viper
Package "github.com/imdario/mergo", analyzing...
Cached github.com/influxdata/influxdb
Package "github.com/prometheus/client_golang", analyzing...
Cached google.golang.org/api
Package "golang.org/x/sys", analyzing...
Cached github.com/google/gofuzz
Package "github.com/godbus/dbus", analyzing...
Cached github.com/golang/protobuf
Package "github.com/gregjones/httpcache", analyzing...
Cached github.com/imdario/mergo
Package "github.com/Azure/go-autorest", analyzing...
Cached golang.org/x/sys
Package "github.com/armon/circbuf", analyzing...
Cached github.com/prometheus/client_golang
Package "github.com/coreos/pkg", analyzing...
Cached github.com/godbus/dbus
Package "github.com/d2g/dhcp4client", analyzing...
Cached github.com/armon/circbuf
Package "github.com/docker/libnetwork", analyzing...
Cached github.com/gregjones/httpcache
Package "github.com/fsnotify/fsnotify", analyzing...
Cached github.com/coreos/pkg
Package "github.com/kr/pty", analyzing...
Cached github.com/Azure/go-autorest
Package "github.com/quobyte/api", analyzing...
Cached github.com/d2g/dhcp4client
Package "github.com/spf13/cobra", analyzing...
Cached github.com/kr/pty
Package "golang.org/x/crypto", analyzing...
Cached github.com/fsnotify/fsnotify
Package "gopkg.in/inf.v0", analyzing...
Cached github.com/docker/libnetwork
Package "k8s.io/apimachinery", analyzing...
Cached github.com/quobyte/api
Package "github.com/aws/aws-sdk-go", analyzing...
Cached golang.org/x/crypto
Package "github.com/russross/blackfriday", analyzing...
Cached github.com/spf13/cobra
Package "k8s.io/apiextensions-apiserver", analyzing...
Cached gopkg.in/inf.v0
Package "github.com/daviddengcn/go-colortext", analyzing...
Cached k8s.io/apimachinery
Package "github.com/docker/go-connections", analyzing...
Cached k8s.io/apiextensions-apiserver
Package "github.com/elazarl/go-bindata-assetfs", analyzing...
Cached github.com/russross/blackfriday
Package "github.com/stretchr/testify", analyzing...
Cached github.com/aws/aws-sdk-go
Package "github.com/clusterhq/flocker-go", analyzing...
Cached github.com/daviddengcn/go-colortext
Package "github.com/docker/spdystream", analyzing...
Cached github.com/elazarl/go-bindata-assetfs
Package "github.com/hawkular/hawkular-client-go", analyzing...
Cached github.com/docker/go-connections
Package "k8s.io/sample-apiserver", analyzing...
Cached github.com/stretchr/testify
Package "github.com/opencontainers/runc", analyzing...
Cached github.com/clusterhq/flocker-go
Package "github.com/pkg/errors", analyzing...
Cached github.com/docker/spdystream
Package "github.com/containernetworking/cni", analyzing...
Cached github.com/hawkular/hawkular-client-go
Package "github.com/elazarl/goproxy", analyzing...
Cached k8s.io/sample-apiserver
Package "github.com/emicklei/go-restful-swagger12", analyzing...
Cached github.com/opencontainers/runc
Package "github.com/google/cadvisor", analyzing...
Cached github.com/pkg/errors
Package "github.com/googleapis/gnostic", analyzing...
Cached github.com/containernetworking/cni
Package "github.com/libopenstorage/openstorage", analyzing...
Cached github.com/elazarl/goproxy
Package "github.com/square/go-jose", analyzing...
Cached github.com/emicklei/go-restful-swagger12
Package "golang.org/x/exp", analyzing...
Cached github.com/googleapis/gnostic
Package "k8s.io/utils", analyzing...
Cached github.com/google/cadvisor
Package "vbom.ml/util", analyzing...
Cached github.com/libopenstorage/openstorage
Package "github.com/PuerkitoBio/purell", analyzing...
Cached github.com/square/go-jose
Package "github.com/go-openapi/strfmt", analyzing...
Cached golang.org/x/exp
Package "github.com/mitchellh/go-wordwrap", analyzing...
Cached vbom.ml/util
Package "github.com/mxk/go-flowrate", analyzing...
Cached k8s.io/utils
Package "github.com/opencontainers/selinux", analyzing...
Cached github.com/PuerkitoBio/purell
Package "google.golang.org/grpc", analyzing...
Cached github.com/go-openapi/strfmt
Package "github.com/jonboulle/clockwork", analyzing...
Cached github.com/mitchellh/go-wordwrap
Package "github.com/json-iterator/go", analyzing...
Cached github.com/mxk/go-flowrate
Package "github.com/rubiojr/go-vhd", analyzing...
Cached github.com/opencontainers/selinux
Package "golang.org/x/oauth2", analyzing...
Cached github.com/jonboulle/clockwork
Package "gopkg.in/yaml.v2", analyzing...
Cached github.com/json-iterator/go
Package "k8s.io/kubernetes", analyzing...
Cached google.golang.org/grpc
Package "github.com/cloudflare/cfssl", analyzing...
Cached github.com/rubiojr/go-vhd
Package "github.com/codegangsta/negroni", analyzing...
Cached golang.org/x/oauth2
Package "github.com/d2g/dhcp4", analyzing...
Cached gopkg.in/yaml.v2
Package "github.com/gophercloud/gophercloud", analyzing...
Cached github.com/cloudflare/cfssl
Package "github.com/prometheus/client_model", analyzing...
Cached github.com/codegangsta/negroni
Package "k8s.io/kube-openapi", analyzing...
Cached github.com/d2g/dhcp4
Package "github.com/MakeNowJust/heredoc", analyzing...
Cached github.com/prometheus/client_model
Package "github.com/fatih/camelcase", analyzing...
Cached github.com/gophercloud/gophercloud
Package "github.com/pborman/uuid", analyzing...
Cached k8s.io/kube-openapi
Package "github.com/vishvananda/netlink", analyzing...
Cached github.com/MakeNowJust/heredoc
Package "k8s.io/client-go", analyzing...
Cached github.com/fatih/camelcase
Package "github.com/coreos/etcd", analyzing...
Cached github.com/pborman/uuid
Package "github.com/dgrijalva/jwt-go", analyzing...
Cached github.com/vishvananda/netlink
Package "github.com/go-openapi/spec", analyzing...
Cached k8s.io/client-go
Package "github.com/miekg/coredns", analyzing...
Cached github.com/dgrijalva/jwt-go
Package "k8s.io/metrics", analyzing...
Cached github.com/go-openapi/spec
Package "github.com/howeyc/gopass", analyzing...
Cached github.com/coreos/etcd
Package "github.com/vmware/photon-controller-go-sdk", analyzing...
Cached k8s.io/metrics
Package "k8s.io/kube-aggregator", analyzing...
Cached github.com/howeyc/gopass
Package "github.com/coreos/go-semver", analyzing...
Cached github.com/miekg/coredns
Package "github.com/exponent-io/jsonpath", analyzing...
Cached k8s.io/kube-aggregator
Package "github.com/onsi/ginkgo", analyzing...
Cached github.com/coreos/go-semver
Package "k8s.io/gengo", analyzing...
Cached github.com/vmware/photon-controller-go-sdk
Package "github.com/Azure/azure-sdk-for-go", analyzing...
Cached github.com/exponent-io/jsonpath
Package "github.com/appc/spec", analyzing...
Cached github.com/onsi/ginkgo
Package "github.com/golang/mock", analyzing...
Cached k8s.io/gengo
Package "github.com/lxn/win", analyzing...
Cached github.com/Azure/azure-sdk-for-go
Package "github.com/mvdan/xurls", analyzing...
Cached github.com/appc/spec
Package "gopkg.in/gcfg.v1", analyzing...
Cached github.com/golang/mock
Package "github.com/codedellemc/goscaleio", analyzing...
Cached github.com/lxn/win
Package "github.com/go-openapi/loads", analyzing...
Cached gopkg.in/gcfg.v1
Package "github.com/golang/groupcache", analyzing...
Cached github.com/mvdan/xurls
Package "github.com/opencontainers/go-digest", analyzing...
Cached github.com/codedellemc/goscaleio
Package "github.com/vmware/govmomi", analyzing...
Cached github.com/go-openapi/loads
Package "golang.org/x/net", analyzing...
Cached github.com/golang/groupcache
Package "github.com/coreos/go-oidc", analyzing...
Cached github.com/opencontainers/go-digest
Package "github.com/prometheus/common", analyzing...
Cached golang.org/x/net
Package "golang.org/x/tools", analyzing...
Cached github.com/coreos/go-oidc
Package "k8s.io/heapster", analyzing...
Cached github.com/vmware/govmomi
Package "github.com/docker/distribution", analyzing...
Cached github.com/prometheus/common
Package "github.com/evanphx/json-patch", analyzing...
Cached golang.org/x/tools
Package "github.com/spf13/pflag", analyzing...
Cached k8s.io/heapster
Package "k8s.io/code-generator", analyzing...
Cached github.com/evanphx/json-patch
Package "github.com/gogo/protobuf", analyzing...
Cached k8s.io/kubernetes
Package "github.com/golang/glog", analyzing...
Cached github.com/spf13/pflag
Package "github.com/peterbourgon/diskv", analyzing...
Cached github.com/docker/distribution
Package "golang.org/x/text", analyzing...
Cached k8s.io/code-generator
Package "github.com/Microsoft/hcsshim", analyzing...
Cached github.com/gogo/protobuf
Package "github.com/davecgh/go-spew", analyzing...
Cached github.com/peterbourgon/diskv
Package "github.com/emicklei/go-restful", analyzing...
Cached github.com/golang/glog
Package "github.com/miekg/dns", analyzing...
Cached golang.org/x/text
Package "github.com/mitchellh/mapstructure", analyzing...
Cached github.com/Microsoft/hcsshim
Package "github.com/robfig/cron", analyzing...
Cached github.com/davecgh/go-spew
Package "gopkg.in/natefinch/lumberjack.v2", analyzing...
Cached github.com/emicklei/go-restful
Package "github.com/coreos/go-systemd", analyzing...
Cached github.com/miekg/dns
Package "github.com/coreos/rkt", analyzing...
Cached github.com/mitchellh/mapstructure
Package "github.com/juju/ratelimit", analyzing...
Cached github.com/robfig/cron
Package "github.com/rancher/go-rancher", analyzing...
Cached gopkg.in/natefinch/lumberjack.v2
Package "github.com/renstrom/dedent", analyzing...
Cached github.com/coreos/go-systemd
Package "github.com/xanzy/go-cloudstack", analyzing...
Cached github.com/juju/ratelimit
Package "github.com/xyproto/simpleredis", analyzing...
Cached github.com/rancher/go-rancher
Package "github.com/blang/semver", analyzing...
Cached github.com/renstrom/dedent
Package "k8s.io/api", analyzing...
Cached github.com/xanzy/go-cloudstack
Package "github.com/storageos/go-api", analyzing...
Cached github.com/coreos/rkt
Package "github.com/onsi/gomega", analyzing...
Cached github.com/xyproto/simpleredis
Package "bitbucket.org/bertimus9/systemstat", analyzing...
Cached github.com/blang/semver
Package "bitbucket.org/ww/goautoneg", analyzing...
Cached k8s.io/api
Package "github.com/docker/go-units", analyzing...
Cached github.com/storageos/go-api
Package "github.com/go-openapi/validate", analyzing...
Cached github.com/onsi/gomega
Package "github.com/gorilla/mux", analyzing...
Cached github.com/docker/go-units
Package "github.com/kardianos/osext", analyzing...
Cached github.com/go-openapi/validate
Package "github.com/docker/docker", analyzing...
Cached github.com/gorilla/mux
Package "github.com/hashicorp/golang-lru", analyzing...
Cached github.com/kardianos/osext
Package "github.com/spf13/afero", analyzing...
Cached bitbucket.org/ww/goautoneg
Package "k8s.io/apiserver", analyzing...
Cached github.com/hashicorp/golang-lru
Package "cloud.google.com/go", analyzing...
Cached github.com/spf13/afero
Package "github.com/chai2010/gettext-go", analyzing...
Cached bitbucket.org/bertimus9/systemstat
Package "github.com/heketi/heketi", analyzing...
Cached k8s.io/apiserver
Cached github.com/chai2010/gettext-go
Cached cloud.google.com/go
Cached github.com/heketi/heketi
Cached github.com/docker/docker
Successfully cached all deps.
No versions of golang.org/x/exp met constraints:
	master: Could not introduce golang.org/x/exp@master, as its subpackage golang.org/x/exp/inotify does not contain usable Go code (*build.NoGoError).. (Package is required by (root).)

Copy link
Collaborator

@carolynvs carolynvs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! 👍

I have just some very minor changes, everything is functionally correct.

defer close(deps)
for ip := range a.directDeps {
logger.Printf("Package %q, analyzing...", ip)
pr, err := a.sm.DeduceProjectRoot(ip)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

directDeps is a map of project roots (see below for how it is populated), so you can change the for loop to for pr := range a.directDeps, and remove the call to DeduceProjectRoot.

dep/cmd/dep/init.go

Lines 238 to 242 in bf8f295

pr, err := sm.DeduceProjectRoot(ip)
if err != nil {
return pkgtree.PackageTree{}, nil, err
}
directDeps[string(pr)] = true

return nil
})

go func() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The godoc example used this goroutine with g.Wait() to ensure that they closed the output channel when everything was done (or there was an error). Since we aren't using that, I believe 107-109 can be removed.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

correct. nice catch. This was leftover cruft from when I was working out some bugs in my concurrency

logger.Printf("Unable to cache %s - %s", pr, err)
return err
}
logger.Printf("Cached %s", pr)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at the output, I think it would be clearer if we cut down a bit on how much we are printing. Let's remove this print statement so that we are only logging when we start caching a package, and when the caching fails.

So the output would look more like this:

Caching package github.com/example/A
Caching package github.com/example/B
Caching package github.com/example/C
Successfully cached all deps.

g.Go(func() error {
defer close(deps)
for ip := range a.directDeps {
logger.Printf("Package %q, analyzing...", ip)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's change this to Caching package %q because we aren't actually analyzing anything.

@xmattstrongx
Copy link
Contributor Author

@carolynvs comments address. New output after changes:

git add --all && git reset --hard && dep init --skip-tools
HEAD is now at cd37a28fa5 Update CHANGELOG.md for v1.5.8.
Caching package "github.com/square/go-jose"
Caching package "github.com/vmware/photon-controller-go-sdk"
Caching package "golang.org/x/text"
Caching package "vbom.ml/util"
Caching package "k8s.io/kube-aggregator"
Caching package "k8s.io/kube-openapi"
Caching package "github.com/Azure/azure-sdk-for-go"
Caching package "github.com/coreos/go-systemd"
Caching package "github.com/google/cadvisor"
Caching package "github.com/rancher/go-rancher"
Caching package "github.com/miekg/dns"
Caching package "github.com/onsi/ginkgo"
Caching package "k8s.io/apimachinery"
Caching package "k8s.io/metrics"
Caching package "github.com/daviddengcn/go-colortext"
Caching package "github.com/emicklei/go-restful"
Caching package "github.com/heketi/heketi"
Caching package "github.com/jonboulle/clockwork"
Caching package "github.com/docker/spdystream"
Caching package "github.com/stretchr/testify"
Caching package "github.com/aws/aws-sdk-go"
Caching package "github.com/spf13/afero"
Caching package "k8s.io/client-go"
Caching package "github.com/howeyc/gopass"
Caching package "github.com/robfig/cron"
Caching package "github.com/spf13/cobra"
Caching package "gopkg.in/gcfg.v1"
Caching package "github.com/pborman/uuid"
Caching package "google.golang.org/api"
Caching package "gopkg.in/yaml.v2"
Caching package "github.com/PuerkitoBio/purell"
Caching package "github.com/emicklei/go-restful-swagger12"
Caching package "github.com/golang/mock"
Caching package "github.com/mitchellh/mapstructure"
Caching package "k8s.io/apiextensions-apiserver"
Caching package "github.com/coreos/rkt"
Caching package "github.com/go-openapi/loads"
Caching package "github.com/spf13/viper"
Caching package "github.com/vmware/govmomi"
Caching package "github.com/Microsoft/hcsshim"
Caching package "github.com/d2g/dhcp4"
Caching package "github.com/fsnotify/fsnotify"
Caching package "gopkg.in/inf.v0"
Caching package "github.com/gorilla/mux"
Caching package "github.com/vishvananda/netlink"
Caching package "github.com/pkg/errors"
Caching package "github.com/prometheus/client_golang"
Caching package "github.com/prometheus/client_model"
Caching package "github.com/docker/go-units"
Caching package "github.com/elazarl/goproxy"
Caching package "github.com/golang/glog"
Caching package "github.com/json-iterator/go"
Caching package "github.com/xyproto/simpleredis"
Caching package "google.golang.org/grpc"
Caching package "github.com/d2g/dhcp4client"
Caching package "github.com/golang/groupcache"
Caching package "github.com/google/gofuzz"
Caching package "github.com/rubiojr/go-vhd"
Caching package "github.com/googleapis/gnostic"
Caching package "github.com/onsi/gomega"
Caching package "github.com/renstrom/dedent"
Caching package "github.com/codedellemc/goscaleio"
Caching package "github.com/go-openapi/validate"
Caching package "github.com/juju/ratelimit"
Caching package "github.com/storageos/go-api"
Caching package "golang.org/x/net"
Caching package "github.com/chai2010/gettext-go"
Caching package "github.com/coreos/etcd"
Caching package "github.com/miekg/coredns"
Caching package "github.com/mvdan/xurls"
Caching package "github.com/imdario/mergo"
Caching package "github.com/libopenstorage/openstorage"
Caching package "github.com/hawkular/hawkular-client-go"
Caching package "github.com/kr/pty"
Caching package "github.com/lxn/win"
Caching package "golang.org/x/crypto"
Caching package "github.com/dgrijalva/jwt-go"
Caching package "github.com/exponent-io/jsonpath"
Caching package "github.com/fatih/camelcase"
Caching package "github.com/hashicorp/golang-lru"
Caching package "gopkg.in/natefinch/lumberjack.v2"
Caching package "k8s.io/heapster"
Caching package "github.com/MakeNowJust/heredoc"
Caching package "github.com/containernetworking/cni"
Caching package "github.com/coreos/go-semver"
Caching package "github.com/godbus/dbus"
Caching package "github.com/armon/circbuf"
Caching package "github.com/coreos/go-oidc"
Caching package "k8s.io/apiserver"
Caching package "k8s.io/utils"
Caching package "github.com/mxk/go-flowrate"
Caching package "github.com/russross/blackfriday"
Caching package "github.com/appc/spec"
Caching package "github.com/gregjones/httpcache"
Caching package "github.com/kardianos/osext"
Caching package "github.com/opencontainers/selinux"
Caching package "github.com/quobyte/api"
Caching package "k8s.io/api"
Caching package "github.com/cloudflare/cfssl"
Caching package "github.com/codegangsta/negroni"
Caching package "github.com/cpuguy83/go-md2man"
Caching package "github.com/docker/libnetwork"
Caching package "k8s.io/gengo"
Caching package "k8s.io/sample-apiserver"
Caching package "bitbucket.org/ww/goautoneg"
Caching package "golang.org/x/oauth2"
Caching package "golang.org/x/sys"
Caching package "k8s.io/kubernetes"
Caching package "github.com/docker/go-connections"
Caching package "github.com/opencontainers/go-digest"
Caching package "github.com/golang/protobuf"
Caching package "github.com/opencontainers/runc"
Caching package "k8s.io/code-generator"
Caching package "github.com/Azure/go-autorest"
Caching package "github.com/docker/distribution"
Caching package "github.com/go-openapi/spec"
Caching package "github.com/gogo/protobuf"
Caching package "github.com/coreos/pkg"
Caching package "github.com/evanphx/json-patch"
Caching package "github.com/ghodss/yaml"
Caching package "golang.org/x/tools"
Caching package "bitbucket.org/bertimus9/systemstat"
Caching package "cloud.google.com/go"
Caching package "github.com/peterbourgon/diskv"
Caching package "github.com/prometheus/common"
Caching package "github.com/blang/semver"
Caching package "github.com/clusterhq/flocker-go"
Caching package "github.com/elazarl/go-bindata-assetfs"
Caching package "github.com/davecgh/go-spew"
Caching package "github.com/docker/docker"
Caching package "github.com/influxdata/influxdb"
Caching package "golang.org/x/exp"
Caching package "github.com/go-openapi/strfmt"
Caching package "github.com/gophercloud/gophercloud"
Caching package "github.com/spf13/pflag"
Caching package "github.com/xanzy/go-cloudstack"
Caching package "github.com/mitchellh/go-wordwrap"
Successfully cached all deps.
No versions of golang.org/x/exp met constraints:
	master: Could not introduce golang.org/x/exp@master, as its subpackage golang.org/x/exp/inotify does not contain usable Go code (*build.NoGoError).. Package is required by:
	(root)
	github.com/google/cadvisor@v0.27.2

@carolynvs
Copy link
Collaborator

Yay! Thank you for adding this, it should really help with the "wtf is dep doing?!" moments. 🎉 💖

@carolynvs carolynvs merged commit 43474dd into golang:master Oct 26, 2017
carolynvs added a commit to carolynvs/dep that referenced this pull request Oct 26, 2017
carolynvs added a commit to carolynvs/dep that referenced this pull request Oct 26, 2017
carolynvs added a commit to carolynvs/dep that referenced this pull request Oct 26, 2017
carolynvs added a commit to carolynvs/dep that referenced this pull request Oct 26, 2017
carolynvs added a commit that referenced this pull request Oct 26, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Prefetch direct dependencies during init
3 participants