Make more use of DbViewModel#handleException()
Closes #1973 (closed)
Draft because we probably want to wait for all the other view model work to finish before merging this to avoid conflicts in them. Easier to rebase these changes here.
Edited by Sebastian