.. change::
    :tags: change, orm
    :tickets: 4662

    The condition where a pending object being flushed with an identity that
    already exists in the identity map has been adjusted to emit a warning,
    rather than throw a :class:`.FlushError`. The rationale is so that the
    flush will proceed and raise a :class:`.IntegrityError` instead, in the
    same way as if the existing object were not present in the identity map
    already.   This helps with schemes that are uinsg the
    :class:`.IntegrityError` as a means of catching whether or not a row
    already exists in the table.

    .. seealso::

        :ref:`change_4662`

