Port to new python-apt API

Bug #551510 reported by William Grant
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself
Fix Released
Low
Colin Watson

Bug Description

Once the DC is running Lucid, we should port Soyuz to the new python-apt API and remove the DeprecationWarning filter in silence_warnings() in lib/lp_site_customize.py.

Related branches

Changed in soyuz:
status: New → Triaged
importance: Undecided → Medium
tags: added: tech-debt
Revision history for this message
Robert Collins (lifeless) wrote :

said filter is gone. Can close?

Changed in launchpad:
status: Triaged → Incomplete
Curtis Hovey (sinzui)
Changed in launchpad:
status: Incomplete → Triaged
importance: Medium → Low
tags: added: trivial
description: updated
Revision history for this message
Colin Watson (cjwatson) wrote :

Said filter is still there:

    # XXX wgrant 2010-03-30 bug=551510:
    # Also filter apt_pkg warnings, since Lucid's python-apt has a new API.
    warnings.filterwarnings(
        'ignore', '.*apt_pkg.*', category=DeprecationWarning)

Revision history for this message
Colin Watson (cjwatson) wrote :

I started work on this. As the 'trivial' tag indicates, it's fairly mechanical.

The only part I think is non-obvious is that the new apt_pkg.parse_depends and apt_pkg.parse_src_depends interfaces have a slight difference in how they return strictly-less and strictly-greater dependencies, indicating these by '<' and '>' rather than '<<' and '>>'. Personally I think this is a misdesign in apt; if you actually try to use '<' and '>' in control files you get less-or-equal and greater-or-equal semantics respectively due to a very old design error in dpkg, which is why we have '<<' and '>>' in the first place, and it's better not to confuse the situation further by exposing these as '<' and '>'. Thus, I think the right thing to do here is to map these operators back to the versions used in control files. There are only three relevant call sites so this isn't hard.

Changed in launchpad:
assignee: nobody → Colin Watson (cjwatson)
status: Triaged → In Progress
Revision history for this message
Launchpad QA Bot (lpqabot) wrote :
tags: added: qa-needstesting
Changed in launchpad:
status: In Progress → Fix Committed
Colin Watson (cjwatson)
tags: added: qa-untestable
removed: qa-needstesting
Steve Kowalik (stevenk)
Changed in launchpad:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.