I am guessing that QSortProxyModel (QSPM) listens for the source model's destroyed() signal, so it sets the sourceModel() pointer to null. I have found that QSPM doesn't emit signals that I would expect when the model changes (like dataChanged()), but does emit layoutChanged(). Have you checked for that?