mirror of
https://github.com/apache/superset.git
synced 2026-04-23 18:14:56 +00:00
fix: better handle datasource exceptions (#13578)
* fix: handle datasource injected security exception * add tests * fix error text on create update dbs * fix lint * revert create update message * fix test * add sqlalchemy exceptions
This commit is contained in:
committed by
GitHub
parent
868e063b03
commit
1e88408418
@@ -54,7 +54,7 @@ class UpdateDatabaseCommand(BaseCommand):
|
||||
# TODO Improve this simplistic implementation for catching DB conn fails
|
||||
try:
|
||||
schemas = database.get_all_schema_names()
|
||||
except Exception:
|
||||
except Exception as ex:
|
||||
db.session.rollback()
|
||||
raise DatabaseConnectionFailedError()
|
||||
for schema in schemas:
|
||||
|
||||
Reference in New Issue
Block a user