unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: "pelzflorian (Florian Pelz)" <pelzflorian@pelzflorian.de>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: 63921@debbugs.gnu.org, Brian Cully <bjc@spork.org>
Subject: bug#63921: Activation snippets in reverse order, prevent boot
Date: Wed, 07 Jun 2023 10:57:18 +0200	[thread overview]
Message-ID: <87a5xb645t.fsf@pelzflorian.de> (raw)
In-Reply-To: <87y1kw9ajz.fsf@gnu.org> ("Ludovic Courtès"'s message of "Tue, 06 Jun 2023 11:58:40 +0200")

Hi Ludo, hi all.

Ludovic Courtès <ludo@gnu.org> writes:
> I ended up
> rewriting ‘modify-services’.  Good news is we now have tests for this.

In the rewrite, you wrote:
> +(define (apply-clauses clauses services)
> +  "Apply CLAUSES, an alist as returned by 'clause-alist', to SERVICES, a list
> +of services.  Use each clause at most once; raise an error if a clause was not
> +used."

Using clauses at most once broke the greetd example in the manual:
> (append
>  (modify-services %base-services
>    ;; greetd-service-type provides "greetd" PAM service
>    (delete login-service-type)
>    ;; and can be used in place of mingetty-service-type
>    (delete mingetty-service-type))
>  (list
>   (service greetd-service-type

But there are multiple instances of mingetty-service-type in
%base-services.  Now an error is raised on reconfigure because there are
two term-tty2 services.

I’m not sure, isn’t it more explicit if we keep your change of deleting
at most once, but change the greetd example?

The following works for me now …

(modify-services %base-services
                 (delete login-service-type)
                 (delete mingetty-service-type)
                 (delete mingetty-service-type)
                 (delete mingetty-service-type)
                 (delete mingetty-service-type)
                 (delete mingetty-service-type)
                 (delete mingetty-service-type))

Regards,
Florian




  reply	other threads:[~2023-06-07  8:58 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-06  8:15 bug#63921: Activation snippets in reverse order, prevent boot Ludovic Courtès
2023-06-06  9:58 ` Ludovic Courtès
2023-06-07  8:57   ` pelzflorian (Florian Pelz) [this message]
2023-06-07  9:19     ` pelzflorian (Florian Pelz)
2023-06-07  9:30       ` pelzflorian (Florian Pelz)
2023-06-07 17:44     ` Jelle Licht
2023-06-07 22:02       ` Brian Cully via Bug reports for GNU Guix
2023-06-07 23:07         ` pelzflorian (Florian Pelz)
2023-06-17 13:59           ` pelzflorian (Florian Pelz)
2023-06-26 19:26 ` bug#63921: Patch proposed Felix Lechner via Bug reports for GNU Guix
2023-09-01 11:43   ` bug#63921: Activation snippets in reverse order, prevent boot Maxim Cournoyer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a5xb645t.fsf@pelzflorian.de \
    --to=pelzflorian@pelzflorian.de \
    --cc=63921@debbugs.gnu.org \
    --cc=bjc@spork.org \
    --cc=ludo@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).