Improve gateway reliability and dashboard docs

This commit is contained in:
Joseph Doherty
2026-04-28 00:13:22 -04:00
parent bd4a09a35e
commit 4fc355b357
61 changed files with 1722 additions and 150 deletions
+9 -1
View File
@@ -19,6 +19,8 @@ class ClientOptions:
plaintext: bool = False
ca_file: str | None = None
server_name_override: str | None = None
call_timeout: float | None = 30.0
stream_timeout: float | None = None
def __post_init__(self) -> None:
if not self.endpoint:
@@ -26,6 +28,10 @@ class ClientOptions:
if self.plaintext and self.ca_file:
raise ValueError("ca_file cannot be used with plaintext connections")
if self.call_timeout is not None and self.call_timeout <= 0:
raise ValueError("call_timeout must be greater than zero")
if self.stream_timeout is not None and self.stream_timeout <= 0:
raise ValueError("stream_timeout must be greater than zero")
def __repr__(self) -> str:
api_key = REDACTED if self.api_key else None
@@ -33,7 +39,9 @@ class ClientOptions:
f"{type(self).__name__}(endpoint={self.endpoint!r}, "
f"api_key={api_key!r}, plaintext={self.plaintext!r}, "
f"ca_file={self.ca_file!r}, "
f"server_name_override={self.server_name_override!r})"
f"server_name_override={self.server_name_override!r}, "
f"call_timeout={self.call_timeout!r}, "
f"stream_timeout={self.stream_timeout!r})"
)