Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Version of Delve is too old for Go version 1.20.0 (maximum supported version 1.19)

When start debbugging session in GoLand I get this error:

WARNING: undefined behavior - version of Delve is too old for Go version 1.20.0 (maximum supported version 1.19)

I reinstall it with JetBrains Toolbox and didn't work. I uninstall it and install it manualy and didn't work!

The IDE maintainers say that GoLand didn't update delve when updating the IDE version in SOME CONDITIONS!

like image 518
Mohab Alnajjar Avatar asked Dec 01 '25 05:12

Mohab Alnajjar


2 Answers

I found this workaround from the official issue.

  1. Install dlv binary with go install github.com/go-delve/delve/cmd/dlv@latest
  2. Set the dlv.path=<path_to_dlv_executable> under Help > Edit Custom Properties
  3. Restart GoLand

It works for me.

like image 59
Sunjay Jeffrish Avatar answered Dec 04 '25 00:12

Sunjay Jeffrish


Firstly install the latest version of delve based on the instructions here, https://github.com/go-delve/delve/tree/master/Documentation/installation

# Install the latest release:
$ go install github.com/go-delve/delve/cmd/dlv@latest

After installing the latest version of dlv, identify the path of the dlv executable file,

which dlv
# Output: /Users/<username>/go/bin/dlv

In your debug console check for the path that is used for running dlv /Users/<username>/Library/Application Support/JetBrains/IntelliJIdea2022.1/plugins/go/lib/dlv/macarm/dlv

Goto to the above path and follow the below steps,

mv dlv dlv.old # If the dlv is present 
ln -s /Users/<username>/go/bin/dlv dlv

Now you can rerun the application and you should be able to get the debugger working.

like image 32
Tejash JL Avatar answered Dec 04 '25 02:12

Tejash JL



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!