diff --git a/PIL/_imaging.pyi b/PIL/_imaging.pyi index a8f20fe14..f5d691c7c 100644 --- a/PIL/_imaging.pyi +++ b/PIL/_imaging.pyi @@ -37,7 +37,7 @@ class ImagingCore: def getpixel(self, xy: XY) -> Optional[Any]: ... def putpixel(self, xy: XY, value: Any) -> None: ... - def pixel_access(self, readonly: bool) -> Any: ... + def pixel_access(self, readonly: int) -> Any: ... def convert(self, mode, dither, paletteimage): ... def convert2(self): ... ### diff --git a/src/PIL/Image.py b/src/PIL/Image.py index d5238209c..e36c711dc 100644 --- a/src/PIL/Image.py +++ b/src/PIL/Image.py @@ -553,7 +553,7 @@ class Image(object): self.palette = None # type: Optional[ImagePalette.ImagePalette] self.info = {} # type: Dict[Text, Any] self.category = NORMAL - self.readonly = 0 + self.readonly = 0 # type: int self.pyaccess = None @property