Bug 16149 - urpmi --downgrade manipulates installed-through-deps list, breaking orphan tracking
Summary: urpmi --downgrade manipulates installed-through-deps list, breaking orphan tr...
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 5
Hardware: All Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Thierry Vignaud
QA Contact:
URL:
Whiteboard: MGA4TOO
Keywords:
Depends on:
Blocks:
 
Reported: 2015-06-19 23:03 CEST by David Walser
Modified: 2015-09-04 17:47 CEST (History)
0 users

See Also:
Source RPM: urpmi-8.06-1.mga5.src.rpm
CVE:
Status comment:


Attachments
untested patch (646 bytes, patch)
2015-08-07 15:27 CEST, Thierry Vignaud
Details | Diff

Description David Walser 2015-06-19 23:03:50 CEST
When you downgrade a set of packages with urpmi --downgrade, your purpose is to downgrade those packages, not to mark them as specifically requested non-orphan packages.  Currently urpmi will treat this just as if you called urpmi normally on those packages, which is exactly the wrong thing to do in this case.  urpmi should not manipulate the installed-through-deps list when called with the --downgrade option.

Reproducible: 

Steps to Reproduce:
David Walser 2015-06-19 23:03:55 CEST

Whiteboard: (none) => MGA5TOO, MGA4TOO

Comment 1 Thierry Vignaud 2015-08-07 15:27:10 CEST
Created attachment 6915 [details]
untested patch
Comment 2 David Walser 2015-08-07 15:53:49 CEST
(In reply to Thierry Vignaud from comment #1)
> Created attachment 6915 [details]
> untested patch

It's perfect!  It looks correct, and I tested both cases, urpmi --downgrade on some packages I had updated to a local build of, which normally would have unmarked them as being auto-installed and it didn't do that, and I ran urpmi on a package that was auto-installed and it still unmarked it, as it should have.

Nice job :D  Thanks.
Comment 3 Thierry Vignaud 2015-08-31 13:09:52 CEST
Fixed in my local git

Status: NEW => RESOLVED
Resolution: (none) => FIXED

Thierry Vignaud 2015-08-31 13:10:01 CEST

Hardware: i586 => All

Comment 4 Mageia Robot 2015-08-31 19:28:38 CEST
commit 8116d24edf10c8f56355b7af592530a1a830b052
Author: Thierry Vignaud <thierry.vignaud@...>
Date:   Mon Aug 31 07:08:36 2015 -0400

    do not break orphan tracking when downgrading
    
    thus fixing unmarking packages as potential orphans when downgrading
    (mga#16149)
---
 Commit Link:
   http://gitweb.mageia.org/software/rpm/urpmi/commit/?id=8116d24edf10c8f56355b7af592530a1a830b052
Comment 5 David Walser 2015-08-31 22:35:08 CEST
Thanks.  Is the fix committed in the stable branches?

Status: RESOLVED => REOPENED
Version: Cauldron => 5
Resolution: FIXED => (none)
Whiteboard: MGA5TOO, MGA4TOO => MGA4TOO

Comment 6 Mageia Robot 2015-09-04 17:45:51 CEST
commit 243136c02999fb87dda04d2da9461253bd1fb782
Author: Thierry Vignaud <thierry.vignaud@...>
Date:   Mon Aug 31 07:08:36 2015 -0400

    do not break orphan tracking when downgrading
    
    thus fixing unmarking packages as potential orphans when downgrading
    (mga#16149)
---
 Commit Link:
   http://gitweb.mageia.org/software/rpm/urpmi/commit/?id=243136c02999fb87dda04d2da9461253bd1fb782
Comment 7 Thierry Vignaud 2015-09-04 17:47:29 CEST
No need to reopen bug for that...

Status: REOPENED => RESOLVED
Resolution: (none) => FIXED


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