Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gh-103092: Isolate _pickle #102982

Merged
merged 23 commits into from
Apr 4, 2023
Merged

Conversation

erlend-aasland
Copy link
Contributor

@erlend-aasland erlend-aasland commented Mar 23, 2023

@erlend-aasland erlend-aasland changed the title isolate pickle WIP: Isolate _pickle Mar 23, 2023
@erlend-aasland
Copy link
Contributor Author

Based on previous work by Mohamed Koubaa:

@erlend-aasland erlend-aasland added the 🔨 test-with-refleak-buildbots Test PR w/ refleak buildbots; report in status section label Mar 24, 2023
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @erlend-aasland for commit 0551d52 🤖

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

@bedevere-bot bedevere-bot removed the 🔨 test-with-refleak-buildbots Test PR w/ refleak buildbots; report in status section label Mar 24, 2023
@erlend-aasland erlend-aasland changed the title WIP: Isolate _pickle [PoC] Isolate _pickle Mar 24, 2023
@erlend-aasland erlend-aasland changed the title [PoC] Isolate _pickle gh-103092: Isolate _pickle Mar 28, 2023
@erlend-aasland
Copy link
Contributor Author

FYI, I made a PoC alternative variant where I store the state in the pickler and unpickler objects. It makes for a much nicer diff, but I had to do too much fishy stuff to make it work. You can take a look here: https://github.com/erlend-aasland/cpython/pull/new/isolate-pickle-alt

Modules/_pickle.c Outdated Show resolved Hide resolved
@erlend-aasland erlend-aasland marked this pull request as ready for review April 3, 2023 13:24
Modules/_pickle.c Outdated Show resolved Hide resolved
@bedevere-bot
Copy link

When you're done making the requested changes, leave the comment: I have made the requested changes; please review again.

Modules/_pickle.c Outdated Show resolved Hide resolved
Modules/_pickle.c Outdated Show resolved Hide resolved
@kumaraditya303 kumaraditya303 merged commit c00dcf0 into python:main Apr 4, 2023
@kumaraditya303 kumaraditya303 deleted the isolate-pickle branch April 4, 2023 10:09
@kumaraditya303
Copy link
Contributor

Merged, will start reviewing others in queue.

@erlend-aasland
Copy link
Contributor Author

Thanks for the review, Kumar, and thanks for the initial work, Mohamed!

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure ⚠️⚠️⚠️

Hi! The buildbot aarch64 Fedora Stable 3.x has failed when building commit c00dcf0.

What do you need to do:

  1. Don't panic.
  2. Check the buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/125/builds/3374) and take a look at the build logs.
  4. Check if the failure is related to this commit (c00dcf0) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/125/builds/3374

Failed tests:

  • test_asyncio

Summary of the results of the build (if available):

==

Click to see traceback logs
remote: Enumerating objects: 18, done.        
remote: Counting objects:   5% (1/17)        
remote: Counting objects:  11% (2/17)        
remote: Counting objects:  17% (3/17)        
remote: Counting objects:  23% (4/17)        
remote: Counting objects:  29% (5/17)        
remote: Counting objects:  35% (6/17)        
remote: Counting objects:  41% (7/17)        
remote: Counting objects:  47% (8/17)        
remote: Counting objects:  52% (9/17)        
remote: Counting objects:  58% (10/17)        
remote: Counting objects:  64% (11/17)        
remote: Counting objects:  70% (12/17)        
remote: Counting objects:  76% (13/17)        
remote: Counting objects:  82% (14/17)        
remote: Counting objects:  88% (15/17)        
remote: Counting objects:  94% (16/17)        
remote: Counting objects: 100% (17/17)        
remote: Counting objects: 100% (17/17), done.        
remote: Compressing objects:  12% (1/8)        
remote: Compressing objects:  25% (2/8)        
remote: Compressing objects:  37% (3/8)        
remote: Compressing objects:  50% (4/8)        
remote: Compressing objects:  62% (5/8)        
remote: Compressing objects:  75% (6/8)        
remote: Compressing objects:  87% (7/8)        
remote: Compressing objects: 100% (8/8)        
remote: Compressing objects: 100% (8/8), done.        
remote: Total 18 (delta 9), reused 11 (delta 9), pack-reused 1        
From https://github.com/python/cpython
 * branch                  main       -> FETCH_HEAD
Note: switching to 'c00dcf0e381a090f7e905f887a98bbf63c88af5a'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

HEAD is now at c00dcf0e38 gh-103092: Isolate `_pickle` module (#102982)
Switched to and reset branch 'main'

Timeout (0:15:00)!
Thread 0x0000ffffbbdd4020 (most recent call first):
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/test_asyncio/test_tasks.py", line 137 in __del__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/test_asyncio/test_tasks.py", line 142 in test_task_del_collect
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/case.py", line 589 in _callTestMethod
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/case.py", line 634 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/case.py", line 690 in __call__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 122 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 84 in __call__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 122 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 84 in __call__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 122 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 84 in __call__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 122 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 84 in __call__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 122 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/suite.py", line 84 in __call__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/unittest/runner.py", line 240 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/support/__init__.py", line 1106 in _run_suite
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/support/__init__.py", line 1232 in run_unittest
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/libregrtest/runtest.py", line 281 in _test_module
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/libregrtest/runtest.py", line 317 in _runtest_inner2
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/libregrtest/runtest.py", line 360 in _runtest_inner
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/libregrtest/runtest.py", line 235 in _runtest
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/libregrtest/runtest.py", line 265 in runtest
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/libregrtest/main.py", line 353 in rerun_failed_tests
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/libregrtest/main.py", line 756 in _main
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/libregrtest/main.py", line 711 in main
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/libregrtest/main.py", line 775 in main
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/test/__main__.py", line 2 in <module>
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/runpy.py", line 88 in _run_code
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/Lib/runpy.py", line 198 in _run_module_as_main
make: *** [Makefile:1950: buildbottest] Error 1

Cannot open file '/home/buildbot/buildarea/3.x.cstratak-fedora-stable-aarch64/build/build_oot/test-results.xml' for upload

gaogaotiantian pushed a commit to gaogaotiantian/cpython that referenced this pull request Apr 8, 2023
Co-authored-by: Mohamed Koubaa <koubaa.m@gmail.com>
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
warsaw pushed a commit to warsaw/cpython that referenced this pull request Apr 11, 2023
Co-authored-by: Mohamed Koubaa <koubaa.m@gmail.com>
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants