Title: typing tests: Not all subclass cases are covered · Issue #96769 · python/cpython · GitHub
Open Graph Title: typing tests: Not all subclass cases are covered · Issue #96769 · python/cpython
X Title: typing tests: Not all subclass cases are covered · Issue #96769 · python/cpython
Description: There are a lot of test cases in test_typing.py where we test that different typing things cannot be used as base classes. However, there are multiple missing cases. Examples: Final / Final[int] is not tested to be invalid base class: cp...
Open Graph Description: There are a lot of test cases in test_typing.py where we test that different typing things cannot be used as base classes. However, there are multiple missing cases. Examples: Final / Final[int] is...
X Description: There are a lot of test cases in test_typing.py where we test that different typing things cannot be used as base classes. However, there are multiple missing cases. Examples: Final / Final[int] is...
Opengraph URL: https://github.com/python/cpython/issues/96769
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"typing tests: Not all subclass cases are covered","articleBody":"There are a lot of test cases in `test_typing.py` where we test that different typing things cannot be used as base classes. However, there are multiple missing cases. Examples:\r\n- `Final` / `Final[int]` is not tested to be invalid base class: https://github.com/python/cpython/blob/53a54b781d1f05f2d0b40ce88b3da92d5d23e9d2/Lib/test/test_typing.py#L3748-L3756\r\n- `Ts` is tested, but `*Ts` is not: https://github.com/python/cpython/blob/53a54b781d1f05f2d0b40ce88b3da92d5d23e9d2/Lib/test/test_typing.py#L1039\r\n- Different special forms only tested with / or without `[]`\r\n- And other issues\r\n\r\nI think this should be all covered. I went through all subtyping tests and added more cases.\r\nI will send a PR :)","author":{"url":"https://github.com/sobolevn","@type":"Person","name":"sobolevn"},"datePublished":"2022-09-12T10:43:36.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":2},"url":"https://github.com/96769/cpython/issues/96769"}
| 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:cc7d165c-fa77-a8df-de7b-bf6d87370f17 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | DA5A:148AF3:4A5CC8:60FA64:696B427A |
| html-safe-nonce | 66907d8357f911f1d1c74ff26ef81335dd58df903c1f49a234f1eed0dfcaf36b |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEQTVBOjE0OEFGMzo0QTVDQzg6NjBGQTY0OjY5NkI0MjdBIiwidmlzaXRvcl9pZCI6Ijg0NDYyNzgwNDM3NzU0ODQ1MzkiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | b66081f07c31c9c9ef7502fd57ae423e6c427f14804ecdcbdc8a0f6aeab5e4f5 |
| hovercard-subject-tag | issue:1369665448 |
| 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/cpython/96769/issue_layout |
| twitter:image | https://opengraph.githubassets.com/e5dc799cbd6bb068ffc4ebae0c0feff61799eefbf88035587943feeab2f92c74/python/cpython/issues/96769 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/e5dc799cbd6bb068ffc4ebae0c0feff61799eefbf88035587943feeab2f92c74/python/cpython/issues/96769 |
| og:image:alt | There are a lot of test cases in test_typing.py where we test that different typing things cannot be used as base classes. However, there are multiple missing cases. Examples: Final / Final[int] is... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | sobolevn |
| hostname | github.com |
| expected-hostname | github.com |
| None | 5f99f7c1d70f01da5b93e5ca90303359738944d8ab470e396496262c66e60b8d |
| turbo-cache-control | no-preview |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| 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 | 82560a55c6b2054555076f46e683151ee28a19bc |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width