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

dep ensure -v stuck and frozen forever #1163

Closed
tchap opened this issue Sep 13, 2017 · 24 comments
Closed

dep ensure -v stuck and frozen forever #1163

tchap opened this issue Sep 13, 2017 · 24 comments
Labels

Comments

@tchap
Copy link

tchap commented Sep 13, 2017

What version of dep are you using (dep version)?

dep: stable 0.3.0 from Homebrew.

What dep command did you run?

dep ensure -v

... other deps checked before are ok ...

13)  ? attempt github.com/labstack/echo with 4 pkgs; 51 versions to try
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/echo at 3.2.3 has problem subpkg(s):
(14)    	github.com/labstack/echo/engine is missing; required by (root).	github.com/labstack/echo/engine/fasthttp is missing; required by (root).
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/[email protected]
(14)  ✗   github.com/labstack/[email protected] not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/echo@master
(14)  ✗   github.com/labstack/echo@master not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/echo@v1
(14)  ✗   github.com/labstack/echo@v1 not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)      try github.com/labstack/echo@v2
(14)  ✗   github.com/labstack/echo@v2 not allowed by constraint ^3.2.3:
(14)      ^3.2.3 from (root)
(13)    ← no more versions of github.com/labstack/echo to try; begin backtrack
(12)  ← backtrack: no more versions of github.com/gorilla/websocket to try
(11)  ← backtrack: no more versions of github.com/kelseyhightower/envconfig to try
(10)  ← backtrack: no more versions of github.com/google/go-querystring to try
(9)	← backtrack: no more versions of github.com/google/go-github to try
(8)	← backtrack: no more versions of github.com/pkg/errors to try
(7)	← backtrack: no more versions of github.com/steemwatch/blockfetcher to try
(6)	← backtrack: no more versions of github.com/go-telegram-bot-api/telegram-bot-api to try
(5)	← backtrack: no more versions of github.com/gorilla/securecookie to try
(4)	← backtrack: no more versions of github.com/hashicorp/golang-lru to try
(3)	← backtrack: no more versions of github.com/go-steem/rpc-codec to try
(2)	← backtrack: no more versions of github.com/go-steem/rpc to try
(1)	← backtrack: no more versions of github.com/bwmarrin/discordgo to try
  ✗ solving failed

Solver wall times by segment:
     b-source-exists: 23.909982118s
         b-list-pkgs:  3.773812813s
              b-gmal:  2.543646423s
  b-deduce-proj-root:  2.153111015s
             satisfy:    6.247974ms
            unselect:    4.760852ms
         select-root:     2.57067ms
            new-atom:    2.107874ms
         select-atom:     1.84679ms
          b-pair-rev:    1.179364ms
           backtrack:     356.688µs
     b-list-versions:     198.021µs
           b-matches:      80.919µs
               other:      15.125µs

  TOTAL: 32.399916646s


... and now it is stuck until interrupted ...

What did you expect to see?

I expected dep to fail and exit.

What did you see instead?

I saw dep getting stuck forever.

@sdboyer
Copy link
Member

sdboyer commented Sep 13, 2017

hi, thanks for the issue! eek, this is definitely a new one - while there are hangs, which are almost always on network traffic, those generally occur during the solving process. your trace there indicated that you finished solving - never seen a hang there, before.

is the issue repeatable? if so, if you use the latest tip (go get github.com/golang/dep/cmd/dep), does the issue still occur?

@sdboyer sdboyer added the bug label Sep 13, 2017
@tchap
Copy link
Author

tchap commented Sep 13, 2017

It is happening even when I install the current tip.

Sent SIGQUIT to the process when it was stuck, the stack trace is attached.

dep_stacktrace.txt

@sdboyer
Copy link
Member

sdboyer commented Sep 13, 2017

ok, a quick pass over that stacktrace suggests that it's not actually blocked on work that was initiated by anything that happens after solving is complete, but rather on background work that was initiated during the solving process. there are a handful of subprocess commands are running git ls-remote, and none of them seem to be finishing. very weird.

could you run dep hash-inputs? does your project have any direct or transitive dependencies that are hosted someplace other than on the big public hosts (like github), potentially with odd git serverside configurations?

@tchap
Copy link
Author

tchap commented Sep 14, 2017

