Description of problem: With en_US locale, everything works well (ignore the dep issue, that's not important): $ sudo dnf system-upgrade download --releasever=23 Last metadata expiration check performed 0:05:49 ago on Wed Nov 4 16:03:25 2015. Error: package smc-1.9-17.fc22.x86_64 requires libboost_filesystem.so.1.57.0()(64bit), but none of the providers can be installed (try to add '--allowerasing' to command line to replace conflicting packages) With zh_CN locale, the system-upgrade plugin is not found: $ LC_ALL=zh_CN.UTF-8 sudo dnf system-upgrade download --releasever=23 加载插件失败:system_upgrade 没有命令: system-upgrade。请使用 /bin/dnf --help 这可能是一个DNF插件的命令,请尝试:"dnf install 'dnf-command(system-upgrade)'" which translates to: Failed to load plugin: system_upgrade No command: system-upgrade. Use / bin / dnf --help This may be a DNF plug-in command, try: "dnf install 'dnf-command (system-upgrade)'" Other Chinese users see even tracebacks: 加载插件失败:system_upgrade Traceback (most recent call last): File "/bin/dnf", line 36, in <module> main.user_main(sys.argv[1:], exit_code=True) File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 198, in user_main errcode = main(args) File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 84, in main return _main(base, args) File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 117, in _main cli.configure(map(ucd, args)) File "/usr/lib/python2.7/site-packages/dnf/cli/cli.py", line 1006, in configure self.base.plugins.run_init(self.base, self) File "/usr/lib/python2.7/site-packages/dnf/plugin.py", line 104, in run_init plugin = p_cls(base, cli) File "/usr/lib/python2.7/site-packages/dnf-plugins/system_upgrade.py", line 359, in __init__ super(SystemUpgradePlugin, self).__init__(base, cli) TypeError: must be type, not None (The Chinese characters means ‘failed to load plugin’) See here: http://fedoramagazine.org/upgrading-from-fedora-22-to-fedora-23/#comment-449824 Version-Release number of selected component (if applicable): dnf-1.1.3-1.fc22.noarch dnf-conf-1.1.3-1.fc22.noarch dnf-plugins-core-0.1.13-1.fc22.noarch dnf-plugin-system-upgrade-0.7.0-1.fc22.noarch dnf-yum-1.1.3-1.fc22.noarch python2-dnf-plugin-system-upgrade-0.7.0-1.fc22.noarch python3-dnf-1.1.3-1.fc22.noarch python-dnf-1.1.3-1.fc22.noarch python-dnf-plugins-core-0.1.13-1.fc22.noarch python-dnf-plugins-extras-common-0.0.11-1.fc22.noarch python-dnf-plugins-extras-migrate-0.0.11-1.fc22.noarch
Adding wwoods into CC in case it's a bug in system-upgrade plugin somehow.
A workaround for this (not tested) could be: 1. See what your current locale is: $ locale 2. Switch system to English: $ sudo localectl set-locale LANG=en_US.UTF-8 3. Reboot, perform the upgrade. 4. Switch your system back to Chinese: $ sudo localectl set-locale LANG=YOUR_OLD_LOCALE 5. Reboot.
Also tracked in system-upgrade github: https://github.com/rpm-software-management/dnf-plugin-system-upgrade/issues/32
Hi, I was able to reproduce the traceback and it seems that jsilhan was right with blaming python. The whole issue is apparently caused by lines #368 and #369 containing: usage = dnf.i18n.ucd("[%s] [download --releasever=%s|reboot|clean|log]" % ( _("OPTIONS"), _("VERSION"))) After commenting out those lines the plugin run smoothly. Using python3 version of plugin can be considered as another workaround.
It can be also fixed by: usage = "[%s] [download --releasever=%s|reboot|clean|log]" % ( dnf.i18n.ucd(_("OPTIONS")), dnf.i18n.ucd(_("VERSION")))
Hmm. `dnf config-manager` will probably have the same problem, then, since AFAICT it's doing the same thing: usage = '[%s] [%s]' % (_('OPTIONS'), _('KEYWORDS')) See https://github.com/rpm-software-management/dnf-plugins-core/blob/dnf-plugins-core-0.1.13-1/plugins/config_manager.py#L49 I'm kind of confused about the root cause here, and the fact that we have to fix multiple plugins feels more like it's a bug in DNF (or, at least, something to add to the plugin docs, i.e. that the 'usage' property has to be the same type as.. whatever the return value of dnf.i18n._() is.) Anyway, I should have a patch for this shortly.
It's not a bug in DNF but Python 2 stuff that cannot handle concatenate different types of strings properly. If it would require fix on may places we can add proper gettext initialization in DNF [1]. [1] https://github.com/rpm-software-management/dnf/pull/375
This commit should fix things for now: https://github.com/rpm-software-management/dnf-plugin-system-upgrade/commit/8430636 I can prepare a patch that uses dnf.i18n.translation once that lands in upstream dnf. Expect dnf-plugin-system-upgrade 0.5.1/0.7.1 to arrive soon..ish.
I cavalierly ignored comment 2 and just ran: $ LANG=C sudo dnf system-upgrade download --releasever=23 $ LANG=C sudo dnf system-upgrade reboot Not only did it fail to upgrade - it also no longer boots and I don't know how to fix it. (Not sure if the old F21 rescue target boot target was still working.) eg localectl in the rescue environment complains it can't connect to dbus. (What could possibly go wrong...;)
(In reply to Jens Petersen from comment #9) > I cavalierly ignored comment 2 and just ran: > > $ LANG=C sudo dnf system-upgrade download --releasever=23 > $ LANG=C sudo dnf system-upgrade reboot > > Not only did it fail to upgrade - it also no longer boots and I don't know > how to fix it. (Not sure if the old F21 rescue target boot target was still > working.) Until dnf-plugin-system-upgrade-0.7.1 is released, you could probably work around this one of two ways: 1) Abort the upgrade See the directions here: https://github.com/rpm-software-management/dnf-plugin-system-upgrade#in-case-of-boot-problems 2) Make the upgrade also use LANG=C Follow the directions above, but instead of removing /sysroot/system-update, add the following line to /lib/systemd/system/dnf-system-upgrade.service: Environment=LANG=C Once you exit the emergency shell, the upgrade *should* start normally.
dnf-plugins-core-0.1.14-1.fc23 dnf-1.1.4-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2015-fe6e8b885b
I'd like to confirm that switching to locale "en_US" as comment 2 suggests will work flawlessly with the system upgrade from f21 to f23. Using Lang=C failed as with comment 9. I failed with de_DE locale..... (I did this comment for those still with f21 (or f22) and didn't get the update (yet))
(In reply to Fedora Update System from comment #11) > dnf-plugins-core-0.1.14-1.fc23 dnf-1.1.4-1.fc23 has been submitted as an > update to Fedora 23. > https://bodhi.fedoraproject.org/updates/FEDORA-2015-fe6e8b885b I tried to install this update onto F22, and the problem persists. Before, I received this error (translated from Chinese): Failed to load plugin: system_upgrade No command: system-upgrade. Use / bin / dnf --help This may be a DNF plug-in command, try: "dnf install 'dnf-command (system-upgrade)'" With the update, I receive this (note the missing first line): No command: system-upgrade. Use / bin / dnf --help This may be a DNF plug-in command, try: "dnf install 'dnf-command (system-upgrade)'" But it might be caused by package version mismatch? Please provide a F22 build to test this.
*** Bug 1279217 has been marked as a duplicate of this bug. ***
dnf-1.1.4-1.fc22 dnf-plugins-core-0.1.14-1.fc22 has been submitted as an update to Fedora 22. https://bodhi.fedoraproject.org/updates/FEDORA-2015-6137119aff
dnf-1.1.4-1.fc23, dnf-plugins-core-0.1.14-1.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with $ su -c 'dnf --enablerepo=updates-testing update dnf dnf-plugins-core' You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-fe6e8b885b
(In reply to Fedora Update System from comment #15) > dnf-1.1.4-1.fc22 dnf-plugins-core-0.1.14-1.fc22 has been submitted as an > update to Fedora 22. > https://bodhi.fedoraproject.org/updates/FEDORA-2015-6137119aff This does not fix this bug. Are system-upgrade changes needed as well?
dnf-1.1.4-1.fc23, dnf-plugins-core-0.1.14-1.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.
dnf-1.1.4-1.fc22, dnf-plugins-core-0.1.14-1.fc22 has been pushed to the Fedora 22 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with $ su -c 'dnf --enablerepo=updates-testing update dnf-plugins-core dnf' You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-6137119aff
The changes were made in dnf [1] and in system-upgrade plugin [2]. I unreferenced this BZ from bodhi update. [1] https://github.com/rpm-software-management/dnf/commit/a4df4849f412b9f03e6e18b52996134a5267c0cd [2] https://github.com/rpm-software-management/dnf-plugin-system-upgrade/commit/4bbbf1ec0c3f387249d30dd103ff4d002c17f574
OK, thanks. Waiting for a new system-upgrade version...
dnf-plugin-system-upgrade-0.7.1-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2015-45efbec1fe
dnf-plugin-system-upgrade-0.7.1-1.fc22 has been submitted as an update to Fedora 22. https://bodhi.fedoraproject.org/updates/FEDORA-2015-6b41346335
This fixes the problem for F22. But we have left the Chinese/Japanese/other users of F21 stranded, because we can no longer push a fix there. Their only choice is to do the workaround - switch system language to English (or other working language), perform the upgrade, and switch it back.
dnf-plugin-system-upgrade-0.7.1-1.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with $ su -c 'dnf --enablerepo=updates-testing update dnf-plugin-system-upgrade' You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-45efbec1fe
dnf-plugin-system-upgrade-0.7.1-1.fc22 has been pushed to the Fedora 22 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with $ su -c 'dnf --enablerepo=updates-testing update dnf-plugin-system-upgrade' You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-6b41346335
dnf-plugin-system-upgrade-0.7.1-1.fc22 has been pushed to the Fedora 22 stable repository. If problems still persist, please make note of it in this bug report.
dnf-plugin-system-upgrade-0.7.1-1.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.