A few days ago, Fedora 42 was released, featuring DNF5 and GNOME 48. Among the most interesting features, GNOME now allows you to see how much time you've spent on your computer during the week, and application notifications are now grouped by application name.
In this article, I will explain how to upgrade Fedora 41 to 42, and what you should pay attention to before upgrading. I upgraded yesterday, and overall, the system works well. However, since the release happened very recently, not all GNOME extensions have been updated to version 48 yet, and at the time of writing this article, Moby hasn't released the Docker repository for the new version.
Table of Contents
Preparing to Upgrade Fedora
Before upgrading, several things need to be done. It's important to back up necessary files to another disk. Since there is a risk that something might go wrong and the system may not boot after the upgrade, you might need to reinstall it from scratch. Also, you need to verify that the extensions you use are supported in the new version, and update all packages in the system to their latest version.
1. Checking Extensions
You can check the versions of extensions using the Extension Manager application. If it's not installed yet, you can install it from the Flathub repository or in the Software Center. After that, launch the application and open the Upgrade Assistant from the menu:

The GNOME version to which we will upgrade is selected as 48. Now, just click the Check Compatibility button:

After that, the program will show which extensions are compatible with the new version and which are not:

2. Package Updates
To ensure a successful upgrade, you need to update all packages in the system to their latest version first. To do this, run:
sudo dnf upgrade --refresh

To confirm the upgrade, you will need to press y (yes). If package conflicts occur during the upgrade, such packages should be reinstalled using the reinstall command, and then the upgrade should be repeated. For example, if there is a problem with the systemd and systemd-udev packages:
sudo dnf reinstall --refresh systemd systemd-udev
After the upgrade, restart your computer.
Upgrading Fedora 41 to 42
1. Downloading Updates
To download all packages required for upgrading from Fedora 41 to 42, execute the following command:
sudo dnf system-upgrade download --releasever=42

This will take quite a long time since you need to download about 2 gigabytes of packages. If you have packages from third-party repositories that haven't been updated yet and other packages depend on them, you'll need to add the --allowerasing option to the system upgrade command, which will allow their removal:
sudo dnf system-upgrade download --releasever=42 --allowerasing
At the end of downloading updates, you will need to confirm adding OpenPGP keys for the new release to the system:

2. System Upgrade
After the updates are downloaded, you can proceed with their installation. It is important that during the upgrade the power supply remains stable and the computer does not shut down. Because if this happens, it may be quite difficult to recover the system. When everything is ready, execute the command:
sudo dnf system-upgrade reboot
The reboot needs to be confirmed by pressing y:

After this, the system will reboot and the upgrade screen will appear. This will again take quite a long time depending on your computer's performance. In my case, the upgrade took about 20 minutes:

After the upgrade, the system will reboot into the new version.
Checking the Version
You can verify that the upgrade was successful by checking the distribution version in the /etc/fedora-release file:
cat /etc/fedora-release

The entire upgrade took me about two hours, most of which was spent downloading and installing packages. However, this was considering that no serious issues occurred. If something goes wrong, it could take significantly longer.
Additional
Disabling GNOME Extensions Compatibility Check
If you have already upgraded and only now realized that some GNOME extensions you need are not supported, you can try to disable version compatibility checking. If the API required by the extensions hasn't changed, even incompatible extensions will work. To do this, execute the following command:
gsettings set org.gnome.shell disable-extension-version-validation true
It is important to re-enable verification later when extension developers release versions compatible with the new GNOME.
Network Issues in Docker
Since Fedora 42 doesn't have a Moby repository yet, dnf will install Docker from the official repositories. After installation, I encountered an issue where containers had no network connectivity. If you face the same problem, you should remove the Docker version from the Fedora repository, add the test repository from Moby, and install Docker from there. More details here.
Wrapping Up
In this article, we have covered how to upgrade Fedora to 42. The system is quite stable, although not all GNOME extensions are supported yet, so if you don't want to disable version verification, you might want to wait a few weeks or a month until everything works properly. If you find other issues and their solutions, please share them in the comments.