Bug 1080837

Summary: [tracking] [rel-eng] use cases for depsolving
Product: [Fedora] Fedora Reporter: Daniel Mach <dmach>
Component: hawkeyAssignee: Packaging Maintenance Team <packaging-team-maint>
Status: CLOSED CANTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 22CC: jsilhan, jzeleny, packaging-team-maint, rholy
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-07-22 11:17:51 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 979353, 1049205, 1049209, 1173027, 1225501    
Bug Blocks: 578256    

Description Daniel Mach 2014-03-26 08:38:52 UTC
rel-eng use cases for depsolving

Depsolving for package installation and for composes is different.
All packages in a compose doesn't have to be installable at once for example.

We need following scenarios supported:


User defined arch for depsolving
--------------------------------
We need to do depsolving for any arch on a single host.
For example ppc64 on x86_64.
We don't install the packages, only use the package list to create repos.


Package conflicts
-----------------
Packages can conflict, but every single package has to be installable.
In other words:
 * install * may not always work
 * install <foo> works
   install <bar> works
   but install <foo> <bar> ends with a conflict


Unresolved dependencies
-----------------------
Composes can contain unresolved dependencies.
We need dnf/hawkey to return a reasonable package set even if all deps weren't met.


Greedy depsolving
-----------------
Install all possible packages providing a reldep.
Example:
 * Requires: MTA
   Installed deps: exim sendmail postfix opensmtpd (all providing MTA)

Comment 1 Ales Kozumplik 2014-03-26 10:29:27 UTC
Discussed this with Dan over IRC. The goal would be to provide this step by step, perhaps using this bugzilla as a tracking bug.

Comment 2 Ales Kozumplik 2014-03-27 13:07:59 UTC
(In reply to Daniel Mach from comment #0)
> Package conflicts
> -----------------
> Packages can conflict, but every single package has to be installable.
> In other words:
>  * install * may not always work
>  * install <foo> works
>    install <bar> works
>    but install <foo> <bar> ends with a conflict

This is already supported by creating one goal for each package and adding packages separately, then solving all the goals.

Comment 3 Ales Kozumplik 2014-03-27 13:10:09 UTC
(In reply to Daniel Mach from comment #0)
> Unresolved dependencies
> -----------------------
> Composes can contain unresolved dependencies.
> We need dnf/hawkey to return a reasonable package set even if all deps
> weren't met.

Dan please specify more, perhaps add an example: what is the input and what is the desired package set on the output? 

It would be best if this was filed as a separate bugzilla.

Comment 4 Ales Kozumplik 2014-03-27 13:11:16 UTC
(In reply to Daniel Mach from comment #0)
> Greedy depsolving
> -----------------
> Install all possible packages providing a reldep.
> Example:
>  * Requires: MTA
>    Installed deps: exim sendmail postfix opensmtpd (all providing MTA)

This is already doable by obtaining all pacakges providing 'MTA' and then filling a goal with them.

Comment 5 Ales Kozumplik 2014-03-27 13:14:04 UTC
(In reply to Daniel Mach from comment #0)
> User defined arch for depsolving
> --------------------------------
> We need to do depsolving for any arch on a single host.
> For example ppc64 on x86_64.
> We don't install the packages, only use the package list to create repos.
> 

This is already doable, e.g. on the x86_64 machine:

   sack = hawkey.Sack(arch='ppc64')

Comment 6 Jaroslav Reznik 2015-03-03 15:38:02 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 22 development cycle.
Changing version to '22'.

More information and reason for this action is here:
https://fedoraproject.org/wiki/Fedora_Program_Management/HouseKeeping/Fedora22

Comment 7 Honza Silhan 2015-07-22 11:17:51 UTC
rel-eng use case is different than regular DNF dependency solving. Now Pungi can run many DNF queries to fit their use case.