Skip to content

[seaborn] Fix misspelled orientation default in Plot.save/Plotter.save - #16714

Merged
srittau merged 1 commit into
python:mainfrom
Dhairya-007:seaborn-portrait-default
Nov 6, 2026
Merged

srittau merged 1 commit into
python:mainfrom
Dhairya-007:seaborn-portrait-default

Conversation

@Dhairya-007

Copy link
Copy Markdown
Contributor

Both Plot.save and Plotter.save declare orientation: str = "protrait".

The keyword-only parameters on these methods mirror matplotlib.backend_bases.FigureCanvasBase.print_figure, as the existing comment in Plotter.save notes. That parameter's default is "portrait":

>>> import inspect
>>> from matplotlib.backend_bases import FigureCanvasBase
>>> inspect.signature(FigureCanvasBase.print_figure).parameters["orientation"].default
'portrait'

seaborn's runtime signature for both methods is (self, loc, **kwargs), so stubtest has no orientation parameter to compare this default against and the typo went unnoticed. The value is still surfaced to users in IDE signature help and hover documentation.

…r.save`

Both `save` methods declared `orientation: str = "protrait"`. The
keyword-only parameters on these methods mirror
`matplotlib.backend_bases.FigureCanvasBase.print_figure`, whose
`orientation` default is `"portrait"`.

seaborn's runtime signature for both methods is `(self, loc, **kwargs)`,
so stubtest cannot compare this default against the implementation and
the typo went unnoticed. The value is still surfaced to users in IDE
signature help and hover documentation.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@srittau
srittau merged commit d4c38c0 into python:main Nov 6, 2026
74 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.

2 participants