After upgrading to an Apple Silicon MacBook Pro and migrating using Migration Assistant, I've been working through various issue getting Homebrew converted to ARM from Intel binaries.
One problem I'm experiencing is editing Go programs in VSCode. It's constantly showing the error message Error: Error: spawn Unknown system error -86.
I've un-installed and re-installed the Go extension with no improvement. I can compile and run go programs from the terminal. I tried setting some env variables in settings.json with no luck. E.g.,
"go.goroot": "/opt/homebrew/Cellar/go/1.22.1/libexec",
"go.toolsEnvVars": {
"GOPATH": "/Users/my_username/go"
},
Any ideas on what to try next or how to get more debug info?
Edit:
I was able to get this output from Extension Host:
2024-03-15 12:12:48.989 [info] ExtensionService#_doActivateExtension golang.go, startup: false, activationEvent: 'onLanguage:go'
2024-03-15 12:19:18.256 [error] TypeError: a.getTime is not a function
at msBetween (/Users/my_username/.vscode-insiders/extensions/golang.go-0.41.2/dist/goMain.js:29032:21)
at daysBetween (/Users/my_username/.vscode-insiders/extensions/golang.go-0.41.2/dist/goMain.js:29026:10)
at TelemetryService.promptForTelemetry (/Users/my_username/.vscode-insiders/extensions/golang.go-0.41.2/dist/goMain.js:30472:9)
at Timeout.callback [as _onTimeout] (/Users/my_username/.vscode-insiders/extensions/golang.go-0.41.2/dist/goMain.js:30335:58)
at listOnTimeout (node:internal/timers:569:17)
at processTimers (node:internal/timers:512:7)