mirror of
https://github.com/doctrine/orm.git
synced 2026-03-24 06:52:09 +01:00
DDC-3115: UnitOfWok can't access proxies protected property #3866
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?
Originally created by @doctrinebot on GitHub (May 4, 2014).
Originally assigned to: @Ocramius on GitHub.
Jira issue originally created by user machete:
Running the code on different environments for a while now, I have never had any problems. Recently I installed the code onto a different server and I've been experiencing the following issue:
I am absolutely clueless, why this happens. It seems to be affecting only specific data rows, as you might reproduce here: http://de.serlo.org/pages
The field is defined as followed:
However, the exact same database snapshot works fine here: http://ptr.serlo.org/pages
Attached you will find a screenshot of the datarows. The yellow ones mark each one working and one not working row.
I have no idea what the problem is here.
@doctrinebot commented on GitHub (May 4, 2014):
Comment created by @ocramius:
Discussed this on IRC - very tricky, seems like one of the servers has the reflection property not set to "accessible"
@doctrinebot commented on GitHub (May 4, 2014):
Comment created by machete:
Adding
$class->reflFields[$field]->setAccessible(true)before line 2596 resolved this issue. Even after removing it, everything worked fine.note to self:
@leondeng commented on GitHub (Aug 24, 2016):
orm 2.5.4, experienced same error:
Worse that Adding
$class->reflFields[$field]->setAccessible(true)before line 2773 not working.it did work when changed that line to
$entity[$field] = $pColl;, and only because my entity implements \ArrayAccess.