My suspicion right now is that there’s not any real mixup happening, but that guix-daemon runs the build in a different environment in the directory
/tmp/derivation-name.drv-0 which gets copied to /tmp/derivation-name.drv-5 in the root filesystem by `guix build -K`, if directories -0, -1, …, -4 already exist. In which case I’d suggest doing something to the messages and/or documentation to make this clearer. E.g. instead of saying “keeping build directory <dir>” say “keeping a copy of the build directory at <dir>”.
