Title: false report of multiple definitions · Issue #649 · python/mypy · GitHub
Open Graph Title: false report of multiple definitions · Issue #649 · python/mypy
X Title: false report of multiple definitions · Issue #649 · python/mypy
Description: The following code in six fails to type check: try: advance_iterator = next except NameError: def advance_iterator(it): return it.next() next = advance_iterator .../lib/python3.4/site-packages/six.py, line 501: Name 'advance_iterator' al...
Open Graph Description: The following code in six fails to type check: try: advance_iterator = next except NameError: def advance_iterator(it): return it.next() next = advance_iterator .../lib/python3.4/site-packages/six....
X Description: The following code in six fails to type check: try: advance_iterator = next except NameError: def advance_iterator(it): return it.next() next = advance_iterator .../lib/python3.4/site-packages/six....
Mail addresses
notifications@github.com
Opengraph URL: https://github.com/python/mypy/issues/649
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"false report of multiple definitions","articleBody":"The following code in six fails to type check:\n\n``` python\ntry:\n advance_iterator = next\nexcept NameError:\n def advance_iterator(it):\n return it.next()\nnext = advance_iterator\n```\n\n.../lib/python3.4/site-packages/six.py, line 501: Name 'advance_iterator' already defined\n\nBut advance_iterator can't be already defined: for NameError to be thrown, the lookup of next must have failed.\n\nWhats the right way to handle this? Just mask it?\n","author":{"url":"https://github.com/rbtcollins","@type":"Person","name":"rbtcollins"},"datePublished":"2015-04-20T10:11:05Z","url":"https://github.com/python/mypy/issues/649"}
| 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:8499463c-69ba-efe3-61b5-19b6af0f764f |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E080:2F6A82:10842D0:159CE11:6B0005E7 |
| html-safe-nonce | 0b720509c8f82427a0ca78e8dd70716d6cb4d248b588dca55cac6e2b1ffbef8f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMDgwOjJGNkE4MjoxMDg0MkQwOjE1OUNFMTE6NkIwMDA1RTciLCJ2aXNpdG9yX2lkIjoiNDU5NjcyMDA2OTI0MDY4NjA1NSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | ecc3f8a8a36d0c23b1fdb2b75bc34fcff18454643f997fc2c04a9e5e3ca6417d |
| hovercard-subject-tag | issue:69553390 |
| 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/649/issue_layout |
| twitter:image | https://opengraph.githubassets.com/08cfb37d23636be2ebe86026e7c2229374a6777f9ee0a823893d017b334670e1/python/mypy/issues/649 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/08cfb37d23636be2ebe86026e7c2229374a6777f9ee0a823893d017b334670e1/python/mypy/issues/649 |
| og:image:alt | The following code in six fails to type check: try: advance_iterator = next except NameError: def advance_iterator(it): return it.next() next = advance_iterator .../lib/python3.4/site-packages/six.... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | rbtcollins |
| hostname | github.com |
| expected-hostname | github.com |
| None | 0a0d8686a27478df474dd7415776a7a080cde8838b3cd92ea7601187572e5729 |
| 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 | 16a11879678aaf97e2a42c33ee70830aa084fa37 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width