You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a superset instance running SSO (configuration is done using the official Helm Chart), but I cannot get the export-roles to work. The error I get:
Traceback (most recent call last):
File "/Users/wards/git/superset/scripts/.venv/bin/superset-cli", line 8, in <module>
sys.exit(superset_cli())
^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/click/core.py", line 1157, in __call__
return self.main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
^^^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/click/core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/click/decorators.py", line 33, in new_func
return f(get_current_context(), *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/preset_cli/cli/superset/export.py", line 257, in export_roles
yaml.dump(list(client.export_roles()), output)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/preset_cli/api/clients/superset.py", line 841, in export_roles
user_email_map = {user["id"]: user["email"] for user in self.export_users()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/preset_cli/api/clients/superset.py", line 841, in <dictcomp>
user_email_map = {user["id"]: user["email"] for user in self.export_users()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/wards/git/superset/scripts/.venv/lib/python3.11/site-packages/preset_cli/api/clients/superset.py", line 821, in _export_users_superset
table = soup.find_all("table")[1]
~~~~~~~~~~~~~~~~~~~~~~^^^
IndexError: list index out of range
After some investigation, it turns out this is because the List users page returns a # page to our SSO. When using superset-cli to export databases and datasets, this doesn't pose a problem (because the admin credentials are still valid on the API), however sign-in to view the CRUD page for users doesn't work.
Possible Resolution
When activating FAB_ADD_SECURITY_API = True in superset_config.py, you can get the active roles from the security API:
https://<superset>/api/v1/security/roles/
The text was updated successfully, but these errors were encountered:
I have a superset instance running SSO (configuration is done using the official Helm Chart), but I cannot get the export-roles to work. The error I get:
After some investigation, it turns out this is because the List users page returns a # page to our SSO. When using
superset-cli
to export databases and datasets, this doesn't pose a problem (because the admin credentials are still valid on the API), however sign-in to view the CRUD page for users doesn't work.Possible Resolution
When activating
FAB_ADD_SECURITY_API = True
insuperset_config.py
, you can get the active roles from the security API:https://<superset>/api/v1/security/roles/
The text was updated successfully, but these errors were encountered: