Bug 1349743 - 'dnf install @kde-desktop-environment' on Fedora 24 installs cinnamon (due to unfortunate imsettings deps / dnf behaviour)
Summary: 'dnf install @kde-desktop-environment' on Fedora 24 installs cinnamon (due to...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: comps
Version: 24
Hardware: x86_64
OS: Linux
urgent
medium
Target Milestone: ---
Assignee: Stephen Gallagher
QA Contact:
URL:
Whiteboard: https://fedoraproject.org/wiki/Common...
Depends On:
Blocks: 1192182
TreeView+ depends on / blocked
 
Reported: 2016-06-24 07:02 UTC by Adam Williamson
Modified: 2016-11-21 14:00 UTC (History)
25 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-11-21 14:00:27 UTC
Type: Bug


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1336879 0 medium CLOSED dnf fails to respect conditional level in comps.xml 2021-02-22 00:41:40 UTC

Internal Links: 1336879

Description Adam Williamson 2016-06-24 07:02:18 UTC
If you do a minimal install of Fedora 24 and then do 'dnf install @kde-desktop-environment', you get Plasma...and Cinnamon. (and somehow, Cinnamon becomes the default session).

This is, I think, ultimately due to imsettings' dependencies, and dnf's ambiguous dependency resolution behaviour (and possibly also https://bugzilla.redhat.com/show_bug.cgi?id=1336879 , about dnf ignoring 'conditional' entries in comps).

The kde-desktop-environment env group pulls in the 'input-methods' group. That group includes these 'default' entries:

      <packagereq type="default">ibus-libzhuyin</packagereq>
      <packagereq type="default">ibus-hangul</packagereq>
      <packagereq type="default">ibus-kkc</packagereq>
      <packagereq type="default">ibus-libpinyin</packagereq>
      <packagereq type="default">ibus-m17n</packagereq>
      <packagereq type="default">ibus-rawcode</packagereq>
      <packagereq type="default">ibus-typing-booster</packagereq>
      <packagereq type="default">im-chooser</packagereq>
      <packagereq type="default">imsettings</packagereq>

imsettings has a virtual dependency, imsettings-desktop-module(arch) , which is provided by various desktop / toolkit-specific packages:

imsettings-cinnamon-0:1.7.1-1.fc25.x86_64
imsettings-gsettings-0:1.7.1-1.fc25.x86_64
imsettings-lxde-0:1.7.1-1.fc25.x86_64
imsettings-mate-0:1.7.1-1.fc25.x86_64
imsettings-qt-0:1.7.1-1.fc25.x86_64
imsettings-xfce-0:1.7.1-1.fc25.x86_64

I think what's happening is that dnf is deciding to pull in imsettings-cinnamon to satisfy this dependency - even though it would surely be a smaller dep chain to install imsettings-qt when installing kde-desktop-environment. That's probably a case of #1192182 (the tracker for dnf making poor decisions about ambiguous dependencies like this).

It's also noteworthy that there are a bunch of 'conditional' entries in the input-methods group, including:

      <packagereq type="conditional" requires="qt">imsettings-qt</packagereq>

which might break the tie for imsettings-qt, if it was considered...but because of #1336879, it probably isn't.

Comment 1 Adam Williamson 2016-06-24 07:03:17 UTC
This is affecting openQA (by making Cinnamon the default session on the disk image which is supposed to be used for KDE upgrade testing).

Comment 2 Adam Williamson 2016-06-24 07:10:49 UTC
This actually affects network installs too: if you do a network install of Plasma, your default session will be Cinnamon.

Comment 3 Adam Williamson 2016-06-24 07:18:37 UTC
confirmed that if you do 'dnf install @kde-desktop-environment imsettings-qt' , you don't get Cinnamon installed, so it's definitely the imsettings dep that's the proximate cause here.

Comment 4 Stephen Gallagher 2016-06-24 15:35:44 UTC
Simple fix here would be to add "Suggests: imsettings-qt" to the `kf5-plasma` package. That would be enough to tell DNF to pull that one in, everything else being equal.

Comment 5 Adam Williamson 2016-06-24 15:37:35 UTC
Some other desktop environments that include the 'input-methods' group have gone with putting the correct provider in their 'foo-desktop' group to act as a clue, but the Suggests: sounds like a better idea (and easier to put in an F24 update)...

Comment 6 Rex Dieter 2016-06-24 15:38:21 UTC
I can implement comment #4 sure, though I think probably a better fit would be in plasma-workspace (rather than a kf5-plasma runtime pkg that could get pulled in elsewhere).

Comment 7 Stephen Gallagher 2016-06-24 15:40:01 UTC
(In reply to Rex Dieter from comment #6)
> I can implement comment #4 sure, though I think probably a better fit would
> be in plasma-workspace (rather than a kf5-plasma runtime pkg that could get
> pulled in elsewhere).

Ah, for some reason I thought kf5-plasma had Obsoleted plasma-workspace. So sure, wherever you think would be the best fit.

Comment 8 Rex Dieter 2016-06-24 15:51:31 UTC
Fwiw, comps also has a conditional in input-methods group:

      <packagereq type="conditional" requires="qt">imsettings-qt</packagereq>

but that may or may not matter here.

Comment 9 Fedora Update System 2016-06-24 18:00:14 UTC
plasma-workspace-5.6.5-2.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-87de75ef6b

Comment 10 Adam Williamson 2016-06-24 18:17:49 UTC
Rex: I mentioned that, and the reason why it doesn't help, in the original description.

Comment 11 MattK 2016-06-24 19:56:59 UTC
Similar problem when installing Xfce via "dnf install @xfce-desktop-environment"

http://forums.fedoraforum.org/showthread.php?t=310363

Comment 12 Kevin Fenzi 2016-06-24 20:11:14 UTC
Well, I could add a similar Suggests to an Xfce package... but I am not at all sure which one. 

And then do we need to do this for each of the other desktops too? :(

Comment 13 Adam Williamson 2016-06-25 00:57:20 UTC
Well, not all of them include input-methods , and some include the appropriate imsettings-(whatever) package in their desktop group, I presume to deal with this issue.

Comment 14 Fedora Update System 2016-06-25 17:44:13 UTC
xfce4-session-4.12.1-9.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-3ddc57115a

Comment 15 Fedora Update System 2016-06-26 00:26:20 UTC
xfce4-session-4.12.1-9.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-3ddc57115a

Comment 16 Fedora Update System 2016-06-26 00:27:10 UTC
plasma-workspace-5.6.5-2.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-87de75ef6b

Comment 17 Fedora Update System 2016-06-26 20:53:55 UTC
xfce4-session-4.12.1-9.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 18 Adam Williamson 2016-06-27 14:59:20 UTC
This bug is for KDE, not Xfce.

Comment 19 Wolfgang Ulbrich 2016-06-29 23:19:19 UTC
Looks like MATE is also affected.
Adding
Suggests: imsettings-mate
to mate-desktop package is sufficient?

Comment 20 Adam Williamson 2016-06-29 23:20:42 UTC
the plasma update is in testing, so setting ON_QA...

wolfgang: yup, the Suggests: seems to be the agreed-upon solution for now.

Comment 21 Fedora Update System 2016-06-30 00:28:16 UTC
mate-desktop-1.14.1-3.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-30c87948ea

Comment 22 Adam Williamson 2016-06-30 01:27:46 UTC
Can people ****PLEASE**** stop setting updates for other desktops as fixing this bug?! This bug is for *KDE*. Not for *ANY OTHER DESKTOP*. If you want to track fixing a similar issue for another desktop, please file another bug.

Comment 23 Wolfgang Ulbrich 2016-06-30 07:27:14 UTC
sorry, i removed the report at bodhi

Comment 24 Fedora Update System 2016-07-02 15:26:04 UTC
plasma-workspace-5.6.5-2.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 25 samoht0 2016-07-03 17:22:36 UTC
Not fixed for me with KDE netinstall including stable updates. Cinnamon came up as default DE. 'rpm -qa | grep -i "plasma-workspace"' showed that plasma-workspace-5.6.5-2.fc24 was present.

So I had no choice and used netinstall with release packages and updated later with dnf.

Comment 26 Marcel 2016-07-06 11:49:36 UTC
Confirming #25. This bug is not fixed yet.
I installed Fedora 24 with netinstall an hour ago and selected KDE as desktop environment. But it installed cinnamon as default desktop.

Comment 27 Rex Dieter 2016-07-06 12:01:27 UTC
Re: comment #25 and comment #26

So you can confirm that imsettings-cinnamon is still getting installed (instead of imsettings-qt) ?

If so, means that adding the
Suggests:       imsettings-qt
didn't help, a dnf issue?

Comment 28 samoht0 2016-07-06 17:34:08 UTC
(In reply to Rex Dieter from comment #27)
> Re: comment #25 and comment #26
> 
> So you can confirm that imsettings-cinnamon is still getting installed
> (instead of imsettings-qt) ?
> 
> If so, means that adding the
> Suggests:       imsettings-qt
> didn't help, a dnf issue?

Sadly, I can't. Did only check for plasma-workspace-5.6.5-2.fc24. Since the machine is now already setup and running nicely with proper package set, redoing the install is no adequate option. Sorry.

I used Fedora-Everything-netinst-x86_64-24-1.2.iso with applying updates at install.  

I also have to say, that in my opinion, this is not a package issue in the first place, but a DNF weakness. See:

https://bugzilla.redhat.com/show_bug.cgi?id=1192189

Comment 29 Marcel 2016-07-06 19:20:35 UTC
(In reply to Rex Dieter from comment #27)
> So you can confirm that imsettings-cinnamon is still getting installed
> (instead of imsettings-qt) ?

Confirming. The package imsettings-cinnamon did get installed, not imsettings-qt.

I've waited until today to make sure getting plasma-workspace-5.6.5-2.fc24 installed (it was pushed 4 days ago into stable repo).

Comment 30 Christian Dersch 2016-07-17 13:39:27 UTC
Also hit this issue with netinst and selected plasma today.

Comment 31 Marcel 2016-07-22 18:54:20 UTC
I currently tried again installing KDE without any "additional packages" (the ones you can select before the installation starts). This time it worked, F24 was installed without the Cinnamon desktop.
I'll further investigate by installing F24 with different configurations. Currently i believe the bug is caused either by another package that gets installed when selecting additional software, or the bug got fixed (unlikely, but possible)

(In reply to Christian Dersch from comment #30)
> Also hit this issue with netinst and selected plasma today.

Which additional software did you select when when installing Fedora 24?

Comment 32 samoht0 2016-07-23 08:49:01 UTC
@Marcel, FYI:
The bug is triggered when only KDE Apps + Admin-Tools are selected. So I guess: KDE Apps.

As I already told, install (including KDE Apps + Admin-Tools) works fine when using the release package set without updates.

Comment 33 Kevin Fenzi 2016-08-08 16:11:25 UTC
So, where are we here?

Suggests didn't actually work. :( 

Should we move this bug over to dnf and see if they have any recommendations?

Comment 34 Rex Dieter 2016-08-08 16:31:17 UTC
+1 => dnf

Comment 35 Robert Moskowitz 2016-08-08 16:33:43 UTC
See bug 1365222 for my Xfce desktop environment experience.

Comment 36 samoht0 2016-08-08 17:47:28 UTC
Yes, dnf.

Would be really interesting, *how* DNF does currently choose what packages to install, when some packages provide a dependency. Considering imsettings-xxx and kernel-debug-modules-extra/kernel-modules-extra (#1192189), I have some sense of foreboding, it's alphabetical order. Hope, I'm wrong.

Comment 37 Kevin Fenzi 2016-08-08 17:50:05 UTC
Moving to dnf maintainers for comment.

Comment 38 Adam Williamson 2016-08-08 17:59:39 UTC
https://fedoraproject.org/w/index.php?title=PackagingDrafts/ProvidesPreferences explicitly recommends Suggests/Enhances, it seems, so if that doesn't work it sounds like a libsolv bug...

I think the code is in https://github.com/openSUSE/libsolv/blob/master/src/rules.c somewhere, so, you know, good luck!

Comment 39 Igor Gnatenko 2016-08-11 00:00:44 UTC
*** Bug 1365222 has been marked as a duplicate of this bug. ***

Comment 40 Igor Gnatenko 2016-08-11 00:07:22 UTC
> reason imsettings-1.7.0-1.fc24.x86_64@fedora unit 208406134848ee1c45138e239e8e4191
> reason imsettings-1.7.1-1.fc24.x86_64@updates unit 9e8d083da747ffe9617c68ce94c41699
> reason imsettings-cinnamon-1.7.0-1.fc24.x86_64@fedora unit cbd5ebf8ab2709e5d1abab2dfda627ec
> reason imsettings-cinnamon-1.7.1-1.fc24.x86_64@updates resolve 4127a5d4e414af36538545e42d489ebe
> reason imsettings-gsettings-1.7.0-1.fc24.x86_64@fedora unit 311c5a8db6198eb81db075df75fe0967
> reason imsettings-libs-1.7.0-1.fc24.i686@fedora unit df0cffa5dd56b12f8f3c5e5a4c27048a
> reason imsettings-libs-1.7.0-1.fc24.x86_64@fedora unit 725ecc4641bccb2484c257facbd16c3f
> reason imsettings-libs-1.7.1-1.fc24.x86_64@updates unit 8b1ab7a740f1fc53310e0f149717914f
> reason imsettings-lxde-1.7.0-1.fc24.x86_64@fedora unit cb7cec519dae88b86cef9144561c9832
> reason imsettings-mate-1.7.0-1.fc24.x86_64@fedora unit fa76d159339a38d29a424fb225ba57e5
> reason imsettings-qt-1.7.0-1.fc24.x86_64@fedora unit cc88cbf5a064300d8ad34a86e0b883fa
> reason imsettings-xfce-1.7.0-1.fc24.x86_64@fedora unit 7f26d634fc143d2d8a6ecab1b812471b

weird, why it doesn't see 1.7.1 version for all others except imsettings-cinnamon.

Comment 41 Igor Gnatenko 2016-08-11 00:22:12 UTC
looks like libsolv found:
  - imsettings-cinnamon-1.7.1-1.fc24.x86_64
  - imsettings-gsettings-1.7.1-1.fc24.x86_64
  - imsettings-lxde-1.7.1-1.fc24.x86_64
  - imsettings-mate-1.7.1-1.fc24.x86_64
  - imsettings-qt-1.7.1-1.fc24.x86_64
  - imsettings-xfce-1.7.1-1.fc24.x86_64

so it tried to solve imsettings-cinnamon and it worked, so it didn't try to solve any other.

Michael, does it make sense for libsolv to check all branches and by default choose with minimal dependencies?

Kevin, Adam, others: this is easily solvable with suggests. Though not sure how it will work with comps ( we should really get rid out of it).

Comment 42 Igor Gnatenko 2016-08-11 00:25:24 UTC
(In reply to Rex Dieter from comment #27)
> Re: comment #25 and comment #26
> 
> So you can confirm that imsettings-cinnamon is still getting installed
> (instead of imsettings-qt) ?
> 
> If so, means that adding the
> Suggests:       imsettings-qt
> didn't help, a dnf issue?
those tags are not pulling into updates/updates-testing due to https://github.com/fedora-infra/bodhi/issues/875

Comment 43 Michael Schröder 2016-08-11 11:08:36 UTC
IMHO checking all branches does not make sense. I don't know of any good metric to compare branches, the number of packages doesn't seem very sensible. A package being split into many subpackages is not something bad per se. Installation size also doesn't make sense, more features mean a bigger size. But why go with the solution with the least features?

Note that libsolv *does* choose a different branch if it finds that it needs to install one of the other packages later.

Comment 44 Honza Silhan 2016-08-15 12:25:18 UTC
IMO It should be not be defined on package level by weak dependencies but rather in comps. "default" value of type is actually like Recommends, it gets pulled in if there's no conflict [1].

Is it possible to add into comps <packagereq type="default">... for each such package that should be pulled into transaction for specific group? If that package should be there anyway then it does not matter whether it is Recommended or Suggested.

[1] http://dnf.readthedocs.io/en/latest/command_ref.html?highlight=default#group-command-label

Comment 45 Stephen Gallagher 2016-08-15 12:37:53 UTC
(In reply to Jan Silhan from comment #44)
> IMO It should be not be defined on package level by weak dependencies but
> rather in comps. "default" value of type is actually like Recommends, it
> gets pulled in if there's no conflict [1].
> 
> Is it possible to add into comps <packagereq type="default">... for each
> such package that should be pulled into transaction for specific group? If
> that package should be there anyway then it does not matter whether it is
> Recommended or Suggested.
> 
> [1]
> http://dnf.readthedocs.io/en/latest/command_ref.html?highlight=default#group-
> command-label


Jan, as noted above: the real problem here is that libsolv is not behaving as explicitly documented. There is an explicit "Suggests: imsettings-qt" that is supposed to tell the depsolver that it should use this package to satisfy "imsettings-desktop-module(arch)". This is clearly written out in https://fedoraproject.org/w/index.php?title=PackagingDrafts/ProvidesPreferences that it should work this way. The fact that it does not /is a bug in libsolv/ that must be fixed.

Making changes to comps to work around libsolv bugs is a hack, not a solution. Please figure out why it's not behaving properly, since this will likely be an issue under other circumstances too.

Comment 46 Igor Gnatenko 2016-09-01 08:50:22 UTC
Stephen, this is bug in bodhi as it doesn't put weak deps into metadata.

Comment 47 Igor Gnatenko 2016-09-01 08:51:20 UTC
Anyway I think proper fix is anyway to put conditional requires to comps.

Comment 48 Randy Barlow 2016-09-01 16:29:28 UTC
There is an upstream Bodhi issue about weak deps missing:

https://github.com/fedora-infra/bodhi/issues/875

Comment 49 Kevin Fenzi 2016-09-01 20:35:12 UTC
Note that we will have weak deps in repodata when/if releng switches to using the fedora based bodhi-backend03 to push updates instead of 01 (rhel7). I can bring this up at our next meeting.

Comment 50 Kevin Fenzi 2016-09-05 03:49:08 UTC
ok, updates are now created on a Fedora-24 instance so they have weak deps. 

If someone could test the orig bug here and confirm it's fixed or not that would be great.

Comment 51 Kamil Páral 2016-11-21 14:00:27 UTC
I performed a netinstall of KDE (both pure KDE, and also KDE + KDE Apps + Admin Tools) for F24 and F25. In all cases I don't have imsettings-qt installed, but imsettings-cinnamon neither:

$ rpm -qa | grep imsett
imsettings-libs-1.7.2-1.fc25.x86_64
imsettings-gsettings-1.7.2-1.fc25.x86_64
imsettings-1.7.2-1.fc25.x86_64

However, in all cases I ended up with a KDE desktop, an no Cinnamon. So I think this is fixed.


Note You need to log in before you can comment on or make changes to this bug.