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

dep init failing for repositories with sub-directories #651

Closed
@ghost

Description

dep master 83e2b6f

Steps to reproduce:

  1. mkdir $GOPATH/src/foo
  2. cd $GOPATH/src/foo
cat > foo.go <<EOL
package foo
import (
        "github.com/prometheus/client_golang/prometheus"
)
func main() {
}
EOL
  1. dep init

Expected output:
$? == 0

Actual output:

Searching GOPATH for projects...
Following dependencies were not found in GOPATH. Dep will use the most recent versions of these projects.
  github.com/prometheus/client_golang
safe write of manifest and lock: second attempt failed: cannot rename /tmp/dep666066408/vendor to /home/ser/workspace/src/foo/vendor: read /tmp/dep666066408/vendor/github.com/prometheus/procfs/fixtures/self: is a directory

More Info
I believe it is because of the import of a subdirectory; I haven't encountered this error when importing a 3-segment path.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions