Possible to retrieve information about formula branch tips

Francis J. Lacoste francis.lacoste at canonical.com
Mon Jul 18 15:05:10 UTC 2011


Hi,

I'm pleased to announce that a new API method is available on
distribution objects to list all the branch tips of package branches. In
Principia-land, this means all the branches with formulas in.

>>> from launchpadlib.launchpad import Launchpad
>>> from pprint import pprint
>>> import datetime
>>> lp = Launchpad('demo!!!', 'production', api_version='devel')

>>> pprint(lp.distributions['principia'].getBranchTips())
[[u'~clint-fewbar/principia/oneiric/ensemble/nfs',
  u'clint at ubuntu.com-20110629160203-4wvvbpgeb7ipdynn',
  []],
 [u'~clint-fewbar/principia/oneiric/pictor/trunk',
  u'kirkland at ubuntu.com-20110614053954-pq7orztdj4lr049f',
  [u'oneiric']],
 [u'~clint-fewbar/principia/oneiric/tomcat6/trunk',
  u'juan.negron at canonical.com-20110627084436-24og7s2huqsisb4q',
  [u'oneiric']],
 [u'~daker/principia/oneiric/joomla/trunk',
  u'daker at ubuntu.com-20110706091929-dc39bi77zu0mv1ej',
  []],
 ...

>>> yesterday = datetime.datetime.utcnow() - datetime.timedelta(days=1)
>>> pprint(lp.distributions['principia'].getBranchTips(since=yesterday))
[[u'~therve/principia/oneiric/rabbitmq-server/trunk',
  u'thomas at canonical.com-20110717205856-7mukcsnskpqwoacr',
  []]]

Enjoy!

-- 
Francis J. Lacoste
francis.lacoste at canonical.com

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 262 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ubuntu.com/archives/juju/attachments/20110718/4718527c/attachment-0002.pgp>


More information about the Ensemble mailing list