mbox series

[bug#40130,0/8] Add 'with-build-handler' and use it to improve UI feedback

Message ID 20200319105642.4830-1-ludo@gnu.org
Headers show
Series Add 'with-build-handler' and use it to improve UI feedback | expand

Message

Ludovic Courtès March 19, 2020, 10:56 a.m. UTC
Hello Guix!

This patch series is to always display upfront what’s going to
happen, even in the presence of “dynamic dependencies” (grafts),
as was reported at:

  https://issues.guix.gnu.org/issue/28310

With this patch, any time ‘build-things’ is called, we have an
opportunity to display what’s going to happen and to choose
whether or not to actually build things (dry runs).

I’m wondering whether/how this mechanism could be extended to
address:

  https://issues.guix.gnu.org/issue/22990

We’ll see!

Ludo’.

Ludovic Courtès (8):
  syscalls: 'with-file-lock' re-grabs lock when reentering its dynamic
    extent.
  store: Add 'with-build-handler'.
  ui: Add a notification build handler.
  guix build: Use 'with-build-handler'.
  deploy: Use 'with-build-handler'.
  pack: Use 'with-build-handler'.
  guix package, pull: Use 'with-build-handler'.
  guix system: Use 'with-build-handler'.

 .dir-locals.el           |   1 +
 guix/build/syscalls.scm  |  64 ++++++-------
 guix/scripts/build.scm   | 114 +++++++++++------------
 guix/scripts/deploy.scm  |  34 +++----
 guix/scripts/pack.scm    | 196 +++++++++++++++++++--------------------
 guix/scripts/package.scm |  29 +++---
 guix/scripts/pull.scm    | 118 ++++++++++++-----------
 guix/scripts/system.scm  |  80 ++++++++--------
 guix/store.scm           |  75 ++++++++++++---
 guix/ui.scm              |  38 ++++++++
 tests/store.scm          |  34 ++++++-
 11 files changed, 447 insertions(+), 336 deletions(-)

Comments

Ludovic Courtès March 22, 2020, 11:44 a.m. UTC | #1
Ludovic Courtès <ludo@gnu.org> skribis:

> This patch series is to always display upfront what’s going to
> happen, even in the presence of “dynamic dependencies” (grafts),
> as was reported at:
>
>   https://issues.guix.gnu.org/issue/28310
>
> With this patch, any time ‘build-things’ is called, we have an
> opportunity to display what’s going to happen and to choose
> whether or not to actually build things (dry runs).

Pushed with a0f480d623f71b7f0d93de192b86038317dc625b along with related
changes.

Ludo’.
Ricardo Wurmus March 22, 2020, 12:44 p.m. UTC | #2
Ludovic Courtès <ludo@gnu.org> writes:

> Ludovic Courtès <ludo@gnu.org> skribis:
>
>> This patch series is to always display upfront what’s going to
>> happen, even in the presence of “dynamic dependencies” (grafts),
>> as was reported at:
>>
>>   https://issues.guix.gnu.org/issue/28310
>>
>> With this patch, any time ‘build-things’ is called, we have an
>> opportunity to display what’s going to happen and to choose
>> whether or not to actually build things (dry runs).
>
> Pushed with a0f480d623f71b7f0d93de192b86038317dc625b along with related
> changes.

Thank you for this improvement that used to be always out of reach!

(I don’t fully understand it yet, which is why I couldn’t give any
comments sooner, but I’ll try <take the time to study this later.)

--
Ricardo