gorgeous-winter-99296
01/29/2024, 9:35 PME Exception: Failed to compile main:
E open .go-1.21.6/src/internal/goarch/goarch.go: no such file or directory
With the command
E + exec .go-1.21.6/bin/go tool compile -buildid a717bf895dab0e5694d00390aa961411b8035d984aa5650934a87c42e83a3dcc -o __pkg__.a -pack -p internal/goarch -importcfg ./importcfg -lang go1.21 -std -+ -complete @__sources__.txt
I've never seen this error before, and the internet contains no traces of this specific issue either. The files definitely exist in the sandbox (๐งต), and the go environment looks kosher. Anyone got any ideas or leads? ๐gorgeous-winter-99296
01/29/2024, 9:35 PME + which go
E .go-1.21.6/bin/go
E + echo 'GOROOT: .go-1.21.6'
E GOROOT: .go-1.21.6
E + echo 'GOPATH: gopath'
E GOPATH: gopath
E + echo 'GOCACHE: cache'
E GOCACHE: cache
E + cat __sources__.txt
E .go-1.21.6/src/internal/goarch/goarch.go
E .go-1.21.6/src/internal/goarch/goarch_amd64.go
E .go-1.21.6/src/internal/goarch/zgoarch_amd64.go
E + go env --json
E {
E "AR": "ar",
E "CC": "gcc",
E "CGO_CFLAGS": "-O2 -g",
E "CGO_CPPFLAGS": "",
E "CGO_CXXFLAGS": "-O2 -g",
E "CGO_ENABLED": "1",
E "CGO_FFLAGS": "-O2 -g",
E "CGO_LDFLAGS": "-O2 -g",
E "CXX": "g++",
E "GCCGO": "gccgo",
E "GO111MODULE": "",
E "GOAMD64": "v1",
E "GOARCH": "amd64",
E "GOBIN": "",
E "GOCACHE": "cache",
E "GOENV": "",
E "GOEXE": "",
E "GOEXPERIMENT": "nocoverageredesign",
E "GOFLAGS": "",
E "GOGCCFLAGS": "-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=/tmp/go-build3969111599=/tmp/go-build -gno-record-gcc-switches",
E "GOHOSTARCH": "amd64",
E "GOHOSTOS": "linux",
E "GOINSECURE": "",
E "GOMOD": "/dev/null",
E "GOMODCACHE": "gopath/pkg/mod",
E "GONOPROXY": "",
E "GONOSUMDB": "",
E "GOOS": "linux",
E "GOPATH": "gopath",
E "GOPRIVATE": "",
E "GOPROXY": "off",
E "GOROOT": ".go-1.21.6",
E "GOSUMDB": "sum.golang.org",
E "GOTMPDIR": "",
E "GOTOOLCHAIN": "auto",
E "GOTOOLDIR": ".go-1.21.6/pkg/tool/linux_amd64",
E "GOVCS": "",
E "GOVERSION": "go1.21.6",
E "GOWORK": "",
E "PKG_CONFIG": "pkg-config"
E }
E + ls -al .go-1.21.6/src/internal/goarch/
E total 164
E drwxr-xr-x 2 ts ts 4096 Jan 29 22:31 .
E drwxr-xr-x 47 ts ts 4096 Jan 29 22:31 ..
E -rw-r--r-- 1 ts ts 1517 Jan 29 22:31 gengoarch.go
E -rw-r--r-- 1 ts ts 2157 Jan 29 22:31 goarch.go
<snip rest of files>
fast-nail-55400
01/29/2024, 9:48 PMfast-nail-55400
01/29/2024, 9:48 PMgorgeous-winter-99296
01/29/2024, 10:00 PMsandbox_root="$(/bin/pwd)"
GOROOT=${{sandbox_root}}/{goroot.path}
GOPATH=${{sandbox_root}}/gopath
GOCACHE=${{sandbox_root}}/cache
And all of them look like relative paths, even in go env
gorgeous-winter-99296
01/29/2024, 10:02 PMgorgeous-winter-99296
01/30/2024, 9:59 PM__SOURCES__
file contain(ed) absolute paths, so they pointed into another GOROOT. Now to fix the 10x slowdown caused by this... ๐gorgeous-winter-99296
01/30/2024, 10:16 PM