Re: Bug#1116273: buildd.debian.org: please provide API for getbuildlog
On Sun, Apr 12, 2026 at 06:25:13PM +0000, Philipp Kern wrote:
> On Wed, Sep 24, 2025 at 11:30:21PM +0200, Chris Hofstaedtler wrote:
> > getbuildlog from devscripts currently parses the HTML generated by
> > fetch.php. This is unsurprisingly brittle, and causes bugs like
> > #651286.
> >
> > I think it would be nicer if buildd.d.o would expose some
> > semi-stable (JSON?) API which getbuidlog could use.
> >
> > getbuildlog, per its documentation, wants to support filtering by
> > these things:
> >
> > - package name (mandatory)
> > - optional version, as a grep -E pattern, or "last"
> > - optional arch, as a grep -E pattern
> >
> > The filtering could be done server- or client-side. It would be good
> > to get things like "+" in version numbers right.
>
> I wrote a small script that dumps the database content as a JSON. It's
> reachable with https://buildd.debian.org/api/buildlogs/<pkg>
>
> One advantage of this is that we should in theory be able to pregenerate
> the content if needed - i.e. on regenerate the package's file on every
> injected build log. But for now just dumping the DB should do.
>
> I'd guess that we also want to dump all the information.
>
> (I still need to properly commit this, but it seems to keep working
> so far.)
It has been committed to https://salsa.debian.org/wb-team/wbpy/ in the
meantime, so resolving the bug.
Kind regards
Philipp kern
Reply to: