- What Grafana version and what operating system are you using?
(grafana) 11.1.0-pre (for darwin/arm64)
macos 14.3
go 1.22.2 (I had previously installed 1.11.x and tried to uninstall it using go docs but am not positive I deleted everything necessary bc there seemed to be some files under $HOME/go)
- What are you trying to achieve?
Trying to run the ‘make’ commands, I wanted to build grafana locally (on macos) in order to complete and test a pr (frontend)
- How are you trying to achieve it?
completed the steps documented on grafana/contribute/developer-guide.md at main · grafana/grafana · GitHub
(up through Build Grafana > Backend)
but these 2 commands fail with similar errors:
make lefthook-install
and
make run
- What happened?
this error occurs (for make run)
(re)installing /Users/carolchung/go/bin/bra-v0.0.0-20200517080246-1e3013ecaff8 build flag -mod=mod only valid when using modules make: *** [/Users/carolchung/go/bin/bra-v0.0.0-20200517080246-1e3013ecaff8] Error 1
also this error occurs (for make lefthook-install)
./scripts/cleanup-husky.sh
(re)installing /Users/carolchung/go/bin/lefthook-v1.4.8
build flag -mod=mod only valid when using modules
make: *** [/Users/carolchung/go/bin/lefthook-v1.4.8] Error 1
- What did you expect to happen?
I thought it should build and start running the server…
- Can you copy/paste the configuration(s) that you are having problems with?
I am wondering if there is an issue where my old installation of go was not cleaned up properly. I will paste the results of running go env below in case that is the issue. I tried to delete my ~HOME/go folder in case that was causing issues but the same errors seem to persist
GO111MODULE='off'
GOARCH='arm64'
GOBIN='/Users/carolc/go/bin'
GOCACHE='/Users/carolc/Library/Caches/go-build'
GOENV='/Users/carolc/Library/Application Support/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFLAGS=''
GOHOSTARCH='arm64'
GOHOSTOS='darwin'
GOINSECURE=''
GOMODCACHE='/Users/carolc/go/pkg/mod'
GONOPROXY=''
GONOSUMDB=''
GOOS='darwin'
GOPATH='/Users/carolc/go'
GOPRIVATE=''
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/usr/local/go'
GOSUMDB='sum.golang.org'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/usr/local/go/pkg/tool/darwin_arm64'
GOVCS=''
GOVERSION='go1.22.2'
GCCGO='gccgo'
AR='ar'
CC='clang'
CXX='clang++'
CGO_ENABLED='1'
GOMOD=''
GOWORK='/Users/carolc/programming_grafana/grafana/go.work'
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
PKG_CONFIG='pkg-config'
GOGCCFLAGS='-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -ffile-prefix-map=/var/folders/t1/t0wh31zd3cvfl8q6x5nxj6gm0000gn/T/go-build1003959801=/tmp/go-build -gno-record-gcc-switches -fno-common'
-
Did you receive any errors in the Grafana UI or in related logs? If so, please tell us exactly what they were.
-
Did you follow any online instructions? If so, what is the URL?