From 5b9c2c59b231c7e000e050bd94f6f9bf58bcc201 Mon Sep 17 00:00:00 2001 From: Jac Fitzgerald Date: Tue, 28 Jul 2026 22:52:00 -0700 Subject: [PATCH] chore: move Concatenate/ParamSpec/overload from typing_extensions to typing These three names live in stdlib `typing` since Python 3.10, which is the repo's supported minimum (`requires-python = ">=3.10"`). Only `Self` still requires `typing_extensions` for 3.10 users, so keep that import in place until 3.10 support drops. Also drop `py39` from Black's `target-version` array and add `py314` -- py39 is below the supported minimum, py314 is already in the CI test matrix. No behavior change. Co-Authored-By: Claude Opus 4.7 (1M context) --- pyproject.toml | 2 +- tableauserverclient/server/endpoint/endpoint.py | 3 ++- tableauserverclient/server/endpoint/jobs_endpoint.py | 3 ++- tableauserverclient/server/request_factory.py | 5 +---- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index e5a330c39..e8d4d9ae6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -49,7 +49,7 @@ version = {attr = "versioneer.get_version"} [tool.black] line-length = 120 -target-version = ['py39', 'py310', 'py311', 'py312', 'py313'] +target-version = ['py310', 'py311', 'py312', 'py313', 'py314'] force-exclude = "tableauserverclient/bin/*" [tool.mypy] diff --git a/tableauserverclient/server/endpoint/endpoint.py b/tableauserverclient/server/endpoint/endpoint.py index 31a0806dc..7a2705299 100644 --- a/tableauserverclient/server/endpoint/endpoint.py +++ b/tableauserverclient/server/endpoint/endpoint.py @@ -2,7 +2,6 @@ import io import os from contextlib import closing -from typing_extensions import Concatenate, ParamSpec from tableauserverclient import datetime_helpers as datetime import abc @@ -12,8 +11,10 @@ from typing import ( Any, Callable, + Concatenate, Generic, Optional, + ParamSpec, TYPE_CHECKING, TypeVar, Union, diff --git a/tableauserverclient/server/endpoint/jobs_endpoint.py b/tableauserverclient/server/endpoint/jobs_endpoint.py index 655b7cc6f..d790c036d 100644 --- a/tableauserverclient/server/endpoint/jobs_endpoint.py +++ b/tableauserverclient/server/endpoint/jobs_endpoint.py @@ -1,5 +1,6 @@ import logging -from typing_extensions import Self, overload +from typing import overload +from typing_extensions import Self from tableauserverclient.models import JobItem, BackgroundJobItem, PaginationItem diff --git a/tableauserverclient/server/request_factory.py b/tableauserverclient/server/request_factory.py index fc4694c01..c78450aa2 100644 --- a/tableauserverclient/server/request_factory.py +++ b/tableauserverclient/server/request_factory.py @@ -1,12 +1,9 @@ import xml.etree.ElementTree as ET -from typing import Any, Callable, TypeVar, TYPE_CHECKING +from typing import Any, Callable, Concatenate, ParamSpec, TypeVar, TYPE_CHECKING from collections.abc import Iterable -from typing_extensions import ParamSpec - from requests.packages.urllib3.fields import RequestField from requests.packages.urllib3.filepost import encode_multipart_formdata -from typing_extensions import Concatenate from tableauserverclient.models import *