From 5e0012569dd8a1251e71c21be6806fc12d6578a1 Mon Sep 17 00:00:00 2001 From: Jacob Walls Date: Fri, 6 Aug 2021 04:56:12 -0400 Subject: [PATCH] Change stub of Pillow.Image.new() to accept str for `color` argument (#5851) --- stubs/Pillow/PIL/Image.pyi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stubs/Pillow/PIL/Image.pyi b/stubs/Pillow/PIL/Image.pyi index 6f8ac1d40..98656a786 100644 --- a/stubs/Pillow/PIL/Image.pyi +++ b/stubs/Pillow/PIL/Image.pyi @@ -218,7 +218,7 @@ class Image: class ImagePointHandler: ... class ImageTransformHandler: ... -def new(mode: _Mode, size: tuple[int, int], color: float | Tuple[float, ...] = ...) -> Image: ... +def new(mode: _Mode, size: tuple[int, int], color: float | Tuple[float, ...] | str = ...) -> Image: ... def frombytes(mode: _Mode, size: tuple[int, int], data, decoder_name: str = ..., *args) -> Image: ... def frombuffer(mode: _Mode, size: tuple[int, int], data, decoder_name: str = ..., *args) -> Image: ... def fromarray(obj, mode: _Mode | None = ...) -> Image: ...