MrFox
(Adam Fox)
March 29, 2023, 10:13am
1
So, here’s a strange one. I treated myself to a new PC, i9 13th gen, lotsa RAM, fast M2 drive…
Reinstalled everything from scratch. Win10, VS2022 (I’m a C# dev by day) and VSCode (I’m working on a Go project by night…)
When I came to install Go, it seemed fine. Installed from go1.20.2.windows-amd64 download, all good.
But when I installed the Go plugin on VSCode it blue screened when it tried to install delve.
Now whenever I run VSCode and try to use Go plugin, BSOD.
I tried installing delve manually, but got errors which I raised with the delve team
opened 04:02PM - 28 Mar 23 UTC
closed 05:56PM - 28 Mar 23 UTC
Hi all, probably doing something stupid, but this is what I tried:
1. What v… ersion of Delve are you using (`dlv version`)? 1.20.1
`go install github.com/go-delve/delve/cmd/dlv@latest`
2. What version of Go are you using? (`go version`)?
ran the file : go1.20.2.windows-amd64
Checked version:
```
go version
go version go1.20.2 windows/amd64
```
I wonder, is amd64 compatible with Intel i9????
3. What operating system and processor architecture are you using?
New build i9 13900K Windows 10: 10.0.19045
32GB RAM, tons of hard drive space.
This is a new PC and hasn't had GO installed on it before.
4. What did you do?
```
go clean -modcache
go install github.com/go-delve/delve/cmd/dlv@latest
```
5. What did you expect to see?
Install OK of delve
6. What did you see instead?
could not import internal/goarch (EOF) and various others...
```
go: downloading github.com/go-delve/delve v1.20.1
go: downloading github.com/sirupsen/logrus v1.6.0
go: downloading github.com/spf13/cobra v1.1.3
go: downloading github.com/google/go-dap v0.6.0
go: downloading github.com/mattn/go-isatty v0.0.3
go: downloading gopkg.in/yaml.v2 v2.4.0
go: downloading github.com/cosiner/argv v0.1.0
go: downloading github.com/go-delve/liner v1.2.3-0.20220127212407-d32d89dd2a5d
go: downloading github.com/mattn/go-colorable v0.0.9
go: downloading github.com/derekparker/trie v0.0.0-20200317170641-1fdf38b7b0e9
go: downloading golang.org/x/sys v0.0.0-20220908164124-27713097b956
go: downloading golang.org/x/arch v0.0.0-20190927153633-4e8777c89be4
go: downloading github.com/hashicorp/golang-lru v0.5.4
go: downloading go.starlark.net v0.0.0-20220816155156-cfacd8902214
go: downloading github.com/cilium/ebpf v0.7.0
go: downloading github.com/spf13/pflag v1.0.5
go: downloading github.com/cpuguy83/go-md2man/v2 v2.0.0
go: downloading github.com/inconshreveable/mousetrap v1.0.0
go: downloading github.com/mattn/go-runewidth v0.0.13
go: downloading github.com/konsorten/go-windows-terminal-sequences v1.0.3
go: downloading github.com/russross/blackfriday/v2 v2.0.1
go: downloading github.com/rivo/uniseg v0.2.0
go: downloading github.com/shurcooL/sanitized_anchor_name v1.0.0
# runtime/internal/math
C:\Program Files\Go\src\runtime\internal\math\math.go:7:8: could not import internal/goarch (EOF)
# runtime/internal/sys
C:\Program Files\Go\src\runtime\internal\sys\consts.go:8:2: could not import internal/goarch (EOF)
C:\Program Files\Go\src\runtime\internal\sys\consts.go:9:2: could not import internal/goos (EOF)
# github.com/shurcooL/sanitized_anchor_name
go\pkg\mod\github.com\shurcoo!l\sanitized_anchor_name@v1.0.0\main.go:10:8: could not import unicode (EOF)
# github.com/rivo/uniseg
go\pkg\mod\github.com\rivo\uniseg@v0.2.0\grapheme.go:3:8: could not import unicode/utf8 (EOF)
# internal/abi
C:\Program Files\Go\src\internal\abi\abi.go:8:2: could not import internal/goarch (EOF)
# internal/bytealg
C:\Program Files\Go\src\internal\bytealg\bytealg.go:8:2: could not import internal/cpu (EOF)
# math
C:\Program Files\Go\src\math\exp_amd64.go:9:8: could not import internal/cpu (EOF)
C:\Program Files\Go\src\math\fma.go:7:8: could not import math/bits (EOF)
```
And then with the Go team
opened 04:49PM - 28 Mar 23 UTC
closed 05:34PM - 28 Mar 23 UTC
I raised this on the delve help forum
https://github.com/go-delve/delve/issues… /3317
and they redirected me here
Hi all, probably doing something stupid, but this is what I tried:
### What version of Go are you using (`go version`)?
```
go version
go version go1.20.2 windows/amd64
```
### Does this issue reproduce with the latest release?
Yes
### What operating system and processor architecture are you using (`go env`)?
New build i9 13900K Windows 10: 10.0.19045
32GB RAM, tons of hard drive space.
This is a new PC and hasn't had GO installed on it before.
<details><summary><code>go env</code> Output</summary><br><pre>
go env
set GO111MODULE=
set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\conta\AppData\Local\go-build
set GOENV=C:\Users\conta\AppData\Roaming\go\env
set GOEXE=.exe
set GOEXPERIMENT=
set GOFLAGS=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOINSECURE=
set GOMODCACHE=C:\Users\conta\go\pkg\mod
set GONOPROXY=
set GONOSUMDB=
set GOOS=windows
set GOPATH=C:\Users\conta\go
set GOPRIVATE=
set GOPROXY=https://proxy.golang.org,direct
set GOROOT=C:\Program Files\Go
set GOSUMDB=sum.golang.org
set GOTMPDIR=
set GOTOOLDIR=C:\Program Files\Go\pkg\tool\windows_amd64
set GOVCS=
set GOVERSION=go1.20.2
set GCCGO=gccgo
set GOAMD64=v1
set AR=ar
set CC=gcc
set CXX=g++
set CGO_ENABLED=0
set GOMOD=NUL
set GOWORK=
set CGO_CFLAGS=-O2 -g
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-O2 -g
set CGO_FFLAGS=-O2 -g
set CGO_LDFLAGS=-O2 -g
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -fno-caret-diagnostics -Qunused-arguments -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=C:\Users\conta\AppData\Local\Temp\go-build2941949347=/tmp/go-build -gno-record-gcc-switches
</pre></details>
### What did you do?
Ran the installer go1.20.2.windows-amd64
Checked version:
```
go version
go version go1.20.2 windows/amd64
```
Tried to install delve
```
go clean -modcache
go install github.com/go-delve/delve/cmd/dlv@latest
```
### What did you expect to see?
Delve install OK
### What did you see instead?
could not import internal/goarch (EOF) and various others...
```
go: downloading github.com/go-delve/delve v1.20.1
go: downloading github.com/sirupsen/logrus v1.6.0
go: downloading github.com/spf13/cobra v1.1.3
go: downloading github.com/google/go-dap v0.6.0
go: downloading github.com/mattn/go-isatty v0.0.3
go: downloading gopkg.in/yaml.v2 v2.4.0
go: downloading github.com/cosiner/argv v0.1.0
go: downloading github.com/go-delve/liner v1.2.3-0.20220127212407-d32d89dd2a5d
go: downloading github.com/mattn/go-colorable v0.0.9
go: downloading github.com/derekparker/trie v0.0.0-20200317170641-1fdf38b7b0e9
go: downloading golang.org/x/sys v0.0.0-20220908164124-27713097b956
go: downloading golang.org/x/arch v0.0.0-20190927153633-4e8777c89be4
go: downloading github.com/hashicorp/golang-lru v0.5.4
go: downloading go.starlark.net v0.0.0-20220816155156-cfacd8902214
go: downloading github.com/cilium/ebpf v0.7.0
go: downloading github.com/spf13/pflag v1.0.5
go: downloading github.com/cpuguy83/go-md2man/v2 v2.0.0
go: downloading github.com/inconshreveable/mousetrap v1.0.0
go: downloading github.com/mattn/go-runewidth v0.0.13
go: downloading github.com/konsorten/go-windows-terminal-sequences v1.0.3
go: downloading github.com/russross/blackfriday/v2 v2.0.1
go: downloading github.com/rivo/uniseg v0.2.0
go: downloading github.com/shurcooL/sanitized_anchor_name v1.0.0
# runtime/internal/math
C:\Program Files\Go\src\runtime\internal\math\math.go:7:8: could not import internal/goarch (EOF)
# runtime/internal/sys
C:\Program Files\Go\src\runtime\internal\sys\consts.go:8:2: could not import internal/goarch (EOF)
C:\Program Files\Go\src\runtime\internal\sys\consts.go:9:2: could not import internal/goos (EOF)
# github.com/shurcooL/sanitized_anchor_name
go\pkg\mod\github.com\shurcoo!l\sanitized_anchor_name@v1.0.0\main.go:10:8: could not import unicode (EOF)
# github.com/rivo/uniseg
go\pkg\mod\github.com\rivo\uniseg@v0.2.0\grapheme.go:3:8: could not import unicode/utf8 (EOF)
# internal/abi
C:\Program Files\Go\src\internal\abi\abi.go:8:2: could not import internal/goarch (EOF)
# internal/bytealg
C:\Program Files\Go\src\internal\bytealg\bytealg.go:8:2: could not import internal/cpu (EOF)
# math
C:\Program Files\Go\src\math\exp_amd64.go:9:8: could not import internal/cpu (EOF)
C:\Program Files\Go\src\math\fma.go:7:8: could not import math/bits (EOF)
```
Both tickets have been closed. So no help there.
Other than ‘looks like a corrupt installation of go’
But it’s a fresh install… I downloaded the file again, reinstalled, same.
When I install go 18.5.0, all is fine. Except it doesn’'t play well with VSCode because VSCode wants the latest…
Any ideas?
I’m currently doing Go coding on my laptop, which is a pain.
skillian
(Sean Killian)
March 31, 2023, 3:14pm
2
MrFox:
I treated myself to a new PC, i9 13th gen, lotsa RAM, fast M2 drive…
Reinstalled everything from scratch. Win10, VS2022 (I’m a C# dev by day) and VSCode (I’m working on a Go project by night…)
Are you me? I have a similar setup but I usually program in Go on my laptop, and haven’t used VSCode and Go on my desktop in a while. I think I still have 1.18 or 1.19 on there. I’ll try out 1.20.2 when I get home from my C# job later today!
MrFox
(Adam Fox)
March 31, 2023, 3:37pm
3
Well. I just installed go v18.5.0 manually, then ran latest VSCode. No BSOD. Installed pls v.0.9.1 manually. Tadaa. Can now debug go.
If anyone else runs into this issue, just install an older version manually. Hopefully when 21 or 22 come out it will have fixed itself…
Thank you @skillian for spurring me into trying again. Tadaa!
1 Like