File tree Expand file tree Collapse file tree 3 files changed +9
-23
lines changed Expand file tree Collapse file tree 3 files changed +9
-23
lines changed Original file line number Diff line number Diff line change @@ -1115,14 +1115,6 @@ def test_repr_jpeg_error_returns_none(self) -> None:
1115
1115
1116
1116
assert im ._repr_jpeg_ () is None
1117
1117
1118
- def test_deprecation (self ) -> None :
1119
- with Image .open (TEST_FILE ) as im :
1120
- assert isinstance (im , JpegImagePlugin .JpegImageFile )
1121
- with pytest .warns (DeprecationWarning , match = "huffman_ac" ):
1122
- assert im .huffman_ac == {}
1123
- with pytest .warns (DeprecationWarning , match = "huffman_dc" ):
1124
- assert im .huffman_dc == {}
1125
-
1126
1118
1127
1119
@pytest .mark .skipif (not is_win32 (), reason = "Windows only" )
1128
1120
@skip_unless_feature ("jpg" )
Original file line number Diff line number Diff line change @@ -122,14 +122,6 @@ The ``options`` parameter in :py:meth:`~PIL.ImageMath.lambda_eval()` and
122
122
:py:meth: `~PIL.ImageMath.unsafe_eval() ` has been deprecated. One or more keyword
123
123
arguments can be used instead.
124
124
125
- JpegImageFile.huffman_ac and JpegImageFile.huffman_dc
126
- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
127
-
128
- .. deprecated :: 11.0.0
129
-
130
- The ``huffman_ac `` and ``huffman_dc `` dictionaries on JPEG images were unused. They
131
- have been deprecated, and will be removed in Pillow 12 (2025-10-15).
132
-
133
125
Specific WebP feature checks
134
126
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
135
127
@@ -223,6 +215,15 @@ Image isImageType()
223
215
``Image.isImageType(im) `` has been removed. Use ``isinstance(im, Image.Image) ``
224
216
instead.
225
217
218
+ JpegImageFile.huffman_ac and JpegImageFile.huffman_dc
219
+ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
220
+
221
+ .. deprecated :: 11.0.0
222
+ .. versionremoved :: 12.0.0
223
+
224
+ The ``huffman_ac `` and ``huffman_dc `` dictionaries on JPEG images were unused. They
225
+ have been deprecated, and will be removed in Pillow 12 (2025-10-15).
226
+
226
227
TiffImagePlugin IFD_LEGACY_API
227
228
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
228
229
Original file line number Diff line number Diff line change 49
49
from ._binary import i32be as i32
50
50
from ._binary import o8
51
51
from ._binary import o16be as o16
52
- from ._deprecate import deprecate
53
52
from .JpegPresets import presets
54
53
55
54
TYPE_CHECKING = False
@@ -393,12 +392,6 @@ def _open(self) -> None:
393
392
394
393
self ._read_dpi_from_exif ()
395
394
396
- def __getattr__ (self , name : str ) -> Any :
397
- if name in ("huffman_ac" , "huffman_dc" ):
398
- deprecate (name , 12 )
399
- return getattr (self , "_" + name )
400
- raise AttributeError (name )
401
-
402
395
def __getstate__ (self ) -> list [Any ]:
403
396
return super ().__getstate__ () + [self .layers , self .layer ]
404
397
You can’t perform that action at this time.
0 commit comments