Please expose queues/recently accepted in the API
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Fix Released
|
Medium
|
Julian Edwards |
Bug Description
Hi,
I have a use case for that API that I would like to see implemented.
In order to import all Ubuntu packages in to bzr I need to find what was
recently accepted and grab the corresponding source package.
My current solution for doing this is to watch the various -changes
mailing lists and react to the mails on there. I'd like to be able
to do it with the API though.
The obvious difference would be that it would be a polling solution
rather than a notification one, so it would have to work a little bit
differently.
The basic information I need to know is the source package,
the version that was uploaded, and the release and pocket that
it was uploaded to. A way to grab the associated source package
directly would be great.
Reliably querying for a list of uploads since a certain time seems
error-prone, and getting the list of every upload ever sounds like
a lot of work when most won't be interesting, I would appreciate
your ideas on what a useful API would be.
Whatever it is has to work with pocket copies and other things where
the version package in a pocket changes whether or not it was
triggered by a dput.
Thanks,
James
Changed in launchpad: | |
importance: | Undecided → Medium |
Changed in soyuz: | |
milestone: | none → pending |
status: | New → Triaged |
Changed in soyuz: | |
status: | Triaged → In Progress |
Changed in soyuz: | |
status: | Fix Committed → Fix Released |
Hi,
archive. getPublishedSou rces goes a long way to doing this, thanks.
here's what I currently do:
publications = ubuntu_ archive. getPublishedSou rces(status= "Published" ) datepublished > last_known_ published:
for publication in publications:
if publication.
scan over all the publishing for this package and import anything we don't yet have
only doing it once per source package name.
The last_known_ published is updated on each run, so that I only do the expensive stuff
for packages that are newly published in at least one series.
This works pretty well, and does what I want, thanks.
However, it requires getting every "Published" record for Ubuntu on every
run, only to filter them afterwards. If getPublishedSources grew a "published
since" parameter or similar, so that I could do the filtering on the query, instead
of on the results I would be a very happy man.
Currently it takes a while to walk the collection to determine what is new, and
means transferring lots of data (this query is run a lot).
Thanks,
James