Merge lp://staging/~ursinha/ubuntu-dev-tools/fix_getBinaryPackage into lp://staging/~ubuntu-dev/ubuntu-dev-tools/trunk

Proposed by Ursula Junque
Status: Merged
Merged at revision: 1459
Proposed branch: lp://staging/~ursinha/ubuntu-dev-tools/fix_getBinaryPackage
Merge into: lp://staging/~ubuntu-dev/ubuntu-dev-tools/trunk
Diff against target: 172 lines (+77/-11)
2 files modified
ubuntutools/lp/lpapicache.py (+73/-11)
ubuntutools/lp/udtexceptions.py (+4/-0)
To merge this branch: bzr merge lp://staging/~ursinha/ubuntu-dev-tools/fix_getBinaryPackage
Reviewer Review Type Date Requested Status
Ursula Junque (community) Needs Resubmitting
Brian Murray Needs Fixing
Review via email: mp+159076@code.staging.launchpad.net

Description of the change

Fixed the behavior of getBinaryPackage in lpapicache.py. It was using the same parameters to get Source and Binary packages build history, but source packages need a distro series, and binary packages need a distro arch series, the results are arch dependent. I've added a DistroArchSeries, and changed DistroSeries accordingly. Also added a method to get binaryFileUrls.

To post a comment you must log in.
Revision history for this message
Brian Murray (brian-murray) wrote :

This looks good however, shouldn't archtag=None here:

68 + def getBinaryPackage(self, name, archtag, series=None, pocket=None):

As distro_arch_series is not required by Launchpad.

While a nitpick the following should be an not a:

17 + Returns a DistroSeries object for a architecture passed by name (e.g.

review: Needs Fixing
1380. By Ursula Junque

ubuntutools/lp/lpapicache.py: removed archtag as required in getBinaryPackage.

Revision history for this message
Ursula Junque (ursinha) wrote :

I've made archtag not required, and workarounded the code so _getPublishedItem will use distro_arch_series parameter instead of distro_series when calling getBinaryPackage (that is the bug that motivated this fix).

review: Needs Resubmitting

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.