Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-103092: Isolate socket#103094

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
kumaraditya303 merged 24 commits intopython:mainfromerlend-aasland:isolate-socket
Apr 9, 2023

Conversation

erlend-aasland
Copy link
Contributor

@erlend-aaslanderlend-aasland commentedMar 28, 2023
edited
Loading

@erlend-aaslanderlend-aasland added the 🔨 test-with-refleak-buildbotsTest PR w/ refleak buildbots; report in status section labelApr 4, 2023
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by@erlend-aasland for commitb4edf64 🤖

If you want to schedule another build, you need to add the🔨 test-with-refleak-buildbots label again.

@bedevere-botbedevere-bot removed the 🔨 test-with-refleak-buildbotsTest PR w/ refleak buildbots; report in status section labelApr 4, 2023
@erlend-aasland
Copy link
ContributorAuthor

There's some leaks that needs to be adressed:

$./python.exe measure.pybefore=46451, after=47809before=47811, after=48549before=48549, after=49287before=49287, after=50025before=50025, after=50763
measure.py
importgcimportsysfor_inrange(5):gc.collect()before=sys.gettotalrefcount()import_socketdelsys.modules["_socket"]del_socketgc.collect()after=sys.gettotalrefcount()print(f"{before=},{after=}")# assert after == before

... and these two:

$./python.exe -mtest -R: test_socket -m RecvmsgIntoSCMRightsStreamTest                                                                              Raised RLIMIT_NOFILE: 256 -> 10240:00:00 load avg: 1.96 Run tests sequentially0:00:00 load avg: 1.96 [1/1] test_socketbeginning 9 repetitions123456789.........test_socket leaked [10, 10, 10, 10] file descriptors, sum=40test_socket failed (reference leak)== Tests result: FAILURE ==1 test failed:    test_socketTotal duration: 1.8 secTests result: FAILURE$./python.exe -mtest -R: test_socket -m RecvmsgSCMRightsStreamTest                                                                                  Raised RLIMIT_NOFILE: 256 -> 10240:00:00 load avg: 2.52 Run tests sequentially0:00:00 load avg: 2.52 [1/1] test_socketbeginning 9 repetitions123456789.........test_socket leaked [10, 10, 10, 10] file descriptors, sum=40test_socket failed (reference leak)== Tests result: FAILURE ==1 test failed:    test_socketTotal duration: 1.8 secTests result: FAILURE

@erlend-aasland
Copy link
ContributorAuthor

Regarding#103094 (comment): the file descriptors leak onmain as well, so it is not a regression introduced by this PR. Let's not bother with those. There's still references leaked by repeated init of the module, though.

@erlend-aasland
Copy link
ContributorAuthor

Seems like the leaks are due to the capsulated C API not being freed.

@erlend-aasland
Copy link
ContributorAuthor

I'd like to hold this PR until#103261 has landed.

@erlend-aaslanderlend-aasland marked this pull request as ready for reviewApril 8, 2023 19:39
@erlend-aaslanderlend-aasland added the 🔨 test-with-refleak-buildbotsTest PR w/ refleak buildbots; report in status section labelApr 8, 2023
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by@erlend-aasland for commit2019a93 🤖

If you want to schedule another build, you need to add the🔨 test-with-refleak-buildbots label again.

@bedevere-botbedevere-bot removed the 🔨 test-with-refleak-buildbotsTest PR w/ refleak buildbots; report in status section labelApr 8, 2023
Copy link
Contributor

@kumaraditya303kumaraditya303 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

LGTM

erlend-aasland reacted with hooray emoji
@kumaraditya303kumaraditya303 merged commitf329a8b intopython:mainApr 9, 2023
@kumaraditya303kumaraditya303 deleted the isolate-socket branchApril 9, 2023 01:03
warsaw pushed a commit to warsaw/cpython that referenced this pull requestApr 11, 2023
@CharlieZhao95CharlieZhao95 mentioned this pull requestApr 12, 2023
5 tasks
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@kumaraditya303kumaraditya303kumaraditya303 approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@erlend-aasland@bedevere-bot@kumaraditya303

[8]ページ先頭

©2009-2025 Movatter.jp