FISCO-BCOS / FISCO-BCOS/go-sdk

go mod tidy时出现了模糊导入的问题

Open
#151 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
74
Forks
63
PR merge metrics
No merged PRs in 30d

Description

go1.16.9 darwin/amd64

报错如下:
imports
github.com/FISCO-BCOS/go-sdk/abi imports
github.com/ethereum/go-ethereum/crypto imports
github.com/btcsuite/btcd/btcec/v2/ecdsa tested by
github.com/btcsuite/btcd/btcec/v2/ecdsa.test imports
github.com/btcsuite/btcd/chaincfg/chainhash: ambiguous import: found package github.com/btcsuite/btcd/chaincfg/chainhash in multiple modules:
github.com/btcsuite/btcd v0.21.0-beta (/Users/coyee/go/pkg/mod/github.com/btcsuite/btcd@v0.21.0-beta/chaincfg/chainhash)
github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 (/Users/coyee/go/pkg/mod/github.com/btcsuite/btcd/chaincfg/chainhash@v1.0.1)

之前使用旧版本sdk时未出现过,请问是我本地环境有问题吗?这个问题怎么解决?

Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce `go mod tidy` with Go 1.16.9 on darwin/amd64 and inspect the module requirements involving github.com/btcsuite/btcd and github.com/btcsuite/btcd/chaincfg/chainhash. Compare the two modules reported in the ambiguous-import error; done means the dependency graph has one unambiguous chainhash package and `go mod tidy` completes successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.