Title: concurrent.futures.wait stub uses a tuple instead of DoneAndNotDoneFutures · Issue #1976 · python/typeshed · GitHub
Open Graph Title: concurrent.futures.wait stub uses a tuple instead of DoneAndNotDoneFutures · Issue #1976 · python/typeshed
X Title: concurrent.futures.wait stub uses a tuple instead of DoneAndNotDoneFutures · Issue #1976 · python/typeshed
Description: The definition of wait indicates that it returns Tuple[Set[Future[_T]], Set[Future[_T]]]. The actual return type is a DoneAndNotDoneFutures namedtuple. The problem with this is that the type inference is not able to determine that done a...
Open Graph Description: The definition of wait indicates that it returns Tuple[Set[Future[_T]], Set[Future[_T]]]. The actual return type is a DoneAndNotDoneFutures namedtuple. The problem with this is that the type infere...
X Description: The definition of wait indicates that it returns Tuple[Set[Future[_T]], Set[Future[_T]]]. The actual return type is a DoneAndNotDoneFutures namedtuple. The problem with this is that the type infere...
Opengraph URL: https://github.com/python/typeshed/issues/1976
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"concurrent.futures.wait stub uses a tuple instead of DoneAndNotDoneFutures","articleBody":"The [definition of wait](https://github.com/python/typeshed/blob/2c6296034fc107689c489b973e82959fe7d06807/stdlib/3/concurrent/futures/_base.pyi#L43) indicates that it returns `Tuple[Set[Future[_T]], Set[Future[_T]]]`. The actual return type is [a DoneAndNotDoneFutures namedtuple](https://github.com/python/cpython/blob/master/Lib/concurrent/futures/_base.py#L307).\r\n\r\nThe problem with this is that the type inference is not able to determine that `done` and `not_done` are members of the tuple. If you use the namedtuple by indexing it then type checking works, however I find that compromises readability.\r\n\r\nThere is a definition for `DoneAndNotDoneFutures` in the same file which appears to be unused, so perhaps it was overlooked?","author":{"url":"https://github.com/bw-matthew","@type":"Person","name":"bw-matthew"},"datePublished":"2018-03-21T12:22:31Z","url":"https://github.com/python/typeshed/issues/1976"}
| 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:1cecc839-1432-bd1b-ca97-7862c2fe51a0 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A9C8:18FDF5:458645:5D3327:6B002BB3 |
| html-safe-nonce | c8932207c671f00a33fb7f8027753c7192c2780dd64ff5385861d25404813893 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBOUM4OjE4RkRGNTo0NTg2NDU6NUQzMzI3OjZCMDAyQkIzIiwidmlzaXRvcl9pZCI6IjI1NDY2NzMwOTcyODk3NzE5NTUiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | afc9d6581c8cff59f7f191c62255e8c8304e76fc6303d8a69290657b13d664c0 |
| hovercard-subject-tag | issue:307222828 |
| 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/1976/issue_layout |
| twitter:image | https://opengraph.githubassets.com/96da67ce11f3d16ccf3a8287b3e492fb7c8bbfa4603bc7fce5d0e6c0a8e19b92/python/typeshed/issues/1976 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/96da67ce11f3d16ccf3a8287b3e492fb7c8bbfa4603bc7fce5d0e6c0a8e19b92/python/typeshed/issues/1976 |
| og:image:alt | The definition of wait indicates that it returns Tuple[Set[Future[_T]], Set[Future[_T]]]. The actual return type is a DoneAndNotDoneFutures namedtuple. The problem with this is that the type infere... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | bw-matthew |
| hostname | github.com |
| expected-hostname | github.com |
| None | 7d0829bbde9e48b2486cb5dd6d147896eb01d32134627091f818958a935ef3f0 |
| 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 | f3f3a43ca095cdea3abbb394112e971f9fdb94fa |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width