Skip to content

Pending warning for deprecated parameter 'vert' of box and violin on 3.10 #29159

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 27, 2024

Conversation

ksunden
Copy link
Member

@ksunden ksunden commented Nov 19, 2024

The new parameter, 'orientation', was only added in the current release, so downstream wanting to avoid warnings
would require version gates. Therefore delaying by at least one release to ease the transition.

This was motivated by Pandas failing tests on this warning.

This portion is made direct to v3.10.x with #29155 being the accompanying version to edit the deprecation on main.

PR summary

PR checklist

@QuLogic QuLogic added this to the v3.10.0 milestone Nov 20, 2024
@tacaswell
Copy link
Member

Per the discussion in #29155 I agree this should stay as "pending".

The new parameter, 'orientation', was only added in the current release, so downstream wanting to avoid warnings
would require version gates. Therefore delaying by at least one release to ease the transition.

This was motivated by Pandas failing tests on this warning.

This portion is made direct to v3.10.x with matplotlib#29155 being the accompanying version to edit the deprecation on main.

Reinstate warning as a pending warning

STY: fits on one line
@ksunden ksunden changed the title Delay warning for deprecated parameter 'vert' of box and violin on 3.10 Pending warning for deprecated parameter 'vert' of box and violin on 3.10 Nov 22, 2024
Copy link
Member

@timhoffm timhoffm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please check whether the message is consistent. Anybody can merge after that.

@@ -4361,9 +4365,10 @@ def merge_kw_rc(subkey, explicit, zdelta=0, usemarker=True):
vert = mpl.rcParams['boxplot.vertical']
else:
_api.warn_deprecated(
"3.10",
"3.11",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would have expected 3.10 here („pending depreciation in 3.10“) but am not sure what the message looks like („deprecated in 3.11“) would also be fine.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The version number actually does not appear in the Pending deprecation, apparently:

PendingDeprecationWarning: vert: bool will be deprecated in a future version. Use orientation: {'vertical', 'horizontal'} instead.

Personally I think this is fine, and leaving the intended deprecation version in source reduces change when actually deprecating (though in this case, it is already fully deprecated on main, so that much doesn't really matter)

@tacaswell tacaswell merged commit 824d2f2 into matplotlib:v3.10.x Nov 27, 2024
39 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants