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

'make contract' command fails #3

Open
savvysiddharth opened this issue Feb 24, 2022 · 2 comments
Open

'make contract' command fails #3

savvysiddharth opened this issue Feb 24, 2022 · 2 comments

Comments

@savvysiddharth
Copy link

I'm trying to run this code locally on my machine. I followed instructions from Docs.
Though chainspace is installed as I'm able to run chainspace genload command successfully, but make contract fails with this error: go: go.mod file not found in current directory or any parent directory; see 'go help modules'

Adding screenshot for reference
image

@savvysiddharth
Copy link
Author

savvysiddharth commented Feb 24, 2022

Modified ./chainspace-go/dummycontract/Dockerfile

FROM golang:alpine AS build

COPY . /go/src/chainspace.io/dummychecker
WORKDIR /go/src/chainspace.io/dummychecker
ADD . .
RUN go mod init
RUN CGO_ENABLED=0 GOOS=linux go build -a -tags netgo -ldflags '-w'

FROM scratch

COPY --from=build /go/src/chainspace.io/dummychecker/dummychecker /dummychecker

ENTRYPOINT ["/dummychecker"]

I added ADD . . and RUN go mod init before the RUN CGO_.. line and go.mod is not issue anymore, but it throws another error: go install: version is required when current directory is not in a module

Attaching screenshot for reference:
image

Using @latest suffix didn't help, as it threw another error as follows:

image

@savvysiddharth savvysiddharth changed the title "make contract" command fails 'make contract' command fails Feb 26, 2022
@gdanezis
Copy link

Hey -- no one is maintaining this code since the chainspace team joined Novi / FB back in Feb 3, 2019 :(

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

2 participants