Bug summary
The 'mode' parameter from Image.fromarray has been deprecated, which is used in matplotlib to plot figures using the tkinter backend.
Code for reproduction
# python -Wd
import matplotlib
from matplotlib import pyplot
matplotlib.use("tkagg")
pyplot.subplots()
Actual outcome
DeprecationWarning: 'mode' parameter is deprecated and will be removed in Pillow 13 (2026-10-15)
Expected outcome
No deprecation warning
Additional information
No response
Operating system
Ubuntu (this bug is also present on Windows)
Matplotlib Version
3.10.3 (pillow==11.3.0)
Matplotlib Backend
TkAgg
Python version
Python 3.12.4
Jupyter version
No response
Installation
None
Bug summary
The
'mode'parameter fromImage.fromarrayhas been deprecated, which is used in matplotlib to plot figures using the tkinter backend.Code for reproduction
Actual outcome
Expected outcome
No deprecation warning
Additional information
No response
Operating system
Ubuntu (this bug is also present on Windows)
Matplotlib Version
3.10.3 (pillow==11.3.0)
Matplotlib Backend
TkAgg
Python version
Python 3.12.4
Jupyter version
No response
Installation
None