$ ~/go/bin/dep hash-inputs
-CONSTRAINTS-
github.com/bwmarrin/discordgo
b-develop
github.com/go-steem/rpc
svc-^0.8.0
github.com/go-telegram-bot-api/telegram-bot-api
svc-^4.6.0
github.com/google/go-github
b-master
github.com/gorilla/securecookie
b-master
github.com/kelseyhightower/envconfig
b-master
github.com/kr/pretty
b-master
github.com/labstack/echo
svc-^3.2.3
github.com/pkg/errors
b-master
github.com/steemwatch/blockfetcher
b-master
github.com/tchap/securecookie
b-master
github.com/tchap/websocket
b-master
github.com/valyala/fasthttp
b-master
golang.org/x/oauth2
b-master
google.golang.org/api
b-master
gopkg.in/mgo.v2
b-v2
gopkg.in/tomb.v2
b-v2
-IMPORTS/REQS-
github.com/bwmarrin/discordgo
github.com/go-steem/rpc
github.com/go-steem/rpc/apis/database
github.com/go-steem/rpc/transports/websocket
github.com/go-steem/rpc/types
github.com/go-telegram-bot-api/telegram-bot-api
github.com/google/go-github/github
github.com/gorilla/securecookie
github.com/hashicorp/golang-lru
github.com/kelseyhightower/envconfig
github.com/kr/pretty
github.com/labstack/echo
github.com/labstack/echo/engine/fasthttp
github.com/labstack/echo/middleware
github.com/pkg/errors
github.com/steemwatch/blockfetcher
github.com/tchap/securecookie
github.com/tchap/websocket
github.com/valyala/fasthttp
golang.org/x/oauth2
golang.org/x/oauth2/facebook
golang.org/x/oauth2/github
golang.org/x/oauth2/google
google.golang.org/api/plus/v1
gopkg.in/mgo.v2
gopkg.in/mgo.v2/bson
gopkg.in/tomb.v2
-IGNORES-
-OVERRIDES-
-ANALYZER-
dep
1

@tamird
Copy link
Contributor

tamird commented Sep 14, 2017

Could you provide your Gopkg.{toml,lock} files? I wonder if this is reproducible.

Of course, if you can share your entire project, even better!

@tchap
Copy link
Author

tchap commented Sep 14, 2017

It should be https://github.com/tchap/steemwatch/tree/13291e84c75c07d10ee10a94dc634b849d9d6880 . It's a WIP commt that will be squashed eventually, but probably not any time soon.

@tchap
Copy link
Author

tchap commented Sep 14, 2017

Kinda weird, though, because when I run status in a different repository, it seems to be stuck as well. When I send SIGINT, I get the following output:

