Old bug; per suggestion from this thread: https://forums.debian.net/viewtopic.php?p=825776 I am adding:
I did a fresh install of Debian 12 which is my main daily driver desktop environment. I installed a headless Debain 12 (from same installer .iso) to a seperate partition but did not have it run update-grub on the install.
I then reboot to my main install, update-grub to pick up the new install, reboot and try to boot to the headless install but the grub.cfg uses /dev/sdX instead of the UUID, so it can't boot (because dev names are different.)
I tried the patch suggested 2011-12-13 by Marcin but it seemed to corrupt my grub.cfg (not surprising, given the age and that it was perhaps for CentOS).
My hack solution was to change /etc/grub.d/30_os-prober line 248 to be:
linux ${LKERNEL} root=UUID=${boot_device_id}
...which I assume is a Bad Idea for some reason, but I don't know anything about this stuff. Just wanted to report that this is still an issue.