Skip to content

Commit a5d95fe

Browse files
tacaswellQuLogic
authored andcommitted
DOC: add notes for removals
1 parent 6f9c155 commit a5d95fe

File tree

1 file changed

+104
-0
lines changed

1 file changed

+104
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
2+
Testing support
3+
~~~~~~~~~~~~~~~
4+
5+
``matplotlib.test()`` has been removed
6+
......................................
7+
8+
Run tests using ``pytest`` from the commandline instead. The variable
9+
``matplotlib.default_test_modules`` was only used for ``matplotlib.test()`` and
10+
is thus removed as well.
11+
12+
To test an installed copy, be sure to specify both ``matplotlib`` and
13+
``mpl_toolkits`` with ``--pyargs``::
14+
15+
python -m pytest --pyargs matplotlib.tests mpl_toolkits.tests
16+
17+
See :ref:`testing` for more details.
18+
19+
20+
21+
Auto-removal of grids by `~.Axes.pcolor` and `~.Axes.pcolormesh`
22+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
23+
24+
`~.Axes.pcolor` and `~.Axes.pcolormesh` previously remove any visible axes
25+
major grid. This behavior is removed; please explicitly call ``ax.grid(False)``
26+
to remove the grid.
27+
28+
29+
30+
Modification of ``Axes`` children sublists
31+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
32+
33+
See :ref:`Behavioural API Changes 3.5 - Axes children combined` for more
34+
information; modification of the following sublists is no longer supported:
35+
36+
* ``Axes.artists``
37+
* ``Axes.collections``
38+
* ``Axes.images``
39+
* ``Axes.lines``
40+
* ``Axes.patches``
41+
* ``Axes.tables``
42+
* ``Axes.texts``
43+
44+
To remove an Artist, use its `.Artist.remove` method. To add an Artist, use the
45+
corresponding ``Axes.add_*`` method.
46+
47+
48+
49+
``ConversionInterface.convert`` no longer accepts unitless values
50+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
51+
52+
Previously, custom subclasses of `.units.ConversionInterface` needed to
53+
implement a ``convert`` method that not only accepted instances of the unit,
54+
but also unitless values (which are passed through as is). This is no longer
55+
the case (``convert`` is never called with a unitless value), and such support
56+
in ``.StrCategoryConverter`` is removed. Likewise, the
57+
``.ConversionInterface.is_numlike`` helper is removed.
58+
59+
Consider calling `.Axis.convert_units` instead, which still supports unitless
60+
values.
61+
62+
63+
Normal list of `.Artist` objects now returned by `.HandlerLine2D.create_artists`
64+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
65+
66+
For Matplotlib 3.5 and 3.6 a proxy list was returned that simulated the return
67+
of `.HandlerLine2DCompound.create_artists`. Now a list containing only the
68+
single artist is return.
69+
70+
71+
rcParams will no longer cast inputs to str
72+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
73+
74+
rcParams that expect a (non-pathlike) str no longer cast non-str inputs using
75+
`str`. This will avoid confusing errors in subsequent code if e.g. a list input
76+
gets implicitly cast to a str.
77+
78+
79+
80+
Case-insensitive scales
81+
~~~~~~~~~~~~~~~~~~~~~~~
82+
83+
Previously, scales could be set case-insensitively (e.g.,
84+
``set_xscale("LoG")``). Now all builtin scales use lowercase names.
85+
86+
87+
88+
Support for ``nx1 = None`` or ``ny1 = None`` in ``AxesLocator`` and ``Divider.locate``
89+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
90+
91+
In `.axes_grid1.axes_divider`, various internal APIs no longer supports
92+
passing ``nx1 = None`` or ``ny1 = None`` to mean ``nx + 1`` or ``ny + 1``, in
93+
preparation for a possible future API which allows indexing and slicing of
94+
dividers (possibly ``divider[a:b] == divider.new_locator(a, b)``, but also
95+
``divider[a:] == divider.new_locator(a, <end>)``). The user-facing
96+
`.Divider.new_locator` API is unaffected -- it correctly normalizes ``nx1 =
97+
None`` and ``ny1 = None`` as needed.
98+
99+
100+
change signature of ``.FigureCanvasBase.enter_notify_event``
101+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
102+
103+
The *xy* parameter is now required and keyword only. This was deprecated in
104+
3.0 and originally slated to be removed in 3.5.

0 commit comments

Comments
 (0)