Consensys / quorum

A permissioned implementation of Ethereum supporting data privacy
https://www.goquorum.com/
GNU Lesser General Public License v3.0
4.69k stars 1.3k forks source link

gopkg.in/oleiade/lane.v1@v1.0.0: go.mod has non-....v1 module path "github.com/oleiade/lane" at revision v1.0.0 #1539

Closed MisiakGeo closed 2 years ago

MisiakGeo commented 2 years ago

Hello, I am trying to use the goQuorum packages, and the following error regarding the oleiade/lane package appears image

The go.mod that I am using is depicted in the following image: image

Any directions that need to follow in order to be able to overcome this issue would be much appreciated.

baptiste-b-pegasys commented 2 years ago

Hello, I see you are using an old version of goquorum, and we are not using go 1.17.

The lane dependency is used by the raft package.

It's not easy for me to reproduce the problem, therefore I am just posing some ideas that might worth to test

  1. I would try to add anexclude property on either raft package or lane dependency (https://go.dev/ref/mod#go-mod-file-exclude)
  2. or a specific replace of Lane with a commit or version that could work

making a go mod tidy usually helps a lot, and we can see that when we change the version go, doing a tidy changes the go.mod definition.

  1. if there is no chance, you might create a fork of goquorum and fix the go modules, by upgrading the go version and by making a go mod tidy.

let me know what happens, you can point me to the specific commit of your project so I can try to reproduce the issue.

MisiakGeo commented 2 years ago

Hello @baptiste-b-pegasys, Thank you for your response. This issue appeared, in a clean machine when go get tries to fetch the packages online. Please find attach the goQuorum version and Go version that was used. Its old but not that old. In my machine that these packages were cached, the problem does not appeared but on the other hand, in a new clean machine this issue appeared. image

baptiste-b-pegasys commented 2 years ago

do you have a link to the commit of the repo so I can take a look at it? thank you

MisiakGeo commented 2 years ago

Hello @baptiste-b-pegasys, I do not have a link. The error occurred during the go get phase, using the aforementioned go.mod. For convenience, I also paste it here: replace ( github.com/ethereum/go-ethereum => github.com/Consensys/quorum v1.2.2-0.20210518093622-1d7926a19a1e github.com/ethereum/go-ethereum/crypto/secp256k1 => github.com/ConsenSys/quorum/crypto/secp256k1 v0.0.0-20210518093622-1d7926a19a1e )

When I executed: go mod tidy, the error appeared.

baptiste-b-pegasys commented 2 years ago

frankly it is hard for me to help if I can't reproduce on my side.

MisiakGeo commented 2 years ago

Hello again @baptiste-b-pegasys , After further investigation it seems that the package gopkg.in/oleiade/lane.v1, that is located here has changed and has moved away from gopkg.in. As shown here here it is imported in github.com with different name. Instead of gopkg.in/oleiade/lane.v1 it has changed to github.com/oleiade/lane. Am I missing something?

MisiakGeo commented 2 years ago

What is the latest GoQuorum package revision that I can download using go.mod ?

baptiste-b-pegasys commented 2 years ago

The latest is v22.7.3 : https://github.com/ConsenSys/quorum/releases/tag/v22.7.3

and it is using gopkg.in/oleiade/lane.v1 v1.0.0

YU-YUEHAO commented 1 year ago

Yes, I'm having this issue as well, but I check https://github.com/oleiade/lane is not gopkg.in/oleiade/lane.v1 v1.0.0 How do I fix it @MisiakGeo

gmisiakoulis commented 1 year ago

Hello @YU-YUEHAO,

I encountered a challenge in resolving this issue. Fortunately, I had a backup of the Go cache directory, allowing me to overcome the problem. I successfully proceeded by copying the old oleiade directory from the backup into the Go cache directory.