Doctrine 2 - ORM
  1. Doctrine 2 - ORM
  2. DDC-2267

EntityManager throws an exception when trying to flush($entity) on a deleted entity

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.3.2
    • Fix Version/s: 2.3.4
    • Component/s: ORM
    • Security Level: All
    • Labels:
      None

      Description

      $entity = $em->find("Bug", 1);
      $em->remove($entity);
      $em->flush($entity);

      Throws an exception. Works fine with $em->flush() (No $entity provided).

      Would be nice to just flush the deleted entity separate from other entities. This technically works for other operations except remove(). The exception claims that the entity is not mapped. It technically can't be mapped since it's set to be deleted.

        Issue Links

          Activity

          Gennady Feldman created issue -
          Benjamin Eberlei made changes -
          Field Original Value New Value
          Link This issue is duplicated by DDC-2309 [ DDC-2309 ]
          Hide
          Benjamin Eberlei added a comment -

          Fixed in 2.3 branch, for 2.3.4

          Show
          Benjamin Eberlei added a comment - Fixed in 2.3 branch, for 2.3.4
          Benjamin Eberlei made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Fix Version/s 2.3.4 [ 10420 ]
          Resolution Fixed [ 1 ]

          This list may be incomplete, as errors occurred whilst retrieving source from linked applications:

          • Request to http://www.doctrine-project.org/fisheye/ failed: Error in remote call to 'FishEye 0 (http://www.doctrine-project.org/fisheye/)' (http://www.doctrine-project.org/fisheye) [AbstractRestCommand{path='/rest-service-fe/search-v1/crossRepositoryQuery', params={query=DDC-2267, expand=changesets[0:20].revisions[0:29],reviews}, methodType=GET}] : Received status code 503 (Service Temporarily Unavailable)

            People

            • Assignee:
              Benjamin Eberlei
              Reporter:
              Gennady Feldman
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: