Subject: [bug#77201] [PATCH] guix: substitute-key-authorization: Fix case when acl symlink is broken

From: Rutherther <[email-masked]>
Date: Fri, 02 May 2025 20:33:48 +0200

I was skimming through the code and I found out install-channels-file
has the same issue as substitute-key-authorization has with this
symlinking. I suppose I will make this into a generic function after
all, so that it can be used in both of those functions.

Just wondering if I should make it a gexp or put it to some of the
guix/build/ files (or a new one?)

"Rutherther" <[email-masked]> writes:

> Apologies for the delay, I somehow didn't get to testing in a VM last
> week, today I finally tested it, found a few issues, fixed them, and it
> seems to be working fine for me. I tried to test all possible cases:
>
> - No acl file
> - Regular file
> - Symlink to store
> - Symlink out of store
> - Broken symlink
>
> - .bak (not) existing
>
> I've kept it directly in this function upon Ludo's comment about
> rebuilding the whole world if it was added to guix/build/utils, I can
> create a new guix/build file if you think it makes sense to have it
> reusable, or put it to another one(?).
>
> Since this is activation logic, I think it's important to thoroughly
> test it - should a new VM tests be added for this, or is it unnecesasry
> and the current tests suffice? If something went wrong, the tests would
> fail to boot (I haven't tried using system tests defined in guix yet, I
> will try to run them).
> Will QA run them for this commit or is it ran only for defined branches?
>
> Submitted v2.
>
> Regards,
> Rutherther