mirror of
https://github.com/apache/superset.git
synced 2024-09-17 11:09:47 -04:00
fix: dataset import error message (#23025)
This commit is contained in:
parent
98bf878d6e
commit
7bb9b810ee
@ -67,6 +67,9 @@ class ImportModelsCommand(BaseCommand):
|
||||
try:
|
||||
self._import(db.session, self._configs, self.overwrite)
|
||||
db.session.commit()
|
||||
except CommandException as ex:
|
||||
db.session.rollback()
|
||||
raise ex
|
||||
except Exception as ex:
|
||||
db.session.rollback()
|
||||
raise self.import_error() from ex
|
||||
|
@ -193,5 +193,5 @@ class DatasetDuplicateFailedError(CreateFailedError):
|
||||
message = _("Dataset could not be duplicated.")
|
||||
|
||||
|
||||
class DatasetForbiddenDataURI(ForbiddenError):
|
||||
class DatasetForbiddenDataURI(ImportFailedError):
|
||||
message = _("Data URI is not allowed.")
|
||||
|
Loading…
Reference in New Issue
Block a user