mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-05 23:06:17 +03:00
Merge branch 'main' into context_manager
This commit is contained in:
commit
988a1fe838
10
.github/workflows/wheels-dependencies.sh
vendored
10
.github/workflows/wheels-dependencies.sh
vendored
|
@ -38,16 +38,6 @@ BZIP2_VERSION=1.0.8
|
||||||
LIBXCB_VERSION=1.17.0
|
LIBXCB_VERSION=1.17.0
|
||||||
BROTLI_VERSION=1.1.0
|
BROTLI_VERSION=1.1.0
|
||||||
|
|
||||||
if [[ -n "$IS_MACOS" ]] && [[ "$CIBW_ARCHS" == "x86_64" ]]; then
|
|
||||||
function build_openjpeg {
|
|
||||||
local out_dir=$(fetch_unpack https://github.com/uclouvain/openjpeg/archive/v$OPENJPEG_VERSION.tar.gz openjpeg-$OPENJPEG_VERSION.tar.gz)
|
|
||||||
(cd $out_dir \
|
|
||||||
&& cmake -DCMAKE_INSTALL_PREFIX=$BUILD_PREFIX -DCMAKE_INSTALL_NAME_DIR=$BUILD_PREFIX/lib . \
|
|
||||||
&& make install)
|
|
||||||
touch openjpeg-stamp
|
|
||||||
}
|
|
||||||
fi
|
|
||||||
|
|
||||||
function build_brotli {
|
function build_brotli {
|
||||||
local cmake=$(get_modern_cmake)
|
local cmake=$(get_modern_cmake)
|
||||||
local out_dir=$(fetch_unpack https://github.com/google/brotli/archive/v$BROTLI_VERSION.tar.gz brotli-$BROTLI_VERSION.tar.gz)
|
local out_dir=$(fetch_unpack https://github.com/google/brotli/archive/v$BROTLI_VERSION.tar.gz brotli-$BROTLI_VERSION.tar.gz)
|
||||||
|
|
|
@ -70,6 +70,7 @@ repos:
|
||||||
rev: v0.20.2
|
rev: v0.20.2
|
||||||
hooks:
|
hooks:
|
||||||
- id: validate-pyproject
|
- id: validate-pyproject
|
||||||
|
additional_dependencies: [trove-classifiers>=2024.10.12]
|
||||||
|
|
||||||
- repo: https://github.com/tox-dev/tox-ini-fmt
|
- repo: https://github.com/tox-dev/tox-ini-fmt
|
||||||
rev: 1.4.1
|
rev: 1.4.1
|
||||||
|
|
|
@ -5,6 +5,15 @@ Changelog (Pillow)
|
||||||
11.0.0 (unreleased)
|
11.0.0 (unreleased)
|
||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
|
- Conditionally define ImageCms type hint to avoid requiring core #8197
|
||||||
|
[radarhere]
|
||||||
|
|
||||||
|
- Support writing LONG8 offsets in AppendingTiffWriter #8417
|
||||||
|
[radarhere]
|
||||||
|
|
||||||
|
- Use ImageFile.MAXBLOCK when saving TIFF images #8461
|
||||||
|
[radarhere]
|
||||||
|
|
||||||
- Do not close provided file handles with libtiff when saving #8458
|
- Do not close provided file handles with libtiff when saving #8458
|
||||||
[radarhere]
|
[radarhere]
|
||||||
|
|
||||||
|
|
|
@ -1,19 +1,6 @@
|
||||||
11.0.0
|
11.0.0
|
||||||
------
|
------
|
||||||
|
|
||||||
Security
|
|
||||||
========
|
|
||||||
|
|
||||||
TODO
|
|
||||||
^^^^
|
|
||||||
|
|
||||||
TODO
|
|
||||||
|
|
||||||
:cve:`YYYY-XXXXX`: TODO
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
TODO
|
|
||||||
|
|
||||||
Backwards Incompatible Changes
|
Backwards Incompatible Changes
|
||||||
==============================
|
==============================
|
||||||
|
|
||||||
|
@ -159,7 +146,7 @@ Python 3.13
|
||||||
|
|
||||||
Pillow 10.4.0 had wheels built against Python 3.13 beta, available as a preview to help
|
Pillow 10.4.0 had wheels built against Python 3.13 beta, available as a preview to help
|
||||||
others prepare for 3.13, and to ensure Pillow could be used immediately at the release
|
others prepare for 3.13, and to ensure Pillow could be used immediately at the release
|
||||||
of 3.13.0 final (2024-10-01, :pep:`719`).
|
of 3.13.0 final (2024-10-07, :pep:`719`).
|
||||||
|
|
||||||
Pillow 11.0.0 now officially supports Python 3.13.
|
Pillow 11.0.0 now officially supports Python 3.13.
|
||||||
|
|
||||||
|
|
|
@ -14,14 +14,14 @@ readme = "README.md"
|
||||||
keywords = [
|
keywords = [
|
||||||
"Imaging",
|
"Imaging",
|
||||||
]
|
]
|
||||||
license = { text = "HPND" }
|
license = { text = "MIT-CMU" }
|
||||||
authors = [
|
authors = [
|
||||||
{ name = "Jeffrey A. Clark", email = "aclark@aclark.net" },
|
{ name = "Jeffrey A. Clark", email = "aclark@aclark.net" },
|
||||||
]
|
]
|
||||||
requires-python = ">=3.9"
|
requires-python = ">=3.9"
|
||||||
classifiers = [
|
classifiers = [
|
||||||
"Development Status :: 6 - Mature",
|
"Development Status :: 6 - Mature",
|
||||||
"License :: OSI Approved :: Historical Permission Notice and Disclaimer (HPND)",
|
"License :: OSI Approved :: CMU License (MIT-CMU)",
|
||||||
"Programming Language :: Python :: 3 :: Only",
|
"Programming Language :: Python :: 3 :: Only",
|
||||||
"Programming Language :: Python :: 3.9",
|
"Programming Language :: Python :: 3.9",
|
||||||
"Programming Language :: Python :: 3.10",
|
"Programming Language :: Python :: 3.10",
|
||||||
|
|
|
@ -173,10 +173,10 @@ class _Operand:
|
||||||
return self.apply("rshift", self, other)
|
return self.apply("rshift", self, other)
|
||||||
|
|
||||||
# logical
|
# logical
|
||||||
def __eq__(self, other):
|
def __eq__(self, other: _Operand | float) -> _Operand: # type: ignore[override]
|
||||||
return self.apply("eq", self, other)
|
return self.apply("eq", self, other)
|
||||||
|
|
||||||
def __ne__(self, other):
|
def __ne__(self, other: _Operand | float) -> _Operand: # type: ignore[override]
|
||||||
return self.apply("ne", self, other)
|
return self.apply("ne", self, other)
|
||||||
|
|
||||||
def __lt__(self, other: _Operand | float) -> _Operand:
|
def __lt__(self, other: _Operand | float) -> _Operand:
|
||||||
|
|
|
@ -1194,11 +1194,11 @@ class TiffImageFile(ImageFile.ImageFile):
|
||||||
if not self._seek_check(frame):
|
if not self._seek_check(frame):
|
||||||
return
|
return
|
||||||
self._seek(frame)
|
self._seek(frame)
|
||||||
# Create a new core image object on second and
|
if self._im is not None and (
|
||||||
# subsequent frames in the image. Image may be
|
self.im.size != self._tile_size or self.im.mode != self.mode
|
||||||
# different size/mode.
|
):
|
||||||
Image._decompression_bomb_check(self._tile_size)
|
# The core image will no longer be used
|
||||||
self.im = Image.core.new(self.mode, self._tile_size)
|
self._im = None
|
||||||
|
|
||||||
def _seek(self, frame: int) -> None:
|
def _seek(self, frame: int) -> None:
|
||||||
if isinstance(self._fp, DeferredError):
|
if isinstance(self._fp, DeferredError):
|
||||||
|
@ -1282,6 +1282,7 @@ class TiffImageFile(ImageFile.ImageFile):
|
||||||
|
|
||||||
def load_prepare(self) -> None:
|
def load_prepare(self) -> None:
|
||||||
if self._im is None:
|
if self._im is None:
|
||||||
|
Image._decompression_bomb_check(self._tile_size)
|
||||||
self.im = Image.core.new(self.mode, self._tile_size)
|
self.im = Image.core.new(self.mode, self._tile_size)
|
||||||
ImageFile.ImageFile.load_prepare(self)
|
ImageFile.ImageFile.load_prepare(self)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user