Apache Superset Dashboard import is failing with Invalid Command Error

I am able to successfully export the Superset dashboard however importing the same dashboard is resulting in the below error. It was working a few days back.

Not sure what is causing the issue as I am not getting any specific error apart from the below error in the log.

Version: 0.00dev

superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    | 2022-07-14 14:36:06,767:INFO:superset.dashboards.commands.importers.dispatcher:Command failed validation
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    | CommandException
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    | Traceback (most recent call last):
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1516, in full_dispatch_request
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     rv = self.dispatch_request()
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1502, in dispatch_request
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     return self.ensure_sync(self.view_functions[rule.endpoint])(**req.view_args)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/usr/local/lib/python3.8/site-packages/flask_appbuilder/security/decorators.py", line 89, in wraps
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     return f(self, *args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/views/base_api.py", line 113, in wraps
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     raise ex
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/views/base_api.py", line 110, in wraps
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     duration, response = time_function(f, self, *args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/utils/core.py", line 1533, in time_function
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     response = func(*args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/utils/log.py", line 244, in wrapper
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     value = f(*args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/views/base_api.py", line 98, in wraps
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     return f(self, *args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/dashboards/api.py", line 1029, in import_
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     command.run()
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/dashboards/commands/importers/dispatcher.py", line 64, in run
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     raise exc
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/dashboards/commands/importers/dispatcher.py", line 57, in run
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     command.run()
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/commands/importers/v1/__init__.py", line 64, in run
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     self.validate()
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/commands/importers/v1/__init__.py", line 95, in validate
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     raise exception
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    | superset.commands.exceptions.CommandInvalidError: Error importing dashboard
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    | 2022-07-14 14:36:06,768:WARNING:superset.views.base:CommandException
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    | Traceback (most recent call last):
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1516, in full_dispatch_request
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     rv = self.dispatch_request()
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1502, in dispatch_request
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     return self.ensure_sync(self.view_functions[rule.endpoint])(**req.view_args)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/usr/local/lib/python3.8/site-packages/flask_appbuilder/security/decorators.py", line 89, in wraps
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     return f(self, *args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/views/base_api.py", line 113, in wraps
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     raise ex
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/views/base_api.py", line 110, in wraps
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     duration, response = time_function(f, self, *args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/utils/core.py", line 1533, in time_function
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     response = func(*args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/utils/log.py", line 244, in wrapper
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     value = f(*args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/views/base_api.py", line 98, in wraps
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     return f(self, *args, **kwargs)
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/dashboards/api.py", line 1029, in import_
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     command.run()
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/dashboards/commands/importers/dispatcher.py", line 64, in run
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     raise exc
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/dashboards/commands/importers/dispatcher.py", line 57, in run
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     command.run()
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/commands/importers/v1/__init__.py", line 64, in run
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     self.validate()
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |   File "/app/superset/commands/importers/v1/__init__.py", line 95, in validate
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    |     raise exception
superset_superset.1.uk4h0kabj1ru@xyz-asca-prod-swarm-2    | superset.commands.exceptions.CommandInvalidError: Error importing dashboard

Leave a Comment