~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/soyuz/browser/packagerelationship.py

  • Committer: Raphael Badin
  • Date: 2012-01-06 08:27:55 UTC
  • mfrom: (14513.5.4 builder-history-lfa)
  • mto: This revision was merged to the branch mainline in revision 14654.
  • Revision ID: raphael.badin@canonical.com-20120106082755-95a0eh6nakv5hj3b
Merge devel.

Show diffs side-by-side

added added

removed removed

Lines of Context:
42
42
            url = canonical_url(target_object)
43
43
        else:
44
44
            url = None
 
45
        # The apt_pkg 0.8 API returns '<' and '>' rather than the '<<' and
 
46
        # '>>' form used in control files.
 
47
        if operator == '<':
 
48
            operator = '<<'
 
49
        elif operator == '>':
 
50
            operator = '>>'
45
51
        relationship_set.add(name, operator, version, url)
46
52
 
47
53
    return relationship_set
82
88
    def __iter__(self):
83
89
        return iter(sorted(
84
90
            self.contents, key=std_operator.attrgetter('name')))
85