Hello,
I have noticed the same issue on P8 with a main profile, a private space and Gboard. This has happened since the upgrade to Android 16.
Interestingly entering a wrong PIN and pressing enter logs a wrong attempt, but entering the right PIN and enter does not unlock. Going back to the lock screen and trying again does work.
No screen protector or any other funky settings.
GOS noted here that the unlock code significantly changed and so that is likely due to this.