René's URL Explorer Experiment


Title: gh-94924: support `inspect.iscoroutinefunction` in `create_autospec(async_def)` by graingert · Pull Request #94962 · python/cpython · GitHub

Open Graph Title: gh-94924: support `inspect.iscoroutinefunction` in `create_autospec(async_def)` by graingert · Pull Request #94962 · python/cpython

X Title: gh-94924: support `inspect.iscoroutinefunction` in `create_autospec(async_def)` by graingert · Pull Request #94962 · python/cpython

Description: Issue: unitest.mock.create_autospec(async_def) does not create functions valid for inspect.iscoroutinefunction #94924

Open Graph Description: Issue: unitest.mock.create_autospec(async_def) does not create functions valid for inspect.iscoroutinefunction #94924

X Description: Issue: unitest.mock.create_autospec(async_def) does not create functions valid for inspect.iscoroutinefunction #94924

Opengraph URL: https://github.com/python/cpython/pull/94962

X: @github

direct link

Domain: github.com

route-pattern/_view_fragments/voltron/pull_requests/show/:user_id/:repository/:id/pull_request_layout(.:format)
route-controllervoltron_pull_requests_fragments
route-actionpull_request_layout
fetch-noncev2:acc01a2d-7c8f-0608-4981-f21b71a6b242
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idC24C:F74F6:2497EFE:30272BA:696B18FB
html-safe-nonce0459b9a7361ee872d3aae25991ffd10fe6eb0b62ec616d68643f705bacdcfd09
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDMjRDOkY3NEY2OjI0OTdFRkU6MzAyNzJCQTo2OTZCMThGQiIsInZpc2l0b3JfaWQiOiIyMTg0ODA5NDY1NTE5MjA4OTIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac55dae58416ce05884297feb96ffaab7f7633a0fe5f65c5e2f5d4f7a60ba182d0
hovercard-subject-tagpull_request:999459812
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/pull_requests_fragments/pull_request_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/voltron/pull_requests/show/python/cpython/94962/pull_request_layout
twitter:imagehttps://opengraph.githubassets.com/0e6641b7c666943f0f40e21b741d9be7ae73bcb6f7b27b175e644057e57c4727/python/cpython/pull/94962
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/0e6641b7c666943f0f40e21b741d9be7ae73bcb6f7b27b175e644057e57c4727/python/cpython/pull/94962
og:image:altIssue: unitest.mock.create_autospec(async_def) does not create functions valid for inspect.iscoroutinefunction #94924
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamegraingert
hostnamegithub.com
expected-hostnamegithub.com
None5f99f7c1d70f01da5b93e5ca90303359738944d8ab470e396496262c66e60b8d
turbo-cache-controlno-preview
go-importgithub.com/python/cpython git https://github.com/python/cpython.git
octolytics-dimension-user_id1525981
octolytics-dimension-user_loginpython
octolytics-dimension-repository_id81598961
octolytics-dimension-repository_nwopython/cpython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id81598961
octolytics-dimension-repository_network_root_nwopython/cpython
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
release82560a55c6b2054555076f46e683151ee28a19bc
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python/cpython/pull/94962#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F94962
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%2Fcpython%2Fpull%2F94962
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%2Fpull_requests_fragments%2Fpull_request_layout&source=header-repo&source_repo=python%2Fcpython
Reloadhttps://github.com/python/cpython/pull/94962
Reloadhttps://github.com/python/cpython/pull/94962
Reloadhttps://github.com/python/cpython/pull/94962
python https://github.com/python
cpythonhttps://github.com/python/cpython
Please reload this pagehttps://github.com/python/cpython/pull/94962
Notifications https://github.com/login?return_to=%2Fpython%2Fcpython
Fork 33.9k https://github.com/login?return_to=%2Fpython%2Fcpython
Star 71.1k https://github.com/login?return_to=%2Fpython%2Fcpython
Code https://github.com/python/cpython
Issues 5k+ https://github.com/python/cpython/issues
Pull requests 2.1k https://github.com/python/cpython/pulls
Actions https://github.com/python/cpython/actions
Projects 31 https://github.com/python/cpython/projects
Security Uh oh! There was an error while loading. Please reload this page. https://github.com/python/cpython/security
Please reload this pagehttps://github.com/python/cpython/pull/94962
Insights https://github.com/python/cpython/pulse
Code https://github.com/python/cpython
Issues https://github.com/python/cpython/issues
Pull requests https://github.com/python/cpython/pulls
Actions https://github.com/python/cpython/actions
Projects https://github.com/python/cpython/projects
Security https://github.com/python/cpython/security
Insights https://github.com/python/cpython/pulse
Sign up for GitHub https://github.com/signup?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose
Jump to bottomhttps://github.com/python/cpython/pull/94962#issue-comment-box
cjw296https://github.com/cjw296
python:mainhttps://github.com/python/cpython/tree/main
graingert:mock-create-autospec-async-defhttps://github.com/graingert/cpython/tree/mock-create-autospec-async-def
gh-94924: support inspect.iscoroutinefunction in create_autospec(async_def) https://github.com/python/cpython/pull/94962#top
cjw296https://github.com/cjw296
python:mainhttps://github.com/python/cpython/tree/main
graingert:mock-create-autospec-async-defhttps://github.com/graingert/cpython/tree/mock-create-autospec-async-def
Conversation 8 https://github.com/python/cpython/pull/94962
Commits 6 https://github.com/python/cpython/pull/94962/commits
Checks 0 https://github.com/python/cpython/pull/94962/checks
Files changed https://github.com/python/cpython/pull/94962/files
Please reload this pagehttps://github.com/python/cpython/pull/94962
https://github.co/hiddenchars
https://github.com/python/cpython/pull/{{ revealButtonHref }}
https://github.com/graingert
graingerthttps://github.com/graingert
Jul 18, 2022https://github.com/python/cpython/pull/94962#issue-1308030442
Please reload this pagehttps://github.com/python/cpython/pull/94962
unitest.mock.create_autospec(async_def) does not create functions valid for inspect.iscoroutinefunction #94924https://github.com/python/cpython/issues/94924
Please reload this pagehttps://github.com/python/cpython/pull/94962
https://github.com/graingert
graingerthttps://github.com/graingert
cjw296https://github.com/cjw296
code ownerhttps://github.com/python/cpython/blob/631160c262b40bf4ce3da6cd7bbb972ae2e9fc91/.github/CODEOWNERS#L100
July 18, 2022 14:16https://github.com/python/cpython/pull/94962#event-7012484977
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
awaiting review https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20review%22
Jul 18, 2022https://github.com/python/cpython/pull/94962#event-7012486025
https://github.com/graingert
graingerthttps://github.com/graingert
Jul 18, 2022https://github.com/python/cpython/pull/94962#issuecomment-1187548145
#84753https://github.com/python/cpython/issues/84753
Please reload this pagehttps://github.com/python/cpython/pull/94962
https://github.com/graingert
graingerthttps://github.com/graingert
force-pushedhttps://github.com/python/cpython/compare/cd43e01453d44038885cb095f2e38bb0084b2729..e0424d25d5b5008bc53e55313ab64c697cfa551d
cd43e01https://github.com/python/cpython/commit/cd43e01453d44038885cb095f2e38bb0084b2729
e0424d2https://github.com/python/cpython/commit/e0424d25d5b5008bc53e55313ab64c697cfa551d
Compare https://github.com/python/cpython/compare/cd43e01453d44038885cb095f2e38bb0084b2729..e0424d25d5b5008bc53e55313ab64c697cfa551d
July 18, 2022 14:28https://github.com/python/cpython/pull/94962#event-7012592653
https://github.com/graingert
graingerthttps://github.com/graingert
Jul 18, 2022 https://github.com/python/cpython/pull/94962#pullrequestreview-1041954161
View reviewed changes https://github.com/python/cpython/pull/94962/files
Lib/unittest/mock.pyhttps://github.com/python/cpython/pull/94962/files#diff-347d0254250a1ab7ab8e31b405e2c35b74cd2838df4ee74f1b658a459eb91f1a
Please reload this pagehttps://github.com/python/cpython/pull/94962
graingerthttps://github.com/graingert
July 18, 2022 15:31https://github.com/python/cpython/pull/94962#commits-pushed-1a39312
https://github.com/graingert
support inspect.iscoroutinefunction in create_autospec(async_def)https://github.com/python/cpython/pull/94962/commits/1a393123fe761a5d799a541736ced30ff4489ee5
1a39312https://github.com/python/cpython/pull/94962/commits/1a393123fe761a5d799a541736ced30ff4489ee5
https://github.com/graingert
test create_autospec with inspect.iscoroutine and inspect.iscoroutine…https://github.com/python/cpython/pull/94962/commits/0596416d31a41195042ddf1c519c144a8a5c8aa9
0596416https://github.com/python/cpython/pull/94962/commits/0596416d31a41195042ddf1c519c144a8a5c8aa9
https://github.com/graingert
test when create_autospec functions check their signaturehttps://github.com/python/cpython/pull/94962/commits/4ab38df251070aca1afb3820e65953a355f90fe8
4ab38dfhttps://github.com/python/cpython/pull/94962/commits/4ab38df251070aca1afb3820e65953a355f90fe8
https://github.com/apps/blurb-it
https://github.com/graingert
📜🤖 Added by blurb_it.https://github.com/python/cpython/pull/94962/commits/034f947cb3e7bda8fa7317e94eb3c7b87f2027aa
034f947https://github.com/python/cpython/pull/94962/commits/034f947cb3e7bda8fa7317e94eb3c7b87f2027aa
https://github.com/graingert
graingerthttps://github.com/graingert
force-pushedhttps://github.com/python/cpython/compare/ccd885e22771fe9a6407d746c204038d0149fb4d..034f947cb3e7bda8fa7317e94eb3c7b87f2027aa
ccd885ehttps://github.com/python/cpython/commit/ccd885e22771fe9a6407d746c204038d0149fb4d
034f947https://github.com/python/cpython/commit/034f947cb3e7bda8fa7317e94eb3c7b87f2027aa
Compare https://github.com/python/cpython/compare/ccd885e22771fe9a6407d746c204038d0149fb4d..034f947cb3e7bda8fa7317e94eb3c7b87f2027aa
July 18, 2022 14:31https://github.com/python/cpython/pull/94962#event-7012629244
https://github.com/graingert
graingerthttps://github.com/graingert
Sep 12, 2022 https://github.com/python/cpython/pull/94962#ref-pullrequest-1352974051
gh-96127: Fix inspect.signature call on mocks #96335 https://github.com/python/cpython/pull/96335
https://github.com/graingert
Merge branch 'main' into mock-create-autospec-async-defhttps://github.com/python/cpython/pull/94962/commits/79f6eb724e2456e42eee0b35a663fe3d7b51e3b9
79f6eb7https://github.com/python/cpython/pull/94962/commits/79f6eb724e2456e42eee0b35a663fe3d7b51e3b9
https://github.com/cjw296
cjw296https://github.com/cjw296
Jun 9, 2023 https://github.com/python/cpython/pull/94962#pullrequestreview-1471983329
View reviewed changes https://github.com/python/cpython/pull/94962/files/c52195852bb5dffc684f1fca74b5afa12de160a4
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
awaiting merge https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20merge%22
awaiting review https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20review%22
Jun 9, 2023https://github.com/python/cpython/pull/94962#event-9484188906
https://github.com/cjw296
Merge branch 'main' into mock-create-autospec-async-defhttps://github.com/python/cpython/pull/94962/commits/c52195852bb5dffc684f1fca74b5afa12de160a4
c521958https://github.com/python/cpython/pull/94962/commits/c52195852bb5dffc684f1fca74b5afa12de160a4
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
Jun 9, 2023 https://github.com/python/cpython/pull/94962#ref-issue-1307074508
unitest.mock.create_autospec(async_def) does not create functions valid for inspect.iscoroutinefunction #94924 https://github.com/python/cpython/issues/94924
https://github.com/cjw296
cjw296https://github.com/cjw296
June 9, 2023 13:00https://github.com/python/cpython/pull/94962#event-9484195406
https://github.com/cjw296
cjw296https://github.com/cjw296
9bf8d82https://github.com/python/cpython/commit/9bf8d825a66ea2a76169b917c12c237a6af2ed75
Jun 9, 2023https://github.com/python/cpython/pull/94962#event-9484538835
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
awaiting merge https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20merge%22
Jun 9, 2023https://github.com/python/cpython/pull/94962#event-9484539507
https://github.com/cjw296
cjw296https://github.com/cjw296
Jul 10, 2023 https://github.com/python/cpython/pull/94962#pullrequestreview-1521577932
View reviewed changes https://github.com/python/cpython/pull/94962/files/c52195852bb5dffc684f1fca74b5afa12de160a4
Lib/unittest/mock.pyhttps://github.com/python/cpython/pull/94962/files/c52195852bb5dffc684f1fca74b5afa12de160a4#diff-347d0254250a1ab7ab8e31b405e2c35b74cd2838df4ee74f1b658a459eb91f1a
Please reload this pagehttps://github.com/python/cpython/pull/94962
https://github.com/cjw296
cjw296https://github.com/cjw296
Jul 10, 2023 https://github.com/python/cpython/pull/94962#pullrequestreview-1521580874
View reviewed changes https://github.com/python/cpython/pull/94962/files/c52195852bb5dffc684f1fca74b5afa12de160a4
Lib/unittest/mock.pyhttps://github.com/python/cpython/pull/94962/files/c52195852bb5dffc684f1fca74b5afa12de160a4#diff-347d0254250a1ab7ab8e31b405e2c35b74cd2838df4ee74f1b658a459eb91f1a
Please reload this pagehttps://github.com/python/cpython/pull/94962
https://github.com/cjw296
cjw296https://github.com/cjw296
Jul 10, 2023 https://github.com/python/cpython/pull/94962#ref-pullrequest-493300726
gh-61215: New mock to wait for multi-threaded events to happen #16094 https://github.com/python/cpython/pull/16094
https://github.com/hugovk
hugovkhttps://github.com/hugovk
Mar 15, 2024https://github.com/python/cpython/pull/94962#issuecomment-2000099627
@cjw296https://github.com/cjw296
Please reload this pagehttps://github.com/python/cpython/pull/94962
https://github.com/graingert
graingerthttps://github.com/graingert
March 15, 2024 17:15https://github.com/python/cpython/pull/94962#event-12134607845
https://github.com/cjw296
cjw296https://github.com/cjw296
Mar 18, 2024https://github.com/python/cpython/pull/94962#issuecomment-2003042644
Please reload this pagehttps://github.com/python/cpython/pull/94962
https://github.com/cjw296
cjw296https://github.com/cjw296
Sep 15, 2025 https://github.com/python/cpython/pull/94962#ref-issue-3306684138
Patched async function not registering calls until coroutine is awaited #137594 https://github.com/python/cpython/issues/137594
Sign up for freehttps://github.com/join?source=comment-repo
Sign in to commenthttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F94962
https://github.com/cjw296
cjw296 https://github.com/cjw296
https://github.com/python/cpython/pull/94962/files/c52195852bb5dffc684f1fca74b5afa12de160a4
Please reload this pagehttps://github.com/python/cpython/pull/94962
https://github.com/graingert
https://github.com/hugovk
https://github.com/cjw296
https://github.com/bedevere-bot
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.