This is an automated email from the ASF dual-hosted git repository. michaelsmolina pushed a commit to branch 5.0 in repository https://gitbox.apache.org/repos/asf/superset.git
commit e8246ea786c0387a843fede3c097d0dffcaf6b22 Author: Dmitry Kochnev <[email protected]> AuthorDate: Fri Feb 21 02:04:11 2025 +0300 fix: oauth2 trino (#31993) (cherry picked from commit 7ce1a3445c0e548d2099477b602162ee545f4d4f) --- superset/db_engine_specs/trino.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/superset/db_engine_specs/trino.py b/superset/db_engine_specs/trino.py index c7ae2b0f82..beb7c0a604 100644 --- a/superset/db_engine_specs/trino.py +++ b/superset/db_engine_specs/trino.py @@ -62,9 +62,7 @@ except ImportError: class CustomTrinoAuthErrorMeta(type): def __instancecheck__(cls, instance: object) -> bool: logger.info("is this being called?") - return isinstance( - instance, HttpError - ) and "error 401: b'Invalid credentials'" in str(instance) + return isinstance(instance, HttpError) and "error 401" in str(instance) class TrinoAuthError(HttpError, metaclass=CustomTrinoAuthErrorMeta):
