Skip to content

Change exception types, improve argument checking, and cleanups in mpl_toolkits#23550

Merged
QuLogic merged 4 commits into
matplotlib:mainfrom
oscargus:mpltoolkitcleanups
Aug 5, 2022
Merged

Change exception types, improve argument checking, and cleanups in mpl_toolkits#23550
QuLogic merged 4 commits into
matplotlib:mainfrom
oscargus:mpltoolkitcleanups

Conversation

@oscargus

@oscargus oscargus commented Aug 4, 2022

Copy link
Copy Markdown
Member

PR Summary

Raise a more exact type.

Better argument checking.

Minor cleanups.

PR Checklist

Tests and Styling

  • Has pytest style unit tests (and pytest passes).
  • Is Flake 8 compliant (install flake8-docstrings and run flake8 --docstring-convention=all).

Documentation

  • [N/A] New features are documented, with examples if plot related.
  • [N/A] New features have an entry in doc/users/next_whats_new/ (follow instructions in README.rst there).
  • API changes documented in doc/api/next_api_changes/ (follow instructions in README.rst there).
  • Documentation is sphinx and numpydoc compliant (the docs should build without error).

@oscargus oscargus force-pushed the mpltoolkitcleanups branch 2 times, most recently from 00be652 to a95cf32 Compare August 4, 2022 09:44
@oscargus oscargus added Maintenance API: changes Changes to the public API, typically requiring deprecation. labels Aug 4, 2022
@oscargus oscargus force-pushed the mpltoolkitcleanups branch from a95cf32 to 3e8c347 Compare August 4, 2022 11:03
@oscargus oscargus changed the title Change exception types and cleanups Change exception types, improve argument checking, and cleanups Aug 4, 2022
@oscargus oscargus changed the title Change exception types, improve argument checking, and cleanups Change exception types, improve argument checking, and cleanups in mpl_toolkits Aug 4, 2022
@oscargus oscargus marked this pull request as ready for review August 4, 2022 11:53
@@ -48,6 +49,7 @@ def __init__(self, fig, pos, horizontal, vertical,
self._horizontal = horizontal
self._vertical = vertical
self._anchor = anchor

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Can drop this line now?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Won't some code quality tools complain if it is defined outside of __init__? That was the reason anyway.

Comment thread doc/api/next_api_changes/behavior/23550-OG.rst Outdated
@tacaswell tacaswell added this to the v3.6.0 milestone Aug 4, 2022
Comment thread lib/mpl_toolkits/axes_grid1/axes_divider.py Outdated
@oscargus oscargus force-pushed the mpltoolkitcleanups branch from 3e8c347 to ad27ad7 Compare August 4, 2022 20:21
@oscargus oscargus force-pushed the mpltoolkitcleanups branch from ad27ad7 to e94dfed Compare August 4, 2022 21:22
@QuLogic QuLogic merged commit 80d79eb into matplotlib:main Aug 5, 2022
@oscargus oscargus deleted the mpltoolkitcleanups branch August 5, 2022 08:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

API: changes Changes to the public API, typically requiring deprecation. Maintenance topic: mpl_toolkit

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants