LoginSignup
0
0

More than 3 years have passed since last update.

dep ensureでbuild.NoGoErrorが出た場合

Posted at

github.com/aws/aws-xray-sdk-goをdepを使って取り込もうとし、READMEに従いdep ensureコマンドを入力したら下記エラーに出くわした。

$ dep ensure -add github.com/aws/aws-xray-sdk-go
Fetching sources...

Solving failure: No versions of github.com/aws/aws-xray-sdk-go met constraints:
    v0.9.4: Could not introduce github.com/aws/aws-xray-sdk-go@v0.9.4, as its subpackage github.com/aws/aws-xray-sdk-go does not contain usable Go code (*build.NoGoError).. (Package is required by (root).)

これはgithub.com/aws/aws-xray-sdk-goの配下に.goファイルが見つからないためエラーになっている模様。
.goファイルが入っているpackageを指定したらエラーなく取り込めた

$ dep ensure -add github.com/aws/aws-xray-sdk-go/xray                                                                                                   
Fetching sources...

"github.com/aws/aws-xray-sdk-go/xray" is not imported by your project, and has been temporarily added to Gopkg.lock and vendor/.
If you run "dep ensure" again before actually importing it, it will disappear from Gopkg.lock and vendor/.
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0