Title: `cfgparser.optionxform = str` gives erroneous error · Issue #1857 · python/typeshed · GitHub
Open Graph Title: `cfgparser.optionxform = str` gives erroneous error · Issue #1857 · python/typeshed
X Title: `cfgparser.optionxform = str` gives erroneous error · Issue #1857 · python/typeshed
Description: The example at https://docs.python.org/3.6/library/configparser.html#configparser.ConfigParser.optionxform on hpw to make ConfigParser option names gives a mypy error. (e2e) Adam@MacBook-Pro ~/Desktop> cat typeshed_example.py from config...
Open Graph Description: The example at https://docs.python.org/3.6/library/configparser.html#configparser.ConfigParser.optionxform on hpw to make ConfigParser option names gives a mypy error. (e2e) Adam@MacBook-Pro ~/Desk...
X Description: The example at https://docs.python.org/3.6/library/configparser.html#configparser.ConfigParser.optionxform on hpw to make ConfigParser option names gives a mypy error. (e2e) Adam@MacBook-Pro ~/Desk...
Opengraph URL: https://github.com/python/typeshed/issues/1857
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"`cfgparser.optionxform = str` gives erroneous error","articleBody":"The example at https://docs.python.org/3.6/library/configparser.html#configparser.ConfigParser.optionxform on hpw to make `ConfigParser` option names gives a `mypy` error.\r\n\r\n```console\r\n(e2e) Adam@MacBook-Pro ~/Desktop> cat typeshed_example.py \r\nfrom configparser import ConfigParser\r\n\r\ncfgparser = ConfigParser()\r\ncfgparser.optionxform = str\r\n(e2e) Adam@MacBook-Pro ~/Desktop> python --version\r\nPython 3.6.4\r\n(e2e) Adam@MacBook-Pro ~/Desktop> mypy typeshed_example.py --show-traceback\r\ntypeshed_example.py:4: error: Cannot assign to a method\r\ntypeshed_example.py:4: error: Incompatible types in assignment (expression has type \"Type[str]\", variable has type \"Callable[[str], str]\")\r\n(e2e) Adam@MacBook-Pro ~/Desktop> python typeshed_example.py \r\n(e2e) Adam@MacBook-Pro ~/Desktop> \r\n```","author":{"url":"https://github.com/adamtheturtle","@type":"Person","name":"adamtheturtle"},"datePublished":"2018-02-07T00:19:29Z","url":"https://github.com/python/typeshed/issues/1857"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| 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:a7e2ab65-d3e9-69ee-9d62-ded8d159f688 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BC9C:1B0A31:1C40D40:263353C:6B000987 |
| html-safe-nonce | b0381fb34f708693b19742575b77df4ad5aef70761a14e23690d6b5ffde5c975 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCQzlDOjFCMEEzMToxQzQwRDQwOjI2MzM1M0M6NkIwMDA5ODciLCJ2aXNpdG9yX2lkIjoiNjk0MDc5NzQzOTk2NDA4ODcxMiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | eb98fd9c6497f5782498d75747550239c05dea2786bf82952174720ba5fc8407 |
| hovercard-subject-tag | issue:294961100 |
| 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/python/typeshed/1857/issue_layout |
| twitter:image | https://opengraph.githubassets.com/cd778e38dd71970156fb6a54cddc666174f4e9e44defa4c4d33f45d3449ba10f/python/typeshed/issues/1857 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/cd778e38dd71970156fb6a54cddc666174f4e9e44defa4c4d33f45d3449ba10f/python/typeshed/issues/1857 |
| og:image:alt | The example at https://docs.python.org/3.6/library/configparser.html#configparser.ConfigParser.optionxform on hpw to make ConfigParser option names gives a mypy error. (e2e) Adam@MacBook-Pro ~/Desk... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | adamtheturtle |
| hostname | github.com |
| expected-hostname | github.com |
| None | 0a0d8686a27478df474dd7415776a7a080cde8838b3cd92ea7601187572e5729 |
| turbo-cache-control | no-preview |
| go-import | github.com/python/typeshed git https://github.com/python/typeshed.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 31696383 |
| octolytics-dimension-repository_nwo | python/typeshed |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 31696383 |
| octolytics-dimension-repository_network_root_nwo | python/typeshed |
| 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 | 16a11879678aaf97e2a42c33ee70830aa084fa37 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width