$ dep status -v
^CSignal received: waiting for 1 ops to complete...
PROJECT                                           CONSTRAINT       VERSION          REVISION  LATEST   PKGS USED
github.com/Shopify/sarama                         ^1.11.0          v1.12.0          c01858a   c01858a  1
github.com/beorn7/perks                           *                branch master    4c0e845   4c0e845  1
github.com/buger/jsonparser                       *                branch master    fda8192   fda8192  1
github.com/certifi/gocertifi                      *                2017.07.27       3fd9e1a   3fd9e1a  1
github.com/codegangsta/inject                     *                v1.0-rc1         37d7f84   37d7f84  1
github.com/confluentinc/confluent-kafka-go        ^0.11.0          v0.11.0          f696f02   f696f02  1
github.com/cznic/b                                *                branch master    6955404   6955404  1
github.com/cznic/fileutil                         *                branch master    90cf820   90cf820  1
github.com/cznic/golex                            *                branch master    4ab7c5e   4ab7c5e  1
github.com/cznic/internal                         *                1.0.0            cef02a8   cef02a8  3
github.com/cznic/lldb                             *                v1.1.0           bea8611   bea8611  1
github.com/cznic/mathutil                         *                branch master    91af0ce   91af0ce  1
github.com/cznic/ql                               branch issue176  branch issue176  ba9eea9   ba9eea9  3
github.com/cznic/sortutil                         *                branch master    4c73428   4c73428  1
github.com/cznic/strutil                          *                branch master    43a8959   43a8959  1
github.com/cznic/zappy                            *                branch master    2533cb5   2533cb5  1
github.com/davecgh/go-spew                        *                v1.1.0           346938d   346938d  1
github.com/dgrijalva/jwt-go                       *                v3.0.0           d2709f9   d2709f9  1
github.com/eapache/go-resiliency                  *                v1.0.0           6800482   6800482  1
github.com/eapache/go-xerial-snappy               *                branch master    bb955e0   bb955e0  1
github.com/eapache/queue                          *                v1.0.2           ded5959   ded5959  1
github.com/eclipse/paho.mqtt.golang               *                v1.1.0           aff1577   aff1577  2
github.com/edsrzf/mmap-go                         *                branch master    0bce6a6   0bce6a6  1
github.com/garyburd/redigo                        ^1.1.0           v1.1.0           4339695   4339695  2
github.com/getsentry/raven-go                     *                branch master    d175f85   d175f85  1
github.com/go-playground/locales                  *                v0.11.1          b860c92   b860c92  2
github.com/go-playground/universal-translator     *                v0.16.0          b32fa30   b32fa30  1
github.com/golang/groupcache                      *                branch master    b710c84   b710c84  1
github.com/golang/protobuf                        *                branch master    17ce142   17ce142  1
github.com/golang/snappy                          *                branch master    553a641   553a641  1
github.com/google/uuid                            *                0.2              064e206   064e206  1
github.com/gopherjs/gopherjs                      *                branch master    b40cd48   b40cd48  1
github.com/influxdata/influxdb                    ^1.2.4           v1.3.5           9d90010   9d90010  3
github.com/jmoiron/sqlx                           *                branch master    d9bd385   d9bd385  3
github.com/jtolds/gls                             *                v4.2.1           77f1821   77f1821  1
github.com/kr/pretty                              *                branch master    cfb55aa   cfb55aa  1
github.com/kr/text                                *                branch master    7cafcd8   7cafcd8  1
github.com/labstack/echo                          *                3.2.3            cec7629            2
github.com/labstack/gommon                        *                0.2.2            779b8a8            4
github.com/lib/pq                                 *                branch master    e422674            2
github.com/mattes/migrate                         ^3.0.1           v3.0.1           035c077            6
github.com/mattn/go-colorable                     *                v0.0.9           167de6b            1
github.com/mattn/go-isatty                        *                v0.0.2           fc9e8d8            1
github.com/matttproud/golang_protobuf_extensions  *                v1.0.0           3247c84            1
github.com/mohae/deepcopy                         *                branch master    491d360            1
github.com/pierrec/lz4                            *                v1.0             5c9560b            1
github.com/pierrec/xxHash                         *                v0.1.1           f051bb7            1
github.com/pkg/errors                             *                v0.8.0           645ef00            1
github.com/prometheus/client_golang               *                v0.8.0           c5b7fcc            2
github.com/prometheus/client_model                *                branch master    6f38060            1
github.com/prometheus/common                      *                branch master    2f17f4a            3
github.com/prometheus/procfs                      *                branch master    e645f4e            2
github.com/rcrowley/go-metrics                    *                branch master    1f30fe9            1
github.com/smartystreets/assertions               *                1.7.0            9c0ea8a            3
github.com/smartystreets/goconvey                 *                1.6.3            9e8dc3f            3
github.com/tchap/zapext                           *                branch master    b3d0aa8            3
github.com/ugorji/go                              *                branch master    8c0409f            1
github.com/valyala/bytebufferpool                 *                branch master    e746df9            1
github.com/valyala/fasttemplate                   *                branch master    dcecefd            1
go.uber.org/atomic                                *                v1.2.0           4e33664            1
go.uber.org/multierr                              *                v1.1.0           3c49374            1
go.uber.org/zap                                   *                v1.6.0           3216c4c            6
golang.org/x/crypto                               *                branch master    faadfbd            2
golang.org/x/net                                  *                branch master    859d1a8            3
golang.org/x/sys                                  *                branch master    062cd7e            1
gopkg.in/edn.v1                                   *                branch v1        948ec68            1
gopkg.in/go-playground/validator.v9               *                v9.7.0           a021b2e            1
gopkg.in/tomb.v2                                  *                branch v2        d5d1b58            1
gopkg.in/urfave/cli.v2                            *                branch v2        50a0fde            1

Here is the stack trace for SIGQUIT: dep_status_stacktrace.txt

Can't tell what kind of issue it is, the verbose mode is not printing anything really and the output looks fine, except the fact that I need to send SIGINT to see it :-)

@sdboyer
Copy link
Member

sdboyer commented Sep 15, 2017 via email

@tchap
Copy link
Author

tchap commented Sep 16, 2017

I am on Mac OS X, so there is DTrace I guess, but never used that one before...

@tamird
Copy link
Contributor

tamird commented Sep 16, 2017

@tchap could you try this with the latest code from master? both your stack traces include newMonitoredCmd which was recently removed.

Also, you could use pstree -s dep -www to see what's hanging. You can get pstree from homebrew.

@tchap
Copy link
Author

tchap commented Sep 17, 2017

@tamird I upgraded from master. Now I am getting the following (when it is stuck):

