Bug 1203505 - dnf doesn't reliably clean requirements on remove
Summary: dnf doesn't reliably clean requirements on remove
Keywords:
Status: CLOSED DUPLICATE of bug 1154202
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf
Version: 21
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Packaging Maintenance Team
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-03-19 02:40 UTC by Christian Stadelmann
Modified: 2015-04-07 11:44 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-04-07 11:44:20 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
dnf's debugdata of running `dnf --debugsolver --verbose install 0ad` (7.69 MB, application/x-xz)
2015-03-19 02:40 UTC, Christian Stadelmann
no flags Details
dnf's debugdata of running `dnf --debugsolver --verbose remove mozjs31` (7.71 MB, application/x-xz)
2015-03-19 02:43 UTC, Christian Stadelmann
no flags Details
dnf's debugdata output of running `dnf --debugsolver --verbose autoerase` (11.29 MB, application/x-xz)
2015-03-19 02:45 UTC, Christian Stadelmann
no flags Details

Description Christian Stadelmann 2015-03-19 02:40:10 UTC
Created attachment 1003566 [details]
dnf's debugdata of running `dnf --debugsolver --verbose install 0ad`

Description of problem:
In some cases dnf doesn't reliably follow the preference `clean_requirements_on_remove=true` in /etc/dnf/dnf.conf

Version-Release number of selected component (if applicable):
dnf 0:0.6.4-1.fc21
libsolv 0:0.6.4-3.fc21

How reproducible:
depends very much on current state of the package database.

Steps to Reproduce:
1. run `dnf install 0ad` which drops in some dependencies, e.g. mozjs31 and 0ad-data
2. run `dnf remove mozjs31` (a dependency of 0ad) which will remove the 0ad package but not the 0ad-data package

Actual results:
0ad-data is not removed

Expected results:
0ad-data should be removed

Additional info:
the package nvidia-texture-tools was also installed automatically as requirement (dependency) of 0ad. It doesn't even show up in output of `dnf remove` or `dnf autoremove`.

Comment 1 Christian Stadelmann 2015-03-19 02:43:50 UTC
Created attachment 1003569 [details]
dnf's debugdata of running `dnf --debugsolver --verbose remove mozjs31`

Comment 2 Christian Stadelmann 2015-03-19 02:45:19 UTC
Created attachment 1003570 [details]
dnf's debugdata output of running `dnf --debugsolver --verbose autoerase`

Comment 3 Honza Silhan 2015-04-07 11:44:20 UTC
It should work in dnf-0.6.5 as expected.

# dnf install 0ad
...
Installing:
 0ad     x86_64 0.0.16-2.fc19  updates 2.9 M
 0ad-data
         noarch 0.0.16-1.fc19  updates 546 M
 enet    x86_64 1.3.7-1.fc19   fedora   30 k
 gloox   x86_64 1:1.0.3-1.fc19 updates 399 k
 miniupnpc
         x86_64 1.9-1.fc19     updates  42 k
 mozjs24 x86_64 24.2.0-3.fc19  updates 1.8 M
 nvidia-texture-tools
         x86_64 2.0.8-5.fc19   fedora  148 k

This removes the unneeded packages as you expect with clean_requirements_on_remove=true:
# dnf remove mozjs24
...
Removing:
 0ad     x86_64 0.0.16-2.fc19  @System 9.7 M
 0ad-data
         noarch 0.0.16-1.fc19  @System 1.3 G
 enet    x86_64 1.3.7-1.fc19   @System  51 k
 gloox   x86_64 1:1.0.3-1.fc19 @System 1.2 M
 hwdata  noarch 0.259-1.fc19   @System 4.4 M
 libjpeg-turbo
         x86_64 1.2.90-3.fc19  @System 344 k
 miniupnpc
         x86_64 1.9-1.fc19     @System 102 k
 mozjs24 x86_64 24.2.0-3.fc19  @System 5.7 M
 nvidia-texture-tools
         x86_64 2.0.8-5.fc19   @System 437 k
 pango   x86_64 1.34.1-2.fc19  @System 766 k

or remove mozjs24 wthout deps and run autoremove afterwards:
# dnf remove mozjs24 --setop=clean_requirements_on_remove=false
...
Removing:
 0ad     x86_64 0.0.16-2.fc19  @System 9.7 M
 mozjs24 x86_64 24.2.0-3.fc19  @System 5.7 M


# dnf autoremove
...
Removing:
 0ad-data
         noarch 0.0.16-1.fc19  @System 1.3 G
...
 enet    x86_64 1.3.7-1.fc19   @System  51 k
...
 gloox   x86_64 1:1.0.3-1.fc19 @System 1.2 M
...
 hwdata  noarch 0.259-1.fc19   @System 4.4 M
...
 libjpeg-turbo
         x86_64 1.2.90-3.fc19  @System 344 k
...
 miniupnpc
         x86_64 1.9-1.fc19     @System 102 k
...
 nvidia-texture-tools
         x86_64 2.0.8-5.fc19   @System 437 k
 pango   x86_64 1.34.1-2.fc19  @System 766 k
...

*** This bug has been marked as a duplicate of bug 1154202 ***


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