Occasionally you’re grumpy because substitutes are lacking and you end
up building packages by yourself (see Substitutes). The
guix weather command reports on substitute availability on the
specified servers so you can have an idea of whether you’ll be grumpy
today. It can sometimes be useful info as a user, but it is primarily
useful to people running
guix publish (see Invoking guix publish).
Here’s a sample run:
$ guix weather --substitute-urls=https://guix.example.org computing 5,872 package derivations for x86_64-linux... looking for 6,128 store items on https://guix.example.org.. updating list of substitutes from 'https://guix.example.org'... 100.0% https://guix.example.org 43.4% substitutes available (2,658 out of 6,128) 7,032.5 MiB of nars (compressed) 19,824.2 MiB on disk (uncompressed) 0.030 seconds per request (182.9 seconds in total) 33.5 requests per second 9.8% (342 out of 3,470) of the missing items are queued 867 queued builds x86_64-linux: 518 (59.7%) i686-linux: 221 (25.5%) aarch64-linux: 128 (14.8%) build rate: 23.41 builds per hour x86_64-linux: 11.16 builds per hour i686-linux: 6.03 builds per hour aarch64-linux: 6.41 builds per hour
As you can see, it reports the fraction of all the packages for which
substitutes are available on the server—regardless of whether
substitutes are enabled, and regardless of whether this server’s signing
key is authorized. It also reports the size of the compressed archives
(“nars”) provided by the server, the size the corresponding store
items occupy in the store (assuming deduplication is turned off), and
the server’s throughput. The second part gives continuous integration
(CI) statistics, if the server supports it. In addition, using the
guix weather can list “important”
package substitutes missing on the server (see below).
To achieve that,
guix weather queries over HTTP(S) meta-data
(narinfos) for all the relevant store items. Like
challenge, it ignores signatures on those substitutes, which is
innocuous since the command only gathers statistics and cannot install
Among other things, it is possible to query specific system types and specific package sets. The available options are listed below.
urls is the space-separated list of substitute server URLs to query. When this option is omitted, the default set of substitute servers is queried.
Query substitutes for system—e.g.,
option can be repeated, in which case
guix weather will query
substitutes for several system types.
Instead of querying substitutes for all the packages, only ask for those
specified in file. file must contain a manifest, as
-m option of
guix package (see Invoking guix package).
Report on substitute coverage for packages: list packages with at least count dependents (zero by default) for which substitutes are unavailable. Dependent packages themselves are not listed: if b depends on a and a has no substitutes, only a is listed, even though b usually lacks substitutes as well. The result looks like this:
$ guix weather --substitute-urls=https://ci.guix.gnu.org -c 10 computing 8,983 package derivations for x86_64-linux... looking for 9,343 store items on https://ci.guix.gnu.org... updating substitutes from 'https://ci.guix.gnu.org'... 100.0% https://ci.guix.gnu.org 64.7% substitutes available (6,047 out of 9,343) … 2502 packages are missing from 'https://ci.guix.gnu.org' for 'x86_64-linux', among which: 58 email@example.com /gnu/store/…-kcoreaddons-5.49.0 46 firstname.lastname@example.org /gnu/store/…-qgpgme-1.11.1 37 email@example.com /gnu/store/…-perl-http-cookiejar-0.008 …
What this example shows is that
kcoreaddons and presumably the 58
packages that depend on it have no substitutes at
qgpgme and the 46 packages that depend on it.
If you are a Guix developer, or if you are taking care of this build farm, you’ll probably want to have a closer look at these packages: they may simply fail to build.