| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:0183438d-f69a-35fb-aa5d-eed0381385e5 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | A4E0:1DC0B7:3AE13E:51B3B2:6A53750E |
| html-safe-nonce | f13572b0cf1fe717c4c58c76dd104c96926f9d8713f7897db55b43c1ff4388cc |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBNEUwOjFEQzBCNzozQUUxM0U6NTFCM0IyOjZBNTM3NTBFIiwidmlzaXRvcl9pZCI6IjM4NzIwOTM0MjkyMjkxMjI4MzAiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 7abe51a54816e245310d49694d47d643340af2e862035bf8f7c019b4c9640081 |
| hovercard-subject-tag | pull_request:3098403318 |
| 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 | ///pull_requests/show/files |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/python/cpython/pull/142656/files |
| twitter:image | https://avatars.githubusercontent.com/u/13768674?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/13768674?s=400&v=4 |
| og:image:alt | gh-142651: Make call_count of Mock thread safe |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 07a982c1d40157c619b364352b704c3ce66bb332 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| Skip to content | https://github.com/python/cpython/pull/142656/files#start-of-content |
|
| https://github.com/ |
|
Sign in
| https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F142656%2Ffiles |
| GitHub CopilotWrite better code with AI | https://github.com/features/copilot |
| GitHub Copilot appDirect agents from issue to merge | https://github.com/features/ai/github-app |
| MCP RegistryNewIntegrate external tools | https://github.com/mcp |
| ActionsAutomate any workflow | https://github.com/features/actions |
| CodespacesInstant dev environments | https://github.com/features/codespaces |
| IssuesPlan and track work | https://github.com/features/issues |
| Code ReviewManage code changes | https://github.com/features/code-review |
| GitHub Advanced SecurityFind and fix vulnerabilities | https://github.com/security/advanced-security |
| Code securitySecure your code as you build | https://github.com/security/advanced-security/code-security |
| Secret protectionStop leaks before they start | https://github.com/security/advanced-security/secret-protection |
| Why GitHub | https://github.com/why-github |
| Documentation | https://docs.github.com |
| Blog | https://github.blog |
| Changelog | https://github.blog/changelog |
| Marketplace | https://github.com/marketplace |
| View all features | https://github.com/features |
| Enterprises | https://github.com/enterprise |
| Small and medium teams | https://github.com/team |
| Startups | https://github.com/enterprise/startups |
| Nonprofits | https://github.com/solutions/industry/nonprofits |
| App Modernization | https://github.com/solutions/use-case/app-modernization |
| DevSecOps | https://github.com/solutions/use-case/devsecops |
| DevOps | https://github.com/solutions/use-case/devops |
| CI/CD | https://github.com/solutions/use-case/ci-cd |
| View all use cases | https://github.com/solutions/use-case |
| Healthcare | https://github.com/solutions/industry/healthcare |
| Financial services | https://github.com/solutions/industry/financial-services |
| Manufacturing | https://github.com/solutions/industry/manufacturing |
| Government | https://github.com/solutions/industry/government |
| View all industries | https://github.com/solutions/industry |
| View all solutions | https://github.com/solutions |
| AI | https://github.com/resources/articles?topic=ai |
| Software Development | https://github.com/resources/articles?topic=software-development |
| DevOps | https://github.com/resources/articles?topic=devops |
| Security | https://github.com/resources/articles?topic=security |
| View all topics | https://github.com/resources/articles |
| Customer stories | https://github.com/customer-stories |
| Events & webinars | https://github.com/resources/events |
| Ebooks & reports | https://github.com/resources/whitepapers |
| Business insights | https://github.com/solutions/executive-insights |
| GitHub Skills | https://skills.github.com |
| Documentation | https://docs.github.com |
| Customer support | https://support.github.com |
| Community forum | https://github.com/orgs/community/discussions |
| Trust center | https://github.com/trust-center |
| Partners | https://github.com/partners |
| View all resources | https://github.com/resources |
| GitHub SponsorsFund open source developers | https://github.com/open-source/sponsors |
| Security Lab | https://securitylab.github.com |
| Maintainer Community | https://maintainers.github.com |
| Accelerator | https://github.com/open-source/accelerator |
| GitHub Stars | https://stars.github.com |
| Archive Program | https://archiveprogram.github.com |
| Topics | https://github.com/topics |
| Trending | https://github.com/trending |
| Collections | https://github.com/collections |
| Enterprise platformAI-powered developer platform | https://github.com/enterprise |
| GitHub Advanced SecurityEnterprise-grade security features | https://github.com/security/advanced-security |
| Copilot for BusinessEnterprise-grade AI features | https://github.com/features/copilot/copilot-business |
| Premium SupportEnterprise-grade 24/7 support | https://github.com/enterprise/premium-support |
| Pricing | https://github.com/pricing |
| Search syntax tips | https://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax |
| documentation | https://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%2F142656%2Ffiles |
|
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%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=python%2Fcpython |
| Reload | https://github.com/python/cpython/pull/142656/files |
| Reload | https://github.com/python/cpython/pull/142656/files |
| Reload | https://github.com/python/cpython/pull/142656/files |
| Please reload this page | https://github.com/python/cpython/pull/142656/files |
|
python
| https://github.com/python |
| cpython | https://github.com/python/cpython |
| Please reload this page | https://github.com/python/cpython/pull/142656/files |
|
Notifications
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Fork
35k
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Star
73.8k
| 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.3k
| https://github.com/python/cpython/pulls |
|
Actions
| https://github.com/python/cpython/actions |
|
Projects
| https://github.com/python/cpython/projects |
|
Security and quality
0
| https://github.com/python/cpython/security |
|
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 and quality
| 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 service | https://docs.github.com/terms |
| privacy statement | https://docs.github.com/privacy |
| Sign in | https://github.com/login?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose |
| kumaraditya303 | https://github.com/kumaraditya303 |
| python:main | https://github.com/python/cpython/tree/main |
|
Conversation
40
| https://github.com/python/cpython/pull/142656 |
|
Commits
18
| https://github.com/python/cpython/pull/142656/commits |
|
Checks
52
| https://github.com/python/cpython/pull/142656/checks |
|
Files changed
| https://github.com/python/cpython/pull/142656/files |
| Please reload this page | https://github.com/python/cpython/pull/142656/files |
|
gh-142651: Make call_count of Mock thread safe
| https://github.com/python/cpython/pull/142656/files#top |
|
Show all changes
18 commits
| https://github.com/python/cpython/pull/142656/files |
|
a401818
Make call_count of Mock thread safe
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/a401818402740042d643e1c26c5c407fe663b60d |
|
d532d23
📜🤖 Added by blurb_it.
blurb-it[bot] Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/d532d23633eeea55eb5ead7db88c51a1d1ab9fc3 |
|
fe7be86
update doc
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/fe7be86596dcb3cbb3483ceb3175d3e791f3cff7 |
|
29578a9
calculate call_count after append call_args_list
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/29578a94af07fc61fa68ae9e6ba9fa0f37aa531c |
|
c2e4ca7
revert change on documentation for call_count.
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/c2e4ca7d882efc7a49314fafd68d5029cbc6e487 |
|
e9e6dfa
revert unnecessary change.
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/e9e6dfa99d568641ea3d0ce52163421edfdb572e |
|
3a4b590
revert blank line deletion
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/3a4b590768d37b3fe6a75b4e581c37e6512f7208 |
|
70e9107
added TestThreadingMockRaceCondition
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/70e91077ac791fe1ef7785e38e0fb9c6699dcc28 |
|
dc0d804
Update Misc/NEWS.d/next/Library/2025-12-13-06-17-44.gh-issue-142651.Z…
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/dc0d804c67e3e9095140be66ecdecedeaa1025b4 |
|
f05407e
Update Lib/test/test_unittest/testmock/testthreadingmock.py
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/f05407ebd7594962f34f13c433481de882d39ce3 |
|
3a81b0d
update test
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/3a81b0d9618d9cf894b15f32bfe6685623b7d842 |
|
23825f4
Merge branch 'fix-issue-142651' of https://github.com/chaope/cpython …
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/23825f42e8a8750f0939f65d754c054883f7eb3b |
|
a76318e
move self._executor.shutdown to addCleanup
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/a76318e79772302eb779eb65e815b69d41e8c2ce |
|
8e2348c
use 3k loops
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/8e2348c4a2d8b8c98769476a63fa83a599170c6a |
|
e7dcc57
add @requires_resource('cpu')
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/e7dcc5752b36b78eac687acdb0f07d2e15fe599f |
|
851f698
update test according to comments
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/851f698a6b6bd80ecaf1947e6293047807e13c1d |
|
3b29867
update according to comments
chaope Dec 13, 2025
| https://github.com/python/cpython/pull/142656/commits/3b298676c60f57be008fcab45a3ae9e3ede3a189 |
|
16232b8
use threading_helper.start_threads
chaope Dec 14, 2025
| https://github.com/python/cpython/pull/142656/commits/16232b89c15a4a1869e174958851bb209aaa55b4 |
|
Clear filters
| https://github.com/python/cpython/pull/142656/files |
| Please reload this page | https://github.com/python/cpython/pull/142656/files |
| Please reload this page | https://github.com/python/cpython/pull/142656/files |
|
testthreadingmock.py
| https://github.com/python/cpython/pull/142656/files#diff-e18ec3ab7692a91926fc78276eb4566663dec50650fbefe1c959132af6b13222 |
|
mock.py
| https://github.com/python/cpython/pull/142656/files#diff-347d0254250a1ab7ab8e31b405e2c35b74cd2838df4ee74f1b658a459eb91f1a |
|
2025-12-13-06-17-44.gh-issue-142651.ZRtBu4.rst
| https://github.com/python/cpython/pull/142656/files#diff-6bbc2ae3aeec2189862819549bf1accdc9aee33f6743722015039f5c41050ad5 |
|
| https://github.com/python/cpython/blob/main/.github/CODEOWNERS#L623 |
| Lib/test/test_unittest/testmock/testthreadingmock.py | https://github.com/python/cpython/pull/142656/files#diff-e18ec3ab7692a91926fc78276eb4566663dec50650fbefe1c959132af6b13222 |
|
View file
| https://github.com/python/cpython/blob/16232b89c15a4a1869e174958851bb209aaa55b4/Lib/test/test_unittest/testmock/testthreadingmock.py |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/142656/{{ revealButtonHref }} |
| Please reload this page | https://github.com/python/cpython/pull/142656/files |
|
| https://github.com/python/cpython/pull/142656/files#diff-e18ec3ab7692a91926fc78276eb4566663dec50650fbefe1c959132af6b13222 |
|
| https://github.com/python/cpython/pull/142656/files#diff-e18ec3ab7692a91926fc78276eb4566663dec50650fbefe1c959132af6b13222 |
| Please reload this page | https://github.com/python/cpython/pull/142656/files |
|
| https://github.com/python/cpython/blob/main/.github/CODEOWNERS#L622 |
| Lib/unittest/mock.py | https://github.com/python/cpython/pull/142656/files#diff-347d0254250a1ab7ab8e31b405e2c35b74cd2838df4ee74f1b658a459eb91f1a |
|
View file
| https://github.com/python/cpython/blob/16232b89c15a4a1869e174958851bb209aaa55b4/Lib/unittest/mock.py |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/142656/{{ revealButtonHref }} |
|
| https://github.com/python/cpython/pull/142656/files#diff-347d0254250a1ab7ab8e31b405e2c35b74cd2838df4ee74f1b658a459eb91f1a |
|
| https://github.com/python/cpython/pull/142656/files#diff-347d0254250a1ab7ab8e31b405e2c35b74cd2838df4ee74f1b658a459eb91f1a |
| Misc/NEWS.d/next/Library/2025-12-13-06-17-44.gh-issue-142651.ZRtBu4.rst | https://github.com/python/cpython/pull/142656/files#diff-6bbc2ae3aeec2189862819549bf1accdc9aee33f6743722015039f5c41050ad5 |
|
View file
| https://github.com/python/cpython/blob/16232b89c15a4a1869e174958851bb209aaa55b4/Misc/NEWS.d/next/Library/2025-12-13-06-17-44.gh-issue-142651.ZRtBu4.rst |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/142656/{{ revealButtonHref }} |
| Please reload this page | https://github.com/python/cpython/pull/142656/files |
|
| https://github.com |
| Terms | https://docs.github.com/site-policy/github-terms/github-terms-of-service |
| Privacy | https://docs.github.com/site-policy/privacy-policies/github-privacy-statement |
| Security | https://github.com/security |
| Status | https://www.githubstatus.com/ |
| Community | https://github.community/ |
| Docs | https://docs.github.com/ |
| Contact | https://support.github.com?tags=dotcom-footer |