GNU bug report logs -
#54352
[PATCH] services: dnsmasq: Add more options.
Previous Next
Full log
Message #23 received at 54352 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Remco van 't Veer schreef op zo 20-03-2022 om 13:22 [+0100]:
> 2022/03/20 12:56, Maxime Devos:
>
> > It would be nice to verify that these are, in fact, booleans,
> > using field sanitizers. See, e.g., ensure-setuid-program-list
> > in (gnu system).
>
> I agree but the same could be said about the other fields and types in
> this record, and those of other services.
In the long-term, it would be nice to eventually add error checking to
other services and fields as well. In the short-term, I would avoid
making error handling worse.
> In this case, the names of the fields ending with "?" should be
> enough for somebody to realise this is a boolean, IMHO.
> The";boolean" comments I've added are just me trying to blend in.
It's technically sufficient, but it does not make for nice error
messages, see the thread at
<https://lists.gnu.org/archive/html/guix-devel/2022-02/msg00140.html>.
In this particular case, there won't be an error message *at all*,
due to how (if forward-private-reverse-lookup? ... ...) works.
For example, consider the case where someone new to Guile and Guix sees
‘boolean’ in the documentation and then tries using "true" and "false"
(the strings):
(dnsmasq-configuration
(forward-private-reverse-lookup? "false"))
Currently, this will silently do the wrong thing.
Greetings,
Maxime.
[signature.asc (application/pgp-signature, inline)]
This bug report was last modified 3 years and 59 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.