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

could not deduce project root for golang.org/x/sys/unix: unable to deduce repository and source type for: "golang.org/x/sys/unix" #292

Closed
sgamerw opened this issue Mar 7, 2017 · 6 comments

Comments

@sgamerw
Copy link

sgamerw commented Mar 7, 2017

could not deduce project root for golang.org/x/sys/unix: unable to deduce repository and source type for: "golang.org/x/sys/unix"

@sdboyer
Copy link
Member

sdboyer commented Mar 7, 2017

Please re-file a proper bug report, including:

  • The command you ran when experiencing the error
  • Any other output that you saw alongside the error
  • The directory from which you ran the command
  • The output of go env

That said, being that your profile location says "Beijing," I'm pretty sure this is the GFW blocking HTTP metadata requests to golang.org to resolve the vanity URL. We may develop better workarounds as part of #286, but that's not going to be for a little while.

@sdboyer sdboyer closed this as completed Mar 7, 2017
@bsed
Copy link

bsed commented May 15, 2017

sm.DeduceProjectRoot: unable to deduce repository and source type for: "golang.org/x/crypto/acme/autocert" i from beijing

go env

$ go env
set GOARCH=amd64
set GOBIN=d:\go\bin
set GOEXE=.exe
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOOS=windows
set GOPATH=E:\gocode
set GORACE=
set GOROOT=d:\go
set GOTOOLDIR=d:\go\pkg\tool\windows_amd64
set GCCGO=gccgo
set CC=gcc
set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0
set CXX=g++
set CGO_ENABLED=1
set PKG_CONFIG=pkg-config
set CGO_CFLAGS=-g -O2
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2

@sdboyer
Copy link
Member

sdboyer commented May 15, 2017

from beijing

This is very likely the great firewall denying access to golang.org. There's not a lot we can do at this stage, but I think you'd likely be able to solve the issue at least for yourself with a socks5 proxy; see e.g. discussion in Masterminds/glide#417.

@bsed
Copy link

bsed commented May 16, 2017

@sdboyer sir, I've already used VPN, or is that the problem?.

@bsed
Copy link

bsed commented May 16, 2017

@sdboyer @zjx20 i use socks-cli solved the problem,tks

ibrasho added a commit to ibrasho-forks/dep that referenced this issue Jun 6, 2017
solver.selectRoot() panics when solver.intersectConstraintsWithImports()
returns an error.

This commit returns the error instead if that error is due to inability
to deduce a project repository.

Solves golang#292 and golang#581

Signed-off-by: Ibrahim AshShohail <ibra.sho@gmail.com>
@iEthereal
Copy link

iEthereal commented Mar 6, 2019

set http_proxy=127.0.0.1:1080
set https_proxy=127.0.0.1:1080

Executing above code before dep ensure -v works for me . BTW, I have ShadowSockets installed serving at port 1080.

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

No branches or pull requests

4 participants