Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

go-fuzz unknown revision #287

Closed
ptrcvc opened this issue Apr 15, 2022 · 4 comments
Closed

go-fuzz unknown revision #287

ptrcvc opened this issue Apr 15, 2022 · 4 comments

Comments

@ptrcvc
Copy link

ptrcvc commented Apr 15, 2022

I'm playing around with a fakenet using a digital ocean droplet. go version go1.16.15 linux/amd64

building results in an error as dvyukov/go-fuzz is replaced:

$ go build
go: github.com/dvyukov/[email protected] (replaced by github.com/guzenok/[email protected]): version "v0.0.0-20210103140116-f9104dfb626f" invalid: unknown revision f9104dfb626f

i personally fixed this by removing line 48 from go.mod:

replace github.com/dvyukov/go-fuzz => github.com/guzenok/go-fuzz v0.0.0-20210103140116-f9104dfb626f

then:

$ go mod download github.com/dvyukov/go-fuzz

I don't really know why /dvyukov/go-fuzz was replaced, looking at the version history of go.mod showed some revisions related to it but i couldnt find the reasoning as to why. Unexperienced with all of this, so forgive me

@Fantom-foundation Fantom-foundation deleted a comment Apr 27, 2022
@rus-alex
Copy link
Contributor

rus-alex commented May 3, 2022

Unfortunately, origin github.com/dvyukov/go-fuzz can't build the fuzzing test program for go-opera:

$ go run github.com/dvyukov/go-fuzz/go-fuzz-build -o=./fuzzing/gossip-fuzz.zip ./gossip
failed to execute go build: exit status 1
/tmp/go-fuzz-build1233413096/goroot/src/crypto/elliptic/p256_asm.go:32:12: pattern p256_asm_table.bin: no matching files found

The fix is still not merged, so we replaced origin go-fuzz with fixed fork in go-opera go.mod.

That is why dvyukov/go-fuzz was replaced.

@rus-alex
Copy link
Contributor

rus-alex commented May 3, 2022

@ptrcvc , as for your trouble on digital ocean droplet, show me the full output of go env please.
Now I don't see any barrier to download github.com/guzenok/go-fuzz v0.0.0-20210103140116-f9104dfb626f revision:

$ go mod init example                                                                                                                                                       
go: creating new go.mod: module example
$ go get github.com/guzenok/[email protected]
go: added github.com/guzenok/go-fuzz v0.0.0-20210103140116-f9104dfb626f
$ go clean -modcache
$ go mod download

@AaronKutch
Copy link
Contributor

AaronKutch commented May 7, 2022

I'm getting the error when compiling in an empty container:

FROM fedora:34
RUN dnf install -y git make gcc gcc-c++ which iproute iputils procps-ng vim-minimal tmux net-tools htop tar jq npm openssl-devel perl rust cargo golang

ADD https://github.com/Fantom-foundation/go-opera/archive/refs/tags/v1.1.0-rc.5.tar.gz /go-opera/
RUN cd /go-opera && tar -xvf * && cd ./go-opera-1.1.0-rc.5 && make opera && mv ./build/opera /usr/bin/opera

#8 0.315 GIT_COMMIT=`git rev-list -1 HEAD 2>/dev/null || echo ""` && \
#8 0.315 GIT_DATE=`git log -1 --date=short --pretty=format:%ct 2>/dev/null || echo ""` && \
#8 0.315 go build \
#8 0.315     -ldflags "-s -w -X github.com/Fantom-foundation/go-opera/cmd/opera/launcher.gitCommit=${GIT_COMMIT} -X github.com/Fantom-foundation/go-opera/cmd/opera/launcher.gitDate=${GIT_DATE}" \
#8 0.315     -o build/opera \
#8 0.315     ./cmd/opera
#8 73.52 go: github.com/dvyukov/[email protected] (replaced by github.com/guzenok/[email protected]): version "v0.0.0-20210103140116-f9104dfb626f" invalid: unknown revision f9104dfb626f
#8 73.52 make: *** [Makefile:6: opera] Error 1

@rus-alex
Copy link
Contributor

@AaronKutch , I got the same error and fixed it by ENV GOPROXY in the dockerfile:

FROM fedora:34
RUN dnf install -y git make gcc gcc-c++ which iproute iputils procps-ng vim-minimal tmux net-tools htop tar jq npm openssl-devel perl rust cargo golang

ADD https://github.com/Fantom-foundation/go-opera/archive/refs/tags/v1.1.0-rc.5.tar.gz /go-opera/
ENV GOPROXY="https://proxy.golang.org,direct"
RUN cd /go-opera && tar -xvf * && cd ./go-opera-1.1.0-rc.5 && make opera && mv ./build/opera /usr/bin/opera

Looking why default GOPROXY="direct" does not work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants