GNU bug report logs - #50755
[PATCH] import: Generate list of importers based on available modules

Previous Next

Package: guix-patches;

Reported by: pinoaffe <pinoaffe <at> airmail.cc>

Date: Thu, 23 Sep 2021 12:25:02 UTC

Severity: normal

Tags: patch

Full log


View this message in rfc822 format

From: zimoun <zimon.toutoune <at> gmail.com>
To: Maxime Devos <maximedevos <at> telenet.be>
Cc: pinoaffe <pinoaffe <at> airmail.cc>, 50755 <at> debbugs.gnu.org
Subject: [bug#50755] [PATCH v3] import: Generate list of importers based on available modules
Date: Mon, 11 Oct 2021 13:51:13 +0200
Hi,

On Thu, 30 Sept 2021 at 10:37, Maxime Devos <maximedevos <at> telenet.be> wrote:

> The list of importers is only needed for two purposes, right?
>
>    1. to print a list of importers when "guix import --help" is run
>    2. to verify the string actually specifies an importer
>
> Then 'guix import SOME-IMPORTER STUFF' could be optimised:
>
> reolve-importer and guix-import could be modified to skip the validation
> step and let resolve-importer print the error if the module couldn't be
> found.  Possibly (resolve-module '(the possibly undefined module) #:ensure #f)
> might be useful. Then 'importers' would only be required for purpose (1),
> so it could be wrapped in a promise, such that if "guix import some-importer stuff"
> is called, only the required importer module is loaded.

My comment is about the elegance vs the performance loss.  On old
machines, Guix is becoming unpractical for many operations (almost all
the operations indeed) and I would not add another slowness.  I am
fine to sacrifice some performances if it is worth.  However, the
balance is always: what is gain and what is loss?  Here the gain is
small code elegance against the performance lost for end-user.  The
question: does it worth?  From my point of view, no, this change is
not worth.  For what my opinion is worth here. ;-)

Cheers,
simon




This bug report was last modified 3 years and 246 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.