From 77ab039e3291383f596d294aa331645860d22b4d Mon Sep 17 00:00:00 2001 From: Jordan Woods <13803242+jorwoods@users.noreply.github.com> Date: Wed, 23 Jul 2025 07:23:32 -0500 Subject: [PATCH 1/2] feat: SiteAuthConfiguration str and repr Gives SiteAuthConfiguration methods for str and repr calls to ensure consistent display of the object. --- tableauserverclient/models/site_item.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tableauserverclient/models/site_item.py b/tableauserverclient/models/site_item.py index ab65b97b..7d87cc53 100644 --- a/tableauserverclient/models/site_item.py +++ b/tableauserverclient/models/site_item.py @@ -1215,6 +1215,16 @@ def from_response(cls, resp: bytes, ns: dict) -> list["SiteAuthConfiguration"]: all_auth_configs.append(auth_config) return all_auth_configs + def __str__(self): + return ( + f"{self.__class__.__qualname__}(auth_setting={self.auth_setting}, " + f"enabled={self.enabled}, " + f"idp_configuration_id={self.idp_configuration_id}, " + f"idp_configuration_name={self.idp_configuration_name})" + ) + + def __repr__(self): + return f"<{str(self)}>" # Used to convert string represented boolean to a boolean type def string_to_bool(s: str) -> bool: From e233ce7e00e6cbf42959931d6ebcdc8b02fa1e87 Mon Sep 17 00:00:00 2001 From: Jordan Woods <13803242+jorwoods@users.noreply.github.com> Date: Wed, 23 Jul 2025 07:28:12 -0500 Subject: [PATCH 2/2] style: black --- tableauserverclient/models/site_item.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tableauserverclient/models/site_item.py b/tableauserverclient/models/site_item.py index 7d87cc53..2bf53144 100644 --- a/tableauserverclient/models/site_item.py +++ b/tableauserverclient/models/site_item.py @@ -1224,7 +1224,8 @@ def __str__(self): ) def __repr__(self): - return f"<{str(self)}>" + return f"<{str(self)}>" + # Used to convert string represented boolean to a boolean type def string_to_bool(s: str) -> bool: