Skip to content

Commit e46e9a4

Browse files
committed
Bump Python version to 3.13
1 parent e97f293 commit e46e9a4

File tree

6 files changed

+10
-11
lines changed

6 files changed

+10
-11
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
- name: Install uv
1616
uses: astral-sh/setup-uv@v4
1717
with:
18-
python-version: "3.12"
18+
python-version: "3.13"
1919

2020
- name: Install the project's dev dependencies
2121
# run: uv sync --dev --group test

.github/workflows/pages.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
- name: Install uv
2121
uses: astral-sh/setup-uv@v4
2222
with:
23-
python-version: "3.12"
23+
python-version: "3.13"
2424

2525
- name: Install the project's dev dependencies
2626
run: uv sync --group docs

.github/workflows/pypi-publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Install uv
1717
uses: astral-sh/setup-uv@v4
1818
with:
19-
python-version: "3.12"
19+
python-version: "3.13"
2020

2121
- name: Install the project with build deps
2222
run: uv sync

pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ classifiers = [
1414
"Programming Language :: Python :: 3.10",
1515
"Programming Language :: Python :: 3.11",
1616
"Programming Language :: Python :: 3.12",
17+
"Programming Language :: Python :: 3.13",
1718
"Programming Language :: Python :: 3 :: Only",
1819
"Topic :: Software Development :: Libraries :: Python Modules",
1920
]

tests/conftest.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,10 @@ def device() -> torch.device:
1414

1515

1616
@pytest.fixture()
17-
def data() -> (
18-
Callable[
19-
[Callable[[Image.Image | torch.Tensor], torch.Tensor]],
20-
tuple[torch.Tensor, torch.Tensor],
21-
]
22-
):
17+
def data() -> Callable[
18+
[Callable[[Image.Image | torch.Tensor], torch.Tensor]],
19+
tuple[torch.Tensor, torch.Tensor],
20+
]:
2321
def _open_and_transform_image(
2422
transform: Callable[[Image.Image | torch.Tensor], torch.Tensor],
2523
) -> tuple[torch.Tensor, torch.Tensor]:

torchattack/_attack.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,13 +87,13 @@ def __eq__(self, other: Any) -> bool:
8787
continue
8888
self_val = getattr(self, attr)
8989
other_val = getattr(other, attr)
90-
90+
9191
if isinstance(self_val, torch.Tensor):
9292
if not isinstance(other_val, torch.Tensor):
9393
return False
9494
if not torch.equal(self_val, other_val):
9595
return False
9696
elif self_val != other_val:
9797
return False
98-
98+
9999
return True

0 commit comments

Comments
 (0)