(address . bug-guix@gnu.org)
Hi Guix!
After updating the system, the dovecot service got confused and started
moving around all mailboxes. I looked up the configuration and noticed
strange invalid syntax for the location field:
Toggle snippet (3 lines)
location=#<<location> file: "path/to/config.scm" line: 297 column: 20>
Because the # character is interpreted as a comment, dovecot doesn't
crash and instead moves mailboxes around in weird ways I don't quite
understand :-/.
This can actually be reproduced locally with the dovecot system test if
one dumps the following expression to check the configuration:
Toggle snippet (5 lines)
(format #t "~a\n" (wait-for-file "/etc/dovecot/dovecot.conf"
marionette
#:read 'get-string-all))
Giving us the snippets like this in the config:
Toggle snippet (39 lines)
$ make check-system TESTS="dovecot" VERBOSE=1
...
namespace inbox {
type=private
separator=
prefix=
location=#<<location> file: "gnu/tests/mail.scm" line: 297 column: 20>
inbox=yes
hidden=no
list=yes
subscriptions=yes
mailbox "Drafts" {
auto=no
special_use=\Drafts
}
mailbox "Junk" {
auto=no
special_use=\Junk
}
mailbox "Trash" {
auto=no
special_use=\Trash
}
mailbox "Sent" {
auto=no
special_use=\Sent
}
mailbox "Sent Messages" {
auto=no
special_use=\Sent
}
mailbox "Drafts" {
auto=no
special_use=\Drafts
}
}
...
I did a `git bisect` with `guix time-machine` (this tool is invaluable)
and found the issue started with this commit:
Toggle snippet (15 lines)
commit 543d971ed2a1d9eb934af1f51930741d7cc4e7ef
Author: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Fri Oct 28 17:06:16 2022 -0400
services: configuration: Re-order generated record fields.
This is so that the first field of the generated record matches the first one
declared, which makes 'define-configuration' record API compatible with
define-record-type* ones.
* gnu/services/configuration.scm (define-configuration-helper): Move the
%location field below the ones declared by the user.
* gnu/services/monitoring.scm (zabbix-front-end-config): Adjust match pattern
accordingly.
Sooo, I'm guessing this is something to do with the configuration field
being named "location", and /maybe/ we're patching it with the origin
location of the configuration, something like that? I don't understand
how this works well enough to be able to thing of any fixes.
Thanks,
Pierre
-----BEGIN PGP SIGNATURE-----
iQFMBAEBCgA2FiEEctU9gYy29KFyWDdMqPyeRH9PfVQFAmN6pbcYHHBpZXJyZS5s
YW5nbG9pc0BnbXguY29tAAoJEKj8nkR/T31UELMIAIk8qZ/lNX/RHsHkjdW1H6uH
ZZJ2BqN1XyqqXuILp5csv0MEKE9PlpSezY5/gTn+o09kzLD/fPkKhzGDgVCTmSXV
hndYGwP6bXoyUcbxOdoE7HDB1RW+euQUt+oVUQBlgnlLlWp9wR4KjF+P4+QD6ygH
VbVyxD93xArLhZe7eq6cLM9hi4wYW9UkV8eGe0SnTkwn9EAZzJpLg+lg/SudnFH+
fwdSUF7lA7HCw8t2+ObFhXuaX1mQOqACy3wQWhKg/00zo0dslu8uwJptltVbuhpX
+hKbfxAUOyng+Xu6Ho8JHK2waIl76KoxCuJpLKj/8u4u4dVUSiKp8rKTPchcwfM=
=1HH9
-----END PGP SIGNATURE-----