Title: fix: do not narrow expression type to TypeVar on equality comparison by ordinary9843 · Pull Request #21209 · python/mypy · GitHub
Open Graph Title: fix: do not narrow expression type to TypeVar on equality comparison by ordinary9843 · Pull Request #21209 · python/mypy
X Title: fix: do not narrow expression type to TypeVar on equality comparison by ordinary9843 · Pull Request #21209 · python/mypy
Description: Optional static typing for Python. Contribute to python/mypy development by creating an account on GitHub.
Open Graph Description: When a variable is compared with == against a TypeVar operand, mypy was narrowing the left-hand variable to the TypeVar type. This caused false errors on subsequent operations — for example, x: int...
X Description: When a variable is compared with == against a TypeVar operand, mypy was narrowing the left-hand variable to the TypeVar type. This caused false errors on subsequent operations — for example, x: int...
Opengraph URL: https://github.com/python/mypy/pull/21209
X: @github
Domain: github.com
| route-pattern | /_view_fragments/voltron/pull_requests/show/:user_id/:repository/:id/pull_request_layout(.:format) |
| route-controller | voltron_pull_requests_fragments |
| route-action | pull_request_layout |
| fetch-nonce | v2:68857223-eb28-fa17-e271-79a059725107 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | A952:7A008:BB36D6:FDDE71:6A593730 |
| html-safe-nonce | 8ede4599828754df95359780bcae1b44bc6bfa9151c6f8838ec532bb21a956f3 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBOTUyOjdBMDA4OkJCMzZENjpGRERFNzE6NkE1OTM3MzAiLCJ2aXNpdG9yX2lkIjoiOTAzMjExODQ1OTIwODEyMDExMiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 75ac144a1038117955314dab2a818a56d5a442842a5a67c6d0e2e110e34b5959 |
| hovercard-subject-tag | pull_request:3521602726 |
| 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/_view_fragments/voltron/pull_requests/show/python/mypy/21209/pull_request_layout |
| twitter:image | https://opengraph.githubassets.com/0f0e4835675965ca4116b8b0d6a294ebdac325d8a70b78495683a420deb2f196/python/mypy/pull/21209 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/0f0e4835675965ca4116b8b0d6a294ebdac325d8a70b78495683a420deb2f196/python/mypy/pull/21209 |
| og:image:alt | When a variable is compared with == against a TypeVar operand, mypy was narrowing the left-hand variable to the TypeVar type. This caused false errors on subsequent operations — for example, x: int... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ordinary9843 |
| hostname | github.com |
| expected-hostname | github.com |
| None | 1b31c9453e1607b2781513084b4770f67217e549834c85b76960d7b13626f7c8 |
| turbo-cache-control | no-cache |
| 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 | 220f27779da5b92b5e17fcaef93e474cc8affba3 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width