diff --git a/Makefile b/Makefile index 218711d..b92db7f 100644 --- a/Makefile +++ b/Makefile @@ -8,26 +8,6 @@ wheel: uvx pip wheel -w dist . .PHONY: test-release -test-release: wheel - uvx twine check dist/*airtrain*.whl - uvx twine upload --repository testpypi dist/*airtrain*.whl - -.PHONY: release -release: wheel - uvx twine check dist/*airtrain*.whl - uvx twine upload dist/*airtrain*.whl - -.PHONY: test-release -test-release: wheel - uvx twine check dist/*airtrain*.whl - uvx twine upload --repository testpypi dist/*airtrain*.whl - -.PHONY: release -release: wheel - uvx twine check dist/*airtrain*.whl - uvx twine upload dist/*airtrain*.whl - -.PHONY: test-release test-release: wheel uvx twine check dist/*airtrain*.whl uvx twine upload --repository testpypi dist/*airtrain*.whl diff --git a/src/airtrain/core.py b/src/airtrain/core.py index b638a21..02bb8ee 100644 --- a/src/airtrain/core.py +++ b/src/airtrain/core.py @@ -14,6 +14,14 @@ from airtrain.client import client +# Unpack is only >3.11 . We'll just rely on type +# checking in those versions to catch mistakes. +# This will make Unpack[CreationArgs] into +# Optional[Any] for lower versions, which should +# pass checks. +Unpack = Optional +CreationArgs = Any + if sys.version_info > (3, 11): from typing import TypedDict, Unpack @@ -21,15 +29,6 @@ class CreationArgs(TypedDict): name: Optional[str] embedding_column: Optional[str] -else: - # Unpack is only >3.11 . We'll just rely on type - # checking in those versions to catch mistakes. - # This will make Unpack[CreationArgs] into - # Optional[Any] for lower versions, which should - # pass checks. - Unpack = Optional - CreationArgs = Any - logger = logging.getLogger(__name__)