Generalise exception handling

This commit is contained in:
2022-08-20 14:47:46 +01:00
parent d9837246de
commit bcee2eedd0
15 changed files with 65 additions and 65 deletions

View File

@ -37,7 +37,7 @@ def _editor_console(id:str=None):
dataset = Dataset.query.filter_by(id=id).first()
datasets = Dataset.query.count()
users = User.query.all()
except (SQLAlchemyError, ConnectionError) as exception:
except Exception as exception:
write('system.log', f'Database error when processing request \'{request.url}\': {exception}')
return abort(500)
if not dataset: