Petar Tahchiev, what you are suggesting in your PR is an improvement in detecting an error condition. I'll change this issue to an improvement. It probably will not be addressed until Hibernate 6.