[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: python-apt and downgrades



On Wed, Oct 30, 2019 at 11:51:38AM +0100, Julian Andres Klode wrote:
> On Wed, Oct 23, 2019 at 11:58:04AM +0100, Stephen Quinney wrote:
> > I'm fairly new to using the apt python modules and I'm really hoping
> > someone can help me with a script I need for downgrading packages.
> >
> > ...
> > 
> >     if best_match is not None and best_match != pkg.current_ver:
> >         depcache.mark_install(pkg)
> >         depcache.set_candidate_ver(pkg,best_match)
> 
> These lines need to be swapped.
> 

It works! Thank you so much!

As a recent convert to this module I'd just like to say a big thanks
for all your hard work. I'm in the middle of porting lots of config
management scripts from RHEL to Debian and the python-apt modules have
made that a much easier job than I thought it would be.


Stephen

-- 
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.


Reply to: