René's URL Explorer Experiment


Title: Recent multiprocessing.Queue change breaks existing annotations and reduces typing precision · Issue #4313 · python/typeshed · GitHub

Open Graph Title: Recent multiprocessing.Queue change breaks existing annotations and reduces typing precision · Issue #4313 · python/typeshed

X Title: Recent multiprocessing.Queue change breaks existing annotations and reduces typing precision · Issue #4313 · python/typeshed

Description: #4289 changed multiprocessing.Queue from a class to a function. This matches the implementation, but this has some possibly unanticipated side effects, as discussed in python/mypy#9100. Here's a summary of the points raised in the linked...

Open Graph Description: #4289 changed multiprocessing.Queue from a class to a function. This matches the implementation, but this has some possibly unanticipated side effects, as discussed in python/mypy#9100. Here's a su...

X Description: #4289 changed multiprocessing.Queue from a class to a function. This matches the implementation, but this has some possibly unanticipated side effects, as discussed in python/mypy#9100. Here's ...

Opengraph URL: https://github.com/python/typeshed/issues/4313

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Recent multiprocessing.Queue change breaks existing annotations and reduces typing precision","articleBody":"#4289 changed `multiprocessing.Queue` from a class to a function. This matches the implementation, but this has some possibly unanticipated side effects, as discussed in https://github.com/python/mypy/pull/9100. Here's a summary of the points raised in the linked PR:\r\n\r\n* `multiprocessing.Queue` is documented as a class: https://docs.python.org/3/library/multiprocessing.html#multiprocessing.Queue\r\n\r\n* `multiprocessing.queues.Queue` can be used in annotations, but it seems to be undocumented. For a user to annotate code using queues, they need to either read the stubs or the stdlib implementation, which is unfortunate.\r\n\r\n* The return type of `multiprocessing.Queue` is `Queue[Any]`, so the change loses some typing precision, even if a user can figure out the correct type. Since `multiprocessing.queues.Queue` is not very discoverable (as it's undocumented), for many new users this may effectively remove the ability to type check queue items.\r\n\r\n* The change breaks existing code that uses `multiprocessing.Queue` as a type, without an obvious fix.\r\n\r\nThe above considerations probably explain why `multiprocessing.Queue` used to be defined as a class, even thought it's not quite true.\r\n\r\nI'm not sure what's the best way forward. Here are some ideas:\r\n\r\n* Revert the change to `Queue` and other similar types (at least for now).\r\n* Teach type checkers to suggest using `multiprocessing.queues.Queue` (etc.) in type annotations. However, if these are undocumented, maybe we shouldn't recommend these?\r\n* Change the return type of `multiprocessing.Queue` to `Queue[T]` to preserve type checking precision (this may not work on all type checkers).","author":{"url":"https://github.com/JukkaL","@type":"Person","name":"JukkaL"},"datePublished":"2020-07-06T17:25:32.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":5},"url":"https://github.com/4313/typeshed/issues/4313"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:ffe67b93-de94-b7f9-1446-1034f1497ec3
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-id91C6:186E38:F263D:1474B2:6969557F
html-safe-nonce8bcdbfb572ed423f056cb5f7c19d48879474657a05cf0266f5efeae80b48f52c
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5MUM2OjE4NkUzODpGMjYzRDoxNDc0QjI6Njk2OTU1N0YiLCJ2aXNpdG9yX2lkIjoiODc3MzU5MjMwMDE5ODEyMjg3OSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmace048c00313c59f754046e7af3d36b86921d0257523a066d3a9ce95bd296638f0
hovercard-subject-tagissue:651704626
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/typeshed/4313/issue_layout
twitter:imagehttps://opengraph.githubassets.com/0b3de8a610430f0cf061a768563640ac504870c843ad71b32dff913e3401f397/python/typeshed/issues/4313
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/0b3de8a610430f0cf061a768563640ac504870c843ad71b32dff913e3401f397/python/typeshed/issues/4313
og:image:alt#4289 changed multiprocessing.Queue from a class to a function. This matches the implementation, but this has some possibly unanticipated side effects, as discussed in python/mypy#9100. Here's a su...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameJukkaL
hostnamegithub.com
expected-hostnamegithub.com
None9db5f28da7e24035385d7f349f17890cbe016a939ddd7952be0f07b862094f5a
turbo-cache-controlno-preview
go-importgithub.com/python/typeshed git https://github.com/python/typeshed.git
octolytics-dimension-user_id1525981
octolytics-dimension-user_loginpython
octolytics-dimension-repository_id31696383
octolytics-dimension-repository_nwopython/typeshed
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id31696383
octolytics-dimension-repository_network_root_nwopython/typeshed
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release4e59fe66217d3c72925af2a341ae3a8f2b5b5b2a
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python/typeshed/issues/4313#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Ftypeshed%2Fissues%2F4313
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub SparkBuild and deploy intelligent appshttps://github.com/features/spark
GitHub ModelsManage and compare promptshttps://github.com/features/models
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Ftypeshed%2Fissues%2F4313
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=python%2Ftypeshed
Reloadhttps://github.com/python/typeshed/issues/4313
Reloadhttps://github.com/python/typeshed/issues/4313
Reloadhttps://github.com/python/typeshed/issues/4313
python https://github.com/python
typeshedhttps://github.com/python/typeshed
Please reload this pagehttps://github.com/python/typeshed/issues/4313
Notifications https://github.com/login?return_to=%2Fpython%2Ftypeshed
Fork 2k https://github.com/login?return_to=%2Fpython%2Ftypeshed
Star 5k https://github.com/login?return_to=%2Fpython%2Ftypeshed
Code https://github.com/python/typeshed
Issues 218 https://github.com/python/typeshed/issues
Pull requests 127 https://github.com/python/typeshed/pulls
Actions https://github.com/python/typeshed/actions
Projects 0 https://github.com/python/typeshed/projects
Security Uh oh! There was an error while loading. Please reload this page. https://github.com/python/typeshed/security
Please reload this pagehttps://github.com/python/typeshed/issues/4313
Insights https://github.com/python/typeshed/pulse
Code https://github.com/python/typeshed
Issues https://github.com/python/typeshed/issues
Pull requests https://github.com/python/typeshed/pulls
Actions https://github.com/python/typeshed/actions
Projects https://github.com/python/typeshed/projects
Security https://github.com/python/typeshed/security
Insights https://github.com/python/typeshed/pulse
New issuehttps://github.com/login?return_to=https://github.com/python/typeshed/issues/4313
New issuehttps://github.com/login?return_to=https://github.com/python/typeshed/issues/4313
#4314https://github.com/python/typeshed/pull/4314
Recent multiprocessing.Queue change breaks existing annotations and reduces typing precisionhttps://github.com/python/typeshed/issues/4313#top
#4314https://github.com/python/typeshed/pull/4314
https://github.com/JukkaL
https://github.com/JukkaL
JukkaLhttps://github.com/JukkaL
on Jul 6, 2020https://github.com/python/typeshed/issues/4313#issue-651704626
#4289https://github.com/python/typeshed/pull/4289
python/mypy#9100https://github.com/python/mypy/pull/9100
https://docs.python.org/3/library/multiprocessing.html#multiprocessing.Queuehttps://docs.python.org/3/library/multiprocessing.html#multiprocessing.Queue
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.