[PR #6649] #6638 #6648 one-to-one association being refreshed even if not built by the hydrator or having HINT_REFRESH set #10084

Open
opened 2026-01-22 16:06:22 +01:00 by admin · 0 comments
Owner

Original Pull Request: https://github.com/doctrine/orm/pull/6649

State: closed
Merged: No


Fixes #6638
Fixes #6648

This patch is just a first stab at the issue: the ObjectHydrator is massively broken because of this bug, and the idea is that we need to internally cache whether an object is BUILT in the current ObjectHydrator, or whether it already exists as a loaded and managed entity in the UnitOfWork.

This has to happen before calling createEntity() on the UnitOfWork, or else information is lost.

**Original Pull Request:** https://github.com/doctrine/orm/pull/6649 **State:** closed **Merged:** No --- Fixes #6638 Fixes #6648 This patch is just a first stab at the issue: the `ObjectHydrator` is massively broken because of this bug, and the idea is that we need to internally cache whether an object is BUILT in the current `ObjectHydrator`, or whether it already exists as a loaded and managed entity in the `UnitOfWork`. This has to happen before calling `createEntity()` on the `UnitOfWork`, or else information is lost.
admin added the pull-request label 2026-01-22 16:06:22 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: doctrine/archived-orm#10084