$ pstree -s dep -www
-+= 00001 root /sbin/launchd
 \-+= 00255 tchap /Applications/iTerm.app/Contents/MacOS/iTerm2 -psn_0_49164
   \-+= 69647 tchap /Applications/iTerm.app/Contents/MacOS/iTerm2 --server /usr/bin/login -fpl tchap /Applications/iTerm.app/Contents/MacOS/iTerm2 --launch_shell
     \-+= 69648 root /usr/bin/login -fpl tchap /Applications/iTerm.app/Contents/MacOS/iTerm2 --launch_shell
       \-+= 69649 tchap -bash
         \--= 72926 tchap /Users/tchap/go/bin/dep ensure -v

The new stack trace:
dep_ensure.stacktrace.txt

@tamird
Copy link
Contributor

tamird commented Sep 17, 2017

That's very strange - there are a number of pending (*os/exec.Cmd).CombinedOutput calls, but no child processes. How could that happen?

@tchap
Copy link
Author

tchap commented Sep 17, 2017

@tamird On the other hand, using just ps shows

87287 ttys002    0:00.03 /usr/bin/ssh [email protected] git-upload-pack 'technoweenie/multipartstreamer'
87295 ttys002    0:00.03 /usr/bin/ssh [email protected] git-upload-pack 'mattn/go-isatty'
87298 ttys002    0:00.03 /usr/bin/ssh [email protected] git-upload-pack 'labstack/gommon'
87325 ttys002    0:00.03 /usr/bin/ssh [email protected] git-upload-pack 'dgrijalva/jwt-go'
87332 ttys002    0:00.03 /usr/bin/ssh [email protected] git-upload-pack 'golang/protobuf'
87335 ttys002    0:00.03 /usr/bin/ssh [email protected] git-upload-pack 'valyala/fasttemplate'
87355 ttys002    0:00.02 /usr/bin/ssh [email protected] git-upload-pack 'golang/appengine'

Killing these processes makes dep print the output and exit.

@sdboyer
Copy link
Member

sdboyer commented Sep 18, 2017

@tchap hmm, so, hanging on those indicates that the hang is almost certainly occurring on attempts to git fetch. it's slightly surprising that it's doing that over ssh, rather than http, which is the default.

could you dump the results of git config -l, run from within your project dir? (sanitize as needed)

@tchap
Copy link
Author

tchap commented Sep 18, 2017

@sdboyer I think that this is it: [email protected]:.insteadof=https://github.com/ :-) Not sure why I did it. To handle private repositories or something, at one point.

@sdboyer
Copy link
Member

sdboyer commented Sep 19, 2017

@tchap yes, i figured you probably had that set. however, even that's still a bit surprising - that multiple ssh commands would be hanging at the same time. the test that i thought covered that case appears not to, but even when i modify the test to use SSH, it still works fine (albeit a bit slower than with https).

any chance that you're not running an ssh-agent locally, and all of those ssh processes are hung waiting for you to input a password?

(also, thanks for the pstree suggestion, @tamird)

@tchap
Copy link
Author

tchap commented Sep 19, 2017

@sdboyer That is not really possible. I am connecting to GitHub without inserting anything all the time.

@sdboyer
Copy link
Member

sdboyer commented Sep 20, 2017

bleh. i'd point you to dtruss/dtrace, but i'm guessing you'd probably have to go through disabling SIP in order to get anything useful, which feels like too much to ask. i guess we just call this ¯\_(ツ)_/¯ 😢

@sdboyer sdboyer closed this as completed Sep 20, 2017
@tchap
Copy link
Author

tchap commented Sep 20, 2017

In case I am like totally bored I may give this a try. That unfortunately won't happen before 2042 or so... 👼

Thanks anyway.

@sdboyer
Copy link
Member

sdboyer commented Sep 20, 2017

if you do get bored, let me know, as the info would be invaluable. otherwise, I'm glad we at least got this sorted for you 🎉

@traetox
Copy link

traetox commented Jan 4, 2018

@sdboyer Yes, exactly that (re the password). dep cannot handle anything where ssh or git stop and ask a question (e.g. passwords, host keys, etc..). Would you accept a PR that looked for an ENV variable stating that all commands should be run linearly and stdio, stderr, and stdout wired to the calling terminal? That way we could at least input the password/accept host key.

As it stands, dep won't work if an GIT+SSH is protected with a passphrase.

@rodrigo-brito
Copy link

Solved! Same problem here. Dep has a problem with private repositories, if you use your SSH key for fetch, use the command: ssh-add -K ~/.ssh/id_rsa to add your key to the keychain.

@gregohardy
Copy link

@rodrigo-brito Thanks! Saved me hours of pain.

@elivingt
Copy link

I had a similar issue.
Found out it was access rights of dep to the git repository.

I cloned the project using ssh (NOT https)
re-run dep ensure

and the problem was gone.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

7 participants