From 347d0d9cb089603a0a5a9029e3d3999f09bf209a Mon Sep 17 00:00:00 2001 From: Nulano Date: Wed, 27 Dec 2023 00:41:30 +0100 Subject: [PATCH] fix types hints for ImageFile._Tile --- pyproject.toml | 1 - src/PIL/ImageFile.py | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index ef0ff8a8ece..de707a2838b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -144,7 +144,6 @@ exclude = [ '^src/PIL/DdsImagePlugin.py$', '^src/PIL/FpxImagePlugin.py$', '^src/PIL/Image.py$', - '^src/PIL/ImageFile.py$', '^src/PIL/ImageMath.py$', '^src/PIL/ImageMorph.py$', '^src/PIL/ImageQt.py$', diff --git a/src/PIL/ImageFile.py b/src/PIL/ImageFile.py index ae4e23db17b..0923979af8b 100644 --- a/src/PIL/ImageFile.py +++ b/src/PIL/ImageFile.py @@ -32,7 +32,7 @@ import itertools import struct import sys -from typing import NamedTuple +from typing import Any, NamedTuple from . import Image from ._deprecate import deprecate @@ -94,7 +94,7 @@ class _Tile(NamedTuple): encoder_name: str extents: tuple[int, int, int, int] offset: int - args: tuple | str | None + args: tuple[Any, ...] | str | None #