diff --git a/src/datalab_api/_base.py b/src/datalab_api/_base.py index cbd7efe..b146986 100644 --- a/src/datalab_api/_base.py +++ b/src/datalab_api/_base.py @@ -35,7 +35,7 @@ class BaseDatalabClient(metaclass=AutoPrettyPrint): _api_key: Optional[str] = None _session: Optional[httpx.Client] = None - _headers: dict[str, str] = {} + _headers: dict[str, str] _timeout: httpx.Timeout = httpx.Timeout(10.0, read=60.0) interactive: bool = True @@ -85,7 +85,7 @@ def __init__(self, datalab_api_url: str, log_level: str = "WARNING"): self.log = logging.getLogger(__name__) self._http_client = httpx.Client - self._headers["User-Agent"] = f"Datalab Python API/{__version__}" + self._headers = {"User-Agent": f"Datalab Python API/{__version__}"} self._detect_api_url()