On one system I had to move root's $HOME away from /root after / got near full.
This appears to break up2date, which continually prompts to add the GPG key to
the keyring, and fails to add it when requested.
has a hard-coded:
gpg_home_dir = "/root/.gnupg"
which should really be picked up from $HOME I would have thought.
$HOME was often invalid in testing for various reasons (most related
to su/sudo/etc) so it was hardcoded.
Picking it up from getpwuid(0)->pw_dir would be a reliable method.