Comment 1 for bug 200457

Revision history for this message
Markus Korn (thekorn) wrote :

The attached patch adds a function 'get_open_milestones(dist=None, package=None, project=None)' as a first step to fix this bug. This function returns an iterator over all open milestones related to given distribution, package or project:

example usage:
In [7]: dict(get_open_milestones("ubuntu"))
Out[7]:
{135: 'Ubuntu: dapper-updates',
 196: 'Ubuntu: later',
 197: 'Ubuntu: edgy-updates',
 556: 'Ubuntu: ubuntu-6.06.2',
 814: 'Ubuntu: gutsy-updates',
 829: 'Ubuntu: ubuntu-8.04',
 831: 'Ubuntu: hardy-alpha-1',
 948: 'Ubuntu: hardy-alpha-2',
 949: 'Ubuntu: hardy-alpha-3',
 950: 'Ubuntu: hardy-alpha-4',
 951: 'Ubuntu: hardy-alpha-5',
 952: 'Ubuntu: hardy-alpha-6',
 953: 'Ubuntu: ubuntu-8.04-beta'}

In [4]: dict(get_open_milestones(project="bughelper"))
Out[4]: {249: 'Bug Helper: 0.1' , 259: 'Bug Helper: 0.2'}

Markus