Title: ENH: Type the possible str legend locs as Literals by timhoffm · Pull Request #29465 · matplotlib/matplotlib · GitHub
Open Graph Title: ENH: Type the possible str legend locs as Literals by timhoffm · Pull Request #29465 · matplotlib/matplotlib
X Title: ENH: Type the possible str legend locs as Literals by timhoffm · Pull Request #29465 · matplotlib/matplotlib
Description: Instead of accepting any str, we only accept as set of predefined literals. For simplicity, we don't distinguish the between allowed positions for Axes legend and figure legend. It's still better to limit the allowed range to the union of both rather than to accept abitrary strings. This is a bit cumbersome, but since loc names are hard to remember and easy to misspell, I believe it's a real benefit if in-editor type checkers could notify on an invalid loc name.
Open Graph Description: Instead of accepting any str, we only accept as set of predefined literals. For simplicity, we don't distinguish the between allowed positions for Axes legend and figure legend. It's still ...
X Description: Instead of accepting any str, we only accept as set of predefined literals. For simplicity, we don't distinguish the between allowed positions for Axes legend and figure legend. It'...
Opengraph URL: https://github.com/matplotlib/matplotlib/pull/29465
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:0c6de52b-0e3a-71d9-e4cf-199e5b04ac44 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | D502:25680F:C1BBD4:10ACE83:6A520EA3 |
| html-safe-nonce | 96cddcfc66188cbfe973f9fe096701e20c2db53053b99c7ee764af4221b90d4d |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJENTAyOjI1NjgwRjpDMUJCRDQ6MTBBQ0U4Mzo2QTUyMEVBMyIsInZpc2l0b3JfaWQiOiI4ODE5MzgxMjM4NjEzODA2NzU1IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 5f2133a39bbb2e9904bb9355be3b297056e99a66ea0775824668f0fbe3e5cdc3 |
| hovercard-subject-tag | pull_request:2272516567 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/matplotlib/matplotlib/pull/29465/files |
| twitter:image | https://avatars.githubusercontent.com/u/2836374?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/2836374?s=400&v=4 |
| og:image:alt | Instead of accepting any str, we only accept as set of predefined literals. For simplicity, we don't distinguish the between allowed positions for Axes legend and figure legend. It's still ... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/matplotlib/matplotlib git https://github.com/matplotlib/matplotlib.git |
| octolytics-dimension-user_id | 215947 |
| octolytics-dimension-user_login | matplotlib |
| octolytics-dimension-repository_id | 1385122 |
| octolytics-dimension-repository_nwo | matplotlib/matplotlib |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1385122 |
| octolytics-dimension-repository_network_root_nwo | matplotlib/matplotlib |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 7aed05249554b889eb33d002851a973eebcc7e91 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width