unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Reily Siegel <mail@reilysiegel.com>
To: guix-devel@gnu.org
Subject: Breaking change: Make 'description' of <service-type> mandatory
Date: Thu, 26 May 2022 09:38:38 +0200	[thread overview]
Message-ID: <87leuospz5.fsf@reilysiegel.com> (raw)

Hello,

This commit at 3948ac25b1dccc40c7fdf56377f94a0775a835ee broke my
configuration. I don't mean to grumble about this, but rather
figure out if I am doing something horribly wrong in my configuration to
cause such a simple change to break things, and perhaps alert other
people making similar mistakes happen.

The solution here is incredibly obvious, I just need to add descriptions
to services I declare in my configuration, but that this change
happened, and I didn't see anyone else have issues on guix-devel,
guix-help, or elsewhere (I may have missed something), I thought it a
good idea to ask if I am doing something unsupported in my
configuration.

The problem arises when a certain feature needs to extend two services
to be useful: take configuration of an emacs package. It must first
extend (in the case of Guix home) home-emacs-service (from RDE channel)
with the emacs configuration to be inserted to init.el, and
home-profile-service-type, to add the emacs package to the profile. It
seems like simple-service /would/ be a good option here, except as best
I can figure out it can only extend one service. So instead, I create a
new service-type, perhaps named my-emacs-feature-configuration-service,
which takes no value and has no extension mechanism, but only serves to
extend multiple other "real" services.

This change (and the discussion at https://issues.guix.gnu.org/55404)
indicates to me that all service-types, no matter where they are
implemented, are meant to be consumed by a generic user, not used in a
one-off way like my configuration does.

So, to sum up, I have a few questions:

1. Is service-type meant for use in individual user configurations?
2. Is there an equivalent function to simple-service that takes multiple
   service/value pairs that I have missed?
   (e.g., (simple-service-like service-a val-a service-b val-b ...)
    or (simple-service-like (list service-a val-a service-b val-b)))
3. If the answer to 2 is no, does it make sense to extend simple-service
   to work with multiple service extensions, or is there some reason for
   only extending one service at a time?

Thanks for reading through this email that I am for some reason sending
even though it would be faster to just add descriptions to all my
services, and hopefully I can learn something about Guix!

-- 
Reily Siegel


             reply	other threads:[~2022-05-26 14:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-26  7:38 Reily Siegel [this message]
2022-05-26 20:03 ` Breaking change: Make 'description' of <service-type> mandatory Liliana Marie Prikler
2022-05-30 16:04 ` Ludovic Courtès

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=87leuospz5.fsf@reilysiegel.com \
    --to=mail@reilysiegel.com \
    --cc=guix-devel@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).