Subject: Re: bug#66097: New test "rewrite-url, without to-version" needs network

From: Maxim Cournoyer <[email-masked]>
Date: Wed, 20 Sep 2023 14:05:44 -0400

Hi Janneke!

Janneke Nieuwenhuizen <[email-masked]> writes:

> Hi Maxim,
>
> As mentioned on IRC, the recently-added "rewrite-url, without
> to-version" test needs not only nss-certs installed, as I found when
> building it for the Hurd.  New we also found it to fail in a container
> without network access.  That means a guix package build (in a
> container) now fails.

Ouch!  That's clearly not intended.

> After I updated the guix version to 1.4.0-11.658de25e99 yesterday
> morning to (finally) get `guix pull' to work on the Hurd, several people
> reported failure to reconfigure on IRC.
>
> This
>
>     guix shell -CD guix
>     export SCM_LOG_DRIVER_FLAGS="--select=^rewrite-url, without to-version"
>     make check TESTS=tests/gnu-maintenance.scm
>
> gives
>
> test-name: rewrite-url, without to-version
> [..]
> expected-value: "https://dist.libuv.org/dist/v1.46.0/libuv-v1.46.0.tar.gz"
> actual-value: #f
> actual-error:
> + (getaddrinfo-error -8)
> result: FAIL
>
>
> When changing the code like this
>
> -(test-equal "rewrite-url, without to-version"
> +(pk "rewrite-url, without to-version"
>    "https://dist.libuv.org/dist/v1.46.0/libuv-v1.46.0.tar.gz"
> -  (with-http-server
> +  "=>"(with-http-server

Thanks for the reproducer.  I'll look into fixing the problem.  I
believe it's a matter of adding more mocked server replies.  I must have
miscounted how many were needed.

-- 
Thanks,
Maxim