Intercept the "transient to pending" transition for a specific object. This event is a specialization of the :meth:`.SessionEvents.after_attach` event which is only invoked for this specific transition. It is invoked typically during the :meth:`.Session.add`
(self, session: Session, instance: _O)
| 2153 | |
| 2154 | @_lifecycle_event |
| 2155 | def transient_to_pending(self, session: Session, instance: _O) -> None: |
| 2156 | """Intercept the "transient to pending" transition for a specific |
| 2157 | object. |
| 2158 | |
| 2159 | This event is a specialization of the |
| 2160 | :meth:`.SessionEvents.after_attach` event which is only invoked |
| 2161 | for this specific transition. It is invoked typically during the |
| 2162 | :meth:`.Session.add` call. |
| 2163 | |
| 2164 | :param session: target :class:`.Session` |
| 2165 | |
| 2166 | :param instance: the ORM-mapped instance being operated upon. |
| 2167 | |
| 2168 | .. seealso:: |
| 2169 | |
| 2170 | :ref:`session_lifecycle_events` |
| 2171 | |
| 2172 | """ |
| 2173 | |
| 2174 | @_lifecycle_event |
| 2175 | def pending_to_transient(self, session: Session, instance: _O) -> None: |
no outgoing calls