mirror of
https://github.com/doctrine/orm.git
synced 2026-03-24 06:52:09 +01:00
[PR #10342] Add Fully-Qualified class name in UnrecognizedField exception #12279
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Original Pull Request: https://github.com/doctrine/orm/pull/10342
State: closed
Merged: Yes
Currently if we use a field that is not properly registered in our mapping, we end up with the following exception from the
BasicEntityPersister:As with a complete stack trace we may be able to dig enough to find the right mapping, it can take more time to find the concerned entity in a context with less informations, such as logs.
This PR adds the entity FQCN to the exception message to ease debugging in such cases, using the class metadata available in
BasicEntityPersister::classproperty. We end up with:As I didn't encountered any tests for the existing
UnrecognizedExceptionclass behavior, I didn't add some but I can if needed.