Upgrade to 4.3, error during 3rd stage, protected package dnf

At the end of stage 3 of the upgrade script from version 4.2 to 4.3, the following error is reported:

Error:
Problem: The operation would result in removing the following protected packages: dnf

The command I entered that caused the error is as follows:

sudo qubes-dist-upgrade --releasever=4.3 --dist-upgrade

I have tried all the suggestions in this thread:
https://forum.qubes-os.org/t/qubes-dist-upgrade-script-error-4-3-rc-2/36435
and always get the same error. I also tried these commands:

sudo dnf remove --duplicates --releasever=41 --setopt protected_packages=
sudo dnf distro-sync --refresh --releasever=41 --setopt protected_packages=

But nothing. The error persists.
I use 6.17.9-1.fc37 kernel, I don’t know if that has anything to do with it.

Thank you!

When entering the command:

rpm -qa | grep fc41

it appears that the only packages updated to version 2 are the following:

glibc-all-langpacks-2.40.28.fc41.x86_64
glibc-common-2.40.28.fc41.x86_64
glibc-gconv-extra-2.40.28.fc41.x86_64
glibc-2.40.28.fc41.x86_64

all others are still at version fc37

All commands that operate with dnf, launched outside the script, produce positive results ‘all done’, such as:

sudo dnf upgrade --allowerasing --releasever=41 --setopt=protected_packages=,

Does anyone have any idea what the problem might be?

Thanks

The script said to replace the xscreensaver-base package with the xfce4-screensaver package.
But when I gave the command:

rpm -qa | grep screensaver

I saw that the package had not been replaced. So I gave the command:

sudo dnf swap --allowerasing xscreensaver-base xfce4-screensaver

and the replacement was successful.
Now the script continues, but it gives me another error (in addition to the previous one, which remains):

Errors during downloading metadata for repository 'qubes-dom0-cached':
- Curl error (37): Couldn't read a file:// file for file:///var/lib/qubes/updates/repodata/repomd.xml [Couldn't open file /var/lib/qubes/updates/repodata/repomd.xml]
Error: Failed to download metadata for repo 'qubes-dom0-cached': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried
Ignored repositories: qubes-dom0-cached
Package xfce4-screensaver-4.18.4-4.fc41.x86_64 is installed.
Dependencies resolved.
No action required.
Done!

The script then continues by attempting to perform distro-sync, and the same error appears here:

Error:
Problem: The operation would result in removing the following protected packages: dnf

Have you tried updating the whonix template PGP key?

Hi,
I recently had the same problem.
The solution is to change UpdateVM from “sys-whonix” to “sys-firewall” when performing updates.

Press Start, then “Qubes global config,” go to the ‘updates’ tab, and change the Dom0 update proxy from “sys-whonix” to “sys-firewall” for the duration of the system update.
Run the distro update commands again, and everything should work correctly.

After completing all stages of the distribution update, install Whonix18 using “Qubes-template-manager” and replace the “sys-whonix” template from ‘whonix17’ to “whonix18”.
Then:
Press Start, then “Qubes global config”, go to the ‘updates’ tab and change the Dom0 update proxy from “sys-firewall” to “sys-whonix” for the duration of the system update.