From mboxrd@z Thu Jan 1 00:00:00 1970 From: Leo Famulari Subject: Re: Is it necessary to download the native inputs while installing packages? Date: Thu, 18 Jan 2018 11:56:07 -0800 Message-ID: References: <81597a04-598a-e894-84af-759c1b5401ca@tobias.gr> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:33966) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ecGIL-0007V3-Dq for guix-devel@gnu.org; Thu, 18 Jan 2018 14:56:18 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ecGII-0003cZ-BZ for guix-devel@gnu.org; Thu, 18 Jan 2018 14:56:17 -0500 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:56189) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ecGII-0003c9-6n for guix-devel@gnu.org; Thu, 18 Jan 2018 14:56:14 -0500 In-Reply-To: <81597a04-598a-e894-84af-759c1b5401ca@tobias.gr> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org, Tobias Geerinckx-Rice , ybbs.daans@hotmail.com Sorry for the top-posting=2E I need to clarify what --fallback does=2E Guix will always build locally if the substitute servers say they lack som= ething Guix needs=2E --fallback works when the substitute servers say they have something, and = then the substitution fails unexpectedly=2E For example, the server may bec= ome overloaded and drop the connection=2E -------- Original Message -------- From: Tobias Geerinckx-Rice Sent: January 18, 2018 9:36:50 AM PST To: ybbs=2Edaans@hotmail=2Ecom, guix-devel@gnu=2Eorg Subject: Re: Is it necessary to download the native inputs while installin= g packages? Hullo, There are quite a few unrelated points mixed together here=2E I'll try to address all of them, but I'm not entirely sure what your main question is=2E I hope to answer it by accident=2E Fis Trivial wrote on 18/01/18 at 16:19: > The network connections to hydra is bad at day time from where I am, > the download speed is about 10kB/s, I can only work with guix at=20 > night=2E And sometimes I use guix --fallback option(like texlive), guix > will redirect to the upstream download link=2E I get your meaning, but =E2=80=98redirect=E2=80=99 isn't the right word to= use here=2E Redirection is something servers do, and that's not the case here=2E When installing a package, Guix queries all known substitute servers for a pre-built binary substitute=2E What =E2=80=98--fallback=E2=80=99 does is= tell Guix to not give up if all servers answer negatively (404), but to build the package from source locally=2E For that it needs to download the source from upstream servers, and of course the native inputs required to perform the build=2E There's no way around that=2E If any of the substitute servers *can* provide a binary, no native-inputs will be downloaded at all=2E Why are you adding =E2=80=98--fallback=E2=80=99? > Chances are the upstream has even worse network bandwidth, then I=20 > have to manually find a mirror of that particular upstream and use=20 > `guix download`=2E This is an unrelated but valid point=2E I've previously mused that it should be possible to let users choose (a set of) their favourite mirror(s), instead of always downloading sources from the first mirror queried=2E It could be as simple as adding ISO codes to each mirror URI=2E > In the case of *texlive-texmf*, it serves mostly as a build=20 > dependence=2E To make things even less convenient, most of the mirror=20 > site only store its ISO package, not the tar ball used in guix=20 > package=2E Oh=2E That's unfortunate=2E I'm not familiar with the Guix texlive package= s, and all the ones I happened to look at now have a direct ftp:// link=2E Is upstream the one doing the =E2=80=94 heh =E2=80=94 redirection here? If= so, it should arguably doing a better job=2E We could still help matters by hard-coding a shortlist of mirrors known to host the files we need=2E > So, I gotta wonder, can we just download the normal inputs and=20 > propagated inputs from hydra while installing packages? Would that=20 > break something like the functional property of guix? =E2=80=98Installing=E2=80=99 is too ambiguous to answer=2E - When *substituting* (installing a binary), native-inputs are not required and should never be downloaded=2E - When *building* (from source), they are=2E Kind regards, T G-R PS: Oh=2E Right=2E Sigh=2E=2E=2E To complicate matters, texlive-texmf is a= special case that's never substituted, because doing so is thought to be worse than just building it from source[1]=2E That's the reason you're downloading TexLive from upstream, but it's *not* the reason you're pulling in TexLive to begin with and doesn't change the native-inputs situation=2E I think=2E [1]: https://git=2Esavannah=2Egnu=2Eorg/cgit/guix/maintenance=2Egit/tree/hydra/= nginx/hydra=2Egnu=2Eorg-locations=2Econf#n23