Golang 1.22?

Hello! I am using Fedora 39 (Cinnamon) and it seems that Go is still version 1.21. Is there a time estimate for when Go 1.22 will arrive to dnf? (or is it there and I missed it?)

Thank you for your part in making this great OS!

You can see the state of builds for a package on Koji.

Here is the page for golang golang | Package Info | koji
It shows that 1.22 is built for f40.

I assume that is because this is a imporant change and only happens at a fedora upgrade point as it must not break existing projects.

I don’t think go will be upgraded for fedora 39. It is an important change and 1.21 will still be supported for some time.

If you want to use go 1.22 on fedora 39 it isn’t a problem though. As a silverblue user I am using mise to install go 1.22. Mise is used to install multiple versions of software development kits next to each other, and it uses it’s own repository. Might be a bit much if you only need a newer version but it is an option. I really like this tool, but sadly also have to use multiple versions of SDKs simultaneously.

Another alternative would be using the flatpak SDK, but this will require using a flatpak IDE and running go inside flatpak. This would be quite a different workflow, but it has it’s benefits.

1 Like

if its such a big issue I recommend using a tool like distrobox+podman to set up a fedora 40 development environment.

like this:

$ distrobox create -n f40 -i registry.fedoraproject.org/fedora-toolbox:40
$ distrobox enter -n f40
$ sudo dnf install golang 

Alternatively you can use the traditional method of downloading the go tar file from the official website, shoving it somewhere and sourcing it. You can follow the guide here but I do recommend changing the directory something your user can write to. Download and install - The Go Programming Language . Maybe ~/.local/share/ ?

A third option is to use the @go-sig COPR repository for go: https://copr.fedorainfracloud.org/coprs/g/go-sig/golang-rawhide/.

As noted in the description - this is use at your own risk. DNF makes it fairly straightforward to roll back if needed.

Thanks everyone! Appreciate your responses.
I didn’t realize it was waiting for Fedora 40.
I like the rawhide version idea because it integrates with DNF.
Downloading the official release is also an option.