Title: Annotation change from "s" to "text" in 3.0- documentation · Issue #12325 · matplotlib/matplotlib · GitHub
Open Graph Title: Annotation change from "s" to "text" in 3.0- documentation · Issue #12325 · matplotlib/matplotlib
X Title: Annotation change from "s" to "text" in 3.0- documentation · Issue #12325 · matplotlib/matplotlib
Description: Bug report Bug summary Annotation argument has changed from 2.2.3 to 3.0 but I do not think it has been fully documented. The documentation here is not to date with s still the keyword shown in parameter list (although it has text in the...
Open Graph Description: Bug report Bug summary Annotation argument has changed from 2.2.3 to 3.0 but I do not think it has been fully documented. The documentation here is not to date with s still the keyword shown in par...
X Description: Bug report Bug summary Annotation argument has changed from 2.2.3 to 3.0 but I do not think it has been fully documented. The documentation here is not to date with s still the keyword shown in par...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/12325
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Annotation change from \"s\" to \"text\" in 3.0- documentation","articleBody":"\r\n\r\n### Bug report\r\n\r\n**Bug summary**\r\nAnnotation argument has changed from 2.2.3 to 3.0 but I do not think it has been fully documented.\r\n\r\nThe documentation here is not to date with `s` still the keyword shown in parameter list (although it has `text` in the definition) https://matplotlib.org/api/_as_gen/matplotlib.axes.Axes.annotate.html#matplotlib.axes.Axes.annotate \r\n\r\n\r\n\r\n**Code for reproduction**\r\n\r\n```\r\n#!/usr/bin/env python\r\nimport matplotlib\r\nimport sys\r\nprint(sys.version)\r\nprint(matplotlib.__version__)\r\nimport matplotlib.pyplot as plt\r\n\r\nplt.figure()\r\na = plt.annotate(s=\"test\", xy=(0.5, 0.5))\r\nprint(a)\r\n```\r\n\r\n**Actual outcome**\r\nHere is the outcome in two different version of matplotlib.\r\n```\r\n/home/jneal/miniconda3/envs/py36/bin/python /home/jneal/Phd/Codes/annotatetest.py\r\n3.6.4 |Anaconda, Inc.| (default, Jan 16 2018, 18:10:19) \r\n[GCC 7.2.0]\r\n2.2.3\r\nAnnotation(0.5,0.5,'test')\r\n\r\nProcess finished with exit code 0\r\n```\r\nand\r\n```\r\n3.6.4 |Anaconda, Inc.| (default, Jan 16 2018, 18:10:19) \r\n[GCC 7.2.0]\r\n3.0.0\r\nTraceback (most recent call last):\r\n File \"annotatetest.py\", line 10, in \u003cmodule\u003e\r\n a = plt.annotate(s=\"test\", xy=(0.5, 0.5))\r\nTypeError: annotate() missing 1 required positional argument: 'text'\r\n```\r\n\r\n\r\n**Expected outcome**\r\nI did not expect it to have changed. \r\n\r\nIf I change `s` to `text` then I have the same problem in reverse if trying to use both versions\r\n( I do know that the arg name can be omitted)\r\n\r\n**Matplotlib version**\r\nconda installed matplotlib from conda-forge\r\n\u003c!--Please tell us how you installed matplotlib and python e.g., from source, pip, conda--\u003e\r\n\u003c!--If you installed from conda, please specify which channel you used if not the default--\u003e\r\n\r\n","author":{"url":"https://github.com/jason-neal","@type":"Person","name":"jason-neal"},"datePublished":"2018-09-28T17:45:34.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/12325/matplotlib/issues/12325"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:6b1ddd28-1aad-4fcf-3c9d-578ae7238931 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 9CF8:348621:761D43:9F0397:6A541857 |
| html-safe-nonce | 8ed39aa65c995a3fa9f3707bde92697b88f67060da23bacea31994e99fe13574 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5Q0Y4OjM0ODYyMTo3NjFENDM6OUYwMzk3OjZBNTQxODU3IiwidmlzaXRvcl9pZCI6IjE2ODYyMDU0NjY3Mzg3NTAzMSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 8de300b64fc900ad9dca96c9b3b73912038b701f6826614b79d574f8600027fd |
| hovercard-subject-tag | issue:364981938 |
| github-keyboard-shortcuts | repository,issues,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/_view_fragments/issues/show/matplotlib/matplotlib/12325/issue_layout |
| twitter:image | https://opengraph.githubassets.com/0defc34489341ea0c9997df4745e82e0dc7a687e0ca13466c3f53850e4d1d472/matplotlib/matplotlib/issues/12325 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/0defc34489341ea0c9997df4745e82e0dc7a687e0ca13466c3f53850e4d1d472/matplotlib/matplotlib/issues/12325 |
| og:image:alt | Bug report Bug summary Annotation argument has changed from 2.2.3 to 3.0 but I do not think it has been fully documented. The documentation here is not to date with s still the keyword shown in par... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | jason-neal |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-preview |
| 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 |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 07a982c1d40157c619b364352b704c3ce66bb332 |
| ui-target | canary-2 |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width