mikebridge commented on issue #39492:
URL: https://github.com/apache/superset/issues/39492#issuecomment-4479528050

   I think the correct fix for the split-flush workaround I had is to wrap the 
whole revert in `db.session.no_autoflush` and emit one explicit 
`db.session.flush()` afterwards. That means that pending DELETEs stay in 
`state.persistent` state instead of transitioning to `state.deleted` 
mid-iteration, so then the cascade walk in `session.add(parent)` no longer hits 
"Instance has been deleted".  I'll update this in the SIP.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to