Skip to content

Commit 07df70c

Browse files
Use Python >= 3.10 type hints
1 parent 3db1b66 commit 07df70c

File tree

4 files changed

+18
-25
lines changed

4 files changed

+18
-25
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
runs-on: ubuntu-latest
3232
strategy:
3333
matrix:
34-
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
34+
python-version: ['3.10', '3.11', '3.12', '3.13', '3.14']
3535
steps:
3636
- uses: actions/checkout@v6
3737
- uses: actions/setup-python@v6

.github/workflows/e2e-test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,8 @@ on:
5555
- dev
5656

5757
env:
58-
DEFAULT_PYTHON_VERSION: "3.10"
59-
EOL_PYTHON_VERSION: "3.9"
58+
DEFAULT_PYTHON_VERSION: "3.13"
59+
EOL_PYTHON_VERSION: "3.10"
6060
EXIT_STATUS: 0
6161

6262
jobs:

linode_api4/objects/linode.py

Lines changed: 12 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1243,29 +1243,21 @@ def _func(value):
12431243

12441244
return password
12451245

1246-
ConfigCreateDevice = Union["Disk", "Volume", Dict[str, Any]]
1247-
ConfigCreateDisk = Union["Disk", int]
1248-
ConfigCreateVolume = Union["Volume", int]
1249-
12501246
# create derived objects
12511247
def config_create(
12521248
self,
1253-
kernel: Optional[Union[Kernel, str]] = None,
1254-
label: Optional[str] = None,
1255-
devices: Optional[
1256-
Union[
1257-
ConfigCreateDevice,
1258-
List[ConfigCreateDevice],
1259-
Dict[str, Any],
1260-
]
1261-
] = None,
1262-
disks: Optional[Union[ConfigCreateDisk, List[ConfigCreateDisk]]] = None,
1263-
volumes: Optional[
1264-
Union[ConfigCreateVolume, List[ConfigCreateVolume]]
1265-
] = None,
1266-
interfaces: Optional[
1267-
List[Union[ConfigInterface, Dict[str, Any]]]
1268-
] = None,
1249+
kernel: Kernel | str | None = None,
1250+
label: str | None = None,
1251+
devices: (
1252+
Union["Disk", "Volume", dict[str, Any]]
1253+
| list[Union["Disk", "Volume", dict[str, Any]]]
1254+
| None
1255+
) = None,
1256+
disks: Union["Disk", int] | list[Union["Disk", int]] | None = None,
1257+
volumes: (
1258+
Union["Volume", int] | list[Union["Volume", int]] | None
1259+
) = None,
1260+
interfaces: list[ConfigInterface | dict[str, Any]] | None = None,
12691261
**kwargs,
12701262
) -> Config:
12711263
"""

pyproject.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ name = "linode_api4"
88
authors = [{ name = "Linode", email = "devs@linode.com" }]
99
description = "The official Python SDK for Linode API v4"
1010
readme = "README.rst"
11-
requires-python = ">=3.9"
11+
requires-python = ">=3.10"
1212
keywords = [
1313
"akamai",
1414
"Akamai Connected Cloud",
@@ -25,10 +25,11 @@ classifiers = [
2525
"License :: OSI Approved :: BSD License",
2626
"Programming Language :: Python",
2727
"Programming Language :: Python :: 3",
28-
"Programming Language :: Python :: 3.9",
2928
"Programming Language :: Python :: 3.10",
3029
"Programming Language :: Python :: 3.11",
3130
"Programming Language :: Python :: 3.12",
31+
"Programming Language :: Python :: 3.13",
32+
"Programming Language :: Python :: 3.14",
3233
]
3334
dependencies = ["requests", "polling", "deprecated"]
3435
dynamic = ["version"]

0 commit comments

Comments
 (0)