Title: Implement PEP 585 (Generic builtins and __future__.annotations) · Issue #7907 · python/mypy · GitHub
Open Graph Title: Implement PEP 585 (Generic builtins and __future__.annotations) · Issue #7907 · python/mypy
X Title: Implement PEP 585 (Generic builtins and __future__.annotations) · Issue #7907 · python/mypy
Description: Are you reporting a bug, or opening a feature request? Reporting a bug Please insert below the code you are checking with mypy, or a mock-up repro if the source is private. We would appreciate if you try to simplify your case to a minima...
Open Graph Description: Are you reporting a bug, or opening a feature request? Reporting a bug Please insert below the code you are checking with mypy, or a mock-up repro if the source is private. We would appreciate if y...
X Description: Are you reporting a bug, or opening a feature request? Reporting a bug Please insert below the code you are checking with mypy, or a mock-up repro if the source is private. We would appreciate if y...
Opengraph URL: https://github.com/python/mypy/issues/7907
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Implement PEP 585 (Generic builtins and __future__.annotations)","articleBody":"* Are you reporting a bug, or opening a feature request? Reporting a bug\r\n* Please insert below the code you are checking with mypy,\r\n or a mock-up repro if the source is private. We would appreciate if you try to simplify your case to a minimal repro.\r\n```py\r\nfrom __future__ import annotations\r\nfrom collections import defaultdict\r\n\r\nsquares: defaultdict[tuple, int] = defaultdict(lambda: 999999)\r\n```\r\n* What is the actual behaviour/output? MyPy tells me `\"defaultdict\" is not subscriptable, use \"typing.DefaultDict\" instead`\r\n* What is the behaviour/output you expect? MyPy ignores the subscript error (and recognises it as equivalent) because of `from __future__ import annotations`\r\n* What is the version of mypy and Python you are using? 0.740 on 3.8.0 (Ubuntu 18.04)\r\n* No additional MyPy flags","author":{"url":"https://github.com/Starwort","@type":"Person","name":"Starwort"},"datePublished":"2019-11-08T16:26:19Z","url":"https://github.com/python/mypy/issues/7907"}
| 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:da9e9645-026c-3b05-9930-9f749fc2b297 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D03E:490F1:12E12C:1A4028:6B008252 |
| html-safe-nonce | 46f214a21366e31c72318d74e9ba6d2dba635b3aeb42dd743dccc62565830aca |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEMDNFOjQ5MEYxOjEyRTEyQzoxQTQwMjg6NkIwMDgyNTIiLCJ2aXNpdG9yX2lkIjoiODgwMjc4MDQyOTgxNjk4ODI0MiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 11ff910af06459ad72b2f9834017cf29b124262be8fbb81856c320a03003fd8a |
| hovercard-subject-tag | issue:520107984 |
| 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/mypy/7907/issue_layout |
| twitter:image | https://opengraph.githubassets.com/a47f4607aa0b243288b3b99eefcf496a6e761d09b771a408440b6769fd137486/python/mypy/issues/7907 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/a47f4607aa0b243288b3b99eefcf496a6e761d09b771a408440b6769fd137486/python/mypy/issues/7907 |
| og:image:alt | Are you reporting a bug, or opening a feature request? Reporting a bug Please insert below the code you are checking with mypy, or a mock-up repro if the source is private. We would appreciate if y... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Starwort |
| hostname | github.com |
| expected-hostname | github.com |
| None | 82c186f13e104004ab7bdb779f3195e59dd38bfde531aaa74b76470fc2462b83 |
| turbo-cache-control | no-preview |
| go-import | github.com/python/mypy git https://github.com/python/mypy.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 7053637 |
| octolytics-dimension-repository_nwo | python/mypy |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 7053637 |
| octolytics-dimension-repository_network_root_nwo | python/mypy |
| 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 | d1bc2aa1939001689f5ce935982c10a6138f745c |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width