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

Gopkg.toml source option invalid #1721

Closed
eddycjy opened this issue Feb 28, 2018 · 6 comments
Closed

Gopkg.toml source option invalid #1721

eddycjy opened this issue Feb 28, 2018 · 6 comments

Comments

@eddycjy
Copy link

eddycjy commented Feb 28, 2018

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

dep:
 version     : devel
 build date  : 
 git hash    : 
 go version  : go1.9
 go compiler : gc
 platform    : linux/amd64

What dep command did you run?

  1. Gopkg.toml :
[[constraint]]
  name = "golang.org/x/text"
  source = "https://github.com/golang/text.git"
  1. main.go (test) :
package main

import (
    "golang.org/x/text/date"
)

func main() {
    date.EtcUTC
}
  1. Run Command :
    dep ensure

What did you expect to see?

I hope that after the source option is configured golang.org/x/text pulls resources from https://github.com/golang/text.git

What did you see instead?

Chinese area golang.org connection is ban, in the case of not using VPN, I configured the source option, hope that through this configuration to pull resources from github, but failed, why ?

error:

The following issues were found in Gopkg.toml:

  ✗ unable to deduce repository and source type for "golang.org/x/text": unable to read metadata: unable to fetch raw metadata: failed HTTP request to URL "http://golang.org/x/text?go-get=1": Get http://golang.org/x/text?go-get=1: dial tcp 216.239.37.1:80: getsockopt: connection timed out

ProjectRoot name validation failed
@wadelee1986
Copy link

+1

@bensonfx
Copy link

bensonfx commented May 1, 2018

same problem.
dep tool's purpose is to resolve the dependency problem.
Many guys in China have the GFW problem.

@bensonfx
Copy link

bensonfx commented May 9, 2018

I add code like this.
the mirror rule can use getProjectConstraint to parse,like dep ensure -add
image

@denglitong
Copy link

+1

@mcauto
Copy link

mcauto commented Dec 28, 2018

+1

@mvdan
Copy link
Member

mvdan commented Sep 4, 2020

Dep was officially deprecated earlier this year, and the proposal to archive this repository was accepted. As such, I'm closing outstanding issues before archiving the repository. For any further comments, please use the proposal thread on the Go issue tracker. Thanks!

@mvdan mvdan closed this as completed Sep 4, 2020
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

6 participants