Use API authentication instead of token scraping#379
Open
joaopamaral wants to merge 22 commits into
Open
Conversation
Add move methods to SupersetClient
Add new line
Reintroduce API authentication instead of token scraping
Vitor-Avila
reviewed
Apr 7, 2026
Contributor
|
also unsure why the CI haven't completed, but hopefully that's fixed with a new commit |
Author
|
@Vitor-Avila, can you test with db one? I've only validated with ldap. Thanks |
Vitor-Avila
reviewed
Apr 22, 2026
Vitor-Avila
left a comment
Contributor
There was a problem hiding this comment.
Left some comments.
Tests are still failing as well, let me know if you can see the errors, or if you want me to share here.
Thanks!
Try the security API first; on failure, log a warning and use the previous BeautifulSoup-based /login/ flow so older Superset instances keep working. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Author
|
hey @Vitor-Avila, addressed the comments, added the fallback to html approach |
Rename mocker.patch return value from UsernamePasswordAuth to username_password_auth to satisfy snake_case style. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Contributor
|
hey @joaopamaral tests are failing, can you please review? Thanks! |
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Resolve conflict in tests/cli/superset/main_test.py by adopting upstream's substring-based assertions for `superset export --help`. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Author
|
Sorry @Vitor-Avila, applied black formatting |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replace the HTML-scraping-based authentication with Superset's official security API endpoints.
Previously, UsernamePasswordAuth authenticated by:
This was fragile and dependent on Superset's frontend HTML structure. The new approach uses the documented REST API:
It was initially proposed in #319 (but I forgot to address the comments, sorry @Vitor-Avila)