Bug 1677746 - DNF can't resolve dependencies properly if RPMs conflict in module dependency
Summary: DNF can't resolve dependencies properly if RPMs conflict in module dependency
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: distribution
Version: 31
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Josh Boyer
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-02-15 18:52 UTC by Igor Raits
Modified: 2020-11-24 16:52 UTC (History)
15 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-11-24 16:52:38 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Igor Raits 2019-02-15 18:52:55 UTC
https://github.com/ignatenkobrain/dnf-modular-kkt#how-does-dnf-do-dependency-resolution-wron-for-modularity

We have test-app rpm which depends on kkt >= 50. And we have 2 kkt build versions: 30 and 80.

And they are packed into a modules as following:

* kkt:konsky:2019:deadbeef:x86_64
** Contains kkt-80-1.x86_64
* kkt:barani:2019:bbadbeef:x86_64
** Contains kkt-30-1.x86_64
* test-app:master:2019:deadbeef:x86_64:
** Contains test-app-1-1.x86_64
** Requires kkt: []

That means, if you would be about to install test-app, you would get test-app-1-1 and kkt-80-1… But not with DNF. What you will get is:

Error:
 Problem: package test-app-1-1.x86_64 requires kkt >= 50, but none of the providers can be installed
  - conflicting requests
  - package kkt-80-1.x86_64 is excluded

---

dnf-4.0.10-2.fc30.noarch

Comment 1 Marek Blaha 2019-02-18 16:20:00 UTC
Well, this behaviour is expected. Dnf has agreed with modularity team on this implementation, which requires more exact module requirements. So at the moment you (as a packager) should use particular streams as a modular dependency. That means:
* test-app:master
** Requires kkt: [konsky]
The other way is defining :konsky stream as a default stream of kkt module, but remember, that user can override repository defined module defaults by his own version.

You are right, there could be an alternative modularity implementation that behaves as you expected. But dnf went with excluding packages from non-enabled streams.

Comment 2 Igor Raits 2019-02-18 16:22:32 UTC
(In reply to Marek Blaha from comment #1)
> Well, this behaviour is expected. Dnf has agreed with modularity team on
> this implementation, which requires more exact module requirements. So at
> the moment you (as a packager) should use particular streams as a modular
> dependency. That means:
> * test-app:master
> ** Requires kkt: [konsky]
> The other way is defining :konsky stream as a default stream of kkt module,
> but remember, that user can override repository defined module defaults by
> his own version.
> 
> You are right, there could be an alternative modularity implementation that
> behaves as you expected. But dnf went with excluding packages from
> non-enabled streams.

But now imagine that both of streams satisfy dependency without any problems (since test-app would have just Requires: kkt, without versioned requires). And I have some RPM installed locally which has Conflicts: kkt < 50.

In this case, there **is** solution (just install different stream) but dnf would still blindly try to install conflicting package. And me, as maintainer of a module, I have no chance to prevent this.

Comment 3 Daniel Mach 2019-07-30 13:50:38 UTC
I believe that it's related to bug#1717117.
DNF implements the current modularity design which prohibits stream switching.
If the design changes, we'll also look into changing the code and DNF's behavior.

Comment 4 Igor Raits 2019-07-31 10:45:43 UTC
(In reply to Daniel Mach from comment #3)
> I believe that it's related to bug#1717117.
> DNF implements the current modularity design which prohibits stream
> switching.
> If the design changes, we'll also look into changing the code and DNF's
> behavior.

This has absolutely nothing to do with stream switching. This is INITIAL installation.

Comment 5 Ben Cotton 2019-08-13 17:12:41 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle.
Changing version to '31'.

Comment 6 Ben Cotton 2019-08-13 18:51:50 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle.
Changing version to 31.

Comment 7 Jaroslav Mracek 2019-09-07 15:13:49 UTC
I got an information that all issues related to modularity should be redirected to distribution component, changing component.

Enabling of non default stream automatically because installing package has unsatisfied dependency requires a change in design of modularity

Comment 8 Kevin Fenzi 2019-09-07 16:27:02 UTC
(In reply to Jaroslav Mracek from comment #7)
> I got an information that all issues related to modularity should be
> redirected to distribution component, changing component.

Oh? From whom? That seems like a bad idea as I'm not aware of any modularity folks watching distribution. 

Will see if I can come up with somthing better here.

Comment 9 Ben Cotton 2020-11-03 15:10:07 UTC
This message is a reminder that Fedora 31 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora 31 on 2020-11-24.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
Fedora 'version' of '31'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 31 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 10 Ben Cotton 2020-11-24 16:52:38 UTC
Fedora 31 changed to end-of-life (EOL) status on 2020-11-24. Fedora 31 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


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