Skip to content

Set colormap modification removal to 3.6. #19766

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
Mar 25, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions lib/matplotlib/colors.py
Original file line number Diff line number Diff line change
Expand Up @@ -557,10 +557,12 @@ def _warn_if_global_cmap_modified(cmap):
if getattr(cmap, '_global', False):
_api.warn_deprecated(
"3.3",
removal="3.6",
message="You are modifying the state of a globally registered "
"colormap. In future versions, you will not be able to "
"modify a registered colormap in-place. To remove this "
"warning, you can make a copy of the colormap first. "
"colormap. This has been deprecated since %(since)s and "
"%(removal)s, you will not be able to modify a "
"registered colormap in-place. To remove this warning, "
"you can make a copy of the colormap first. "
f'cmap = mpl.cm.get_cmap("{cmap.name}").copy()'
)

Expand Down