Giacomo Leidi <[email protected]> writes:

> Hi, as far as I know there is no API to directly query, but the data is 
> there, for example: by tweaking the parameters of  [0] I
> believe a client could crawl all derivations for all architectures that are 
> built from that commit. 
>
> It would be awesome if there was an API that could tell only the build result 
> of a package-architecture-commit tuple. In general I
> discovered that appending .json to many URLs of the Data Service web UI 
> results in JSON data being returned, I'm not sure if this
> is documented somewhere, I didn't look very hard but I was not able to find 
> it.
>
> A couple of years ago I started experimenting with making a Guix extension to 
> query the data service with this use case in mind,
> but I never got anything out of it [1], maybe it can be of inspiration to 
> someone.

The data service web interface was/is meant to be the guide for the API.

If you want to see packages failing to build for x86_64-linux for a
specific revision, you can go to a page like this for example:

  
https://data.qa.guix.gnu.org/revision/4750a7657d73e01d45789b06f4b8154b61da5f7f/package-derivations?search_query=&system=x86_64-linux&target=none&minimum_builds=&maximum_builds=&build_status=failing&field=builds&after_name=&limit_results=&all_results=on

The package pages also contain build information, so you can use this to
find out if a package is building, for example:

  
https://data.qa.guix.gnu.org/revision/4750a7657d73e01d45789b06f4b8154b61da5f7f/package/guile/3.0.9?locale=en_US.UTF-8

The data service design isn't great because while the data might be in
the database, it still needs exposing through the web UI, but new
pages/API endpoints can be added if that would be useful.

I'm using data.qa.guix.gnu.org for these examples, as it's a bit faster
than data.guix.gnu.org, which probably has database issues plus is
suffering under lots of scraping requests.

Attachment: signature.asc
Description: PGP signature

Reply via email to