Skip to content

gh-89363: Skip threading test_is_alive_after_fork() if ASAN #109835

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

Merged
merged 1 commit into from
Sep 25, 2023

Conversation

vstinner
Copy link
Member

@vstinner vstinner commented Sep 25, 2023

Skip test_is_alive_after_fork() of test_threading if Python is built with Address Sanitizer (ASAN).

Skip test_is_alive_after_fork() of test_threading if Python is built
with Address Sanitizer (ASAN).
@vstinner
Copy link
Member Author

Bug seen on GHA Address Sanitizer: https://github.com/python/cpython/actions/runs/6299520741/job/17100440637?pr=109831

FAIL: test_is_alive_after_fork (test.test_threading.ThreadTests.test_is_alive_after_fork)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/cpython/cpython/Lib/test/test_threading.py", line 595, in test_is_alive_after_fork
    support.wait_process(pid, exitcode=10)
  File "/home/runner/work/cpython/cpython/Lib/test/support/__init__.py", line 2199, in wait_process
    raise AssertionError(f"process {pid} is still running "
AssertionError: process 11875 is still running after 300.3 seconds

@vstinner
Copy link
Member Author

Windows x64 failed: I created issue gh-109851.

ERROR: test_pipe_handle (test.test_asyncio.test_windows_utils.PipeTests.test_pipe_handle)

@vstinner
Copy link
Member Author

Bug seen on GHA Address Sanitizer: https://github.com/python/cpython/actions/runs/6299520741/job/17100440637?pr=109831
FAIL: test_is_alive_after_fork (test.test_threading.ThreadTests.test_is_alive_after_fork)

I wrote PR #109835 for this issue.

@vstinner vstinner merged commit bc06743 into python:main Sep 25, 2023
@vstinner vstinner deleted the asan_test_is_alive_after_fork branch September 25, 2023 16:02
@miss-islington
Copy link
Contributor

Thanks @vstinner for the PR 🌮🎉.. I'm working now to backport this PR to: 3.11, 3.12.
🐍🍒⛏🤖

@bedevere-app
Copy link

bedevere-app bot commented Sep 25, 2023

GH-109855 is a backport of this pull request to the 3.12 branch.

@bedevere-app bedevere-app bot removed the needs backport to 3.12 only security fixes label Sep 25, 2023
@bedevere-app
Copy link

bedevere-app bot commented Sep 25, 2023

GH-109856 is a backport of this pull request to the 3.11 branch.

@bedevere-app bedevere-app bot removed the needs backport to 3.11 only security fixes label Sep 25, 2023
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 25, 2023
…thonGH-109835)

Skip test_is_alive_after_fork() of test_threading if Python is built
with Address Sanitizer (ASAN).
(cherry picked from commit bc06743)

Co-authored-by: Victor Stinner <[email protected]>
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 25, 2023
…thonGH-109835)

Skip test_is_alive_after_fork() of test_threading if Python is built
with Address Sanitizer (ASAN).
(cherry picked from commit bc06743)

Co-authored-by: Victor Stinner <[email protected]>
@bedevere-bot
Copy link

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

Hi! The buildbot s390x SLES 3.x has failed when building commit bc06743.

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/540/builds/6627) and take a look at the build logs.
  4. Check if the failure is related to this commit (bc06743) 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/540/builds/6627

Failed tests:

  • test_tools

Failed subtests:

  • test_freeze_simple_script - test.test_tools.test_freeze.TestFreeze.test_freeze_simple_script

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

==

Click to see traceback logs
Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-sles-z/build/Lib/test/test_tools/test_freeze.py", line 32, in test_freeze_simple_script
    outdir, scriptfile, python = helper.prepare(script, outdir)
                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/dje/cpython-buildarea/3.x.edelsohn-sles-z/build/Tools/freeze/test/freeze.py", line 146, in prepare
    copy_source_tree(srcdir, SRCDIR)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-sles-z/build/Tools/freeze/test/freeze.py", line 95, in copy_source_tree
    shutil.copytree(oldroot, newroot, ignore=ignore_non_src)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-sles-z/build/Lib/shutil.py", line 588, in copytree
    return _copytree(entries=entries, src=src, dst=dst, symlinks=symlinks,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/dje/cpython-buildarea/3.x.edelsohn-sles-z/build/Lib/shutil.py", line 542, in _copytree
    raise Error(errors)
shutil.Error: [('/home/dje/cpython-buildarea/3.x.edelsohn-sles-z/build/build/test_python_33783æ/@test_33783_tmpæ2', '/tmp/test_python_a47pyah_/tmpghkm1g6y/cpython/build/test_python_33783æ/@test_33783_tmpæ2', "[Errno 2] No such file or directory: '/home/dje/cpython-buildarea/3.x.edelsohn-sles-z/build/build/test_python_33783æ/@test_33783_tmpæ2'"), (<DirEntry 'test_python_33783æ'>, '/tmp/test_python_a47pyah_/tmpghkm1g6y/cpython/build/test_python_33783æ', "[Errno 2] No such file or directory: '/home/dje/cpython-buildarea/3.x.edelsohn-sles-z/build/build/test_python_33783æ'")]

vstinner added a commit that referenced this pull request Sep 25, 2023
…H-109835) (#109856)

gh-89363: Skip threading test_is_alive_after_fork() if ASAN (GH-109835)

Skip test_is_alive_after_fork() of test_threading if Python is built
with Address Sanitizer (ASAN).
(cherry picked from commit bc06743)

Co-authored-by: Victor Stinner <[email protected]>
csm10495 pushed a commit to csm10495/cpython that referenced this pull request Sep 28, 2023
…thon#109835)

Skip test_is_alive_after_fork() of test_threading if Python is built
with Address Sanitizer (ASAN).
Yhg1s pushed a commit that referenced this pull request Oct 2, 2023
…H-109835) (#109855)

gh-89363: Skip threading test_is_alive_after_fork() if ASAN (GH-109835)

Skip test_is_alive_after_fork() of test_threading if Python is built
with Address Sanitizer (ASAN).
(cherry picked from commit bc06743)

Co-authored-by: Victor Stinner <[email protected]>
Glyphack pushed a commit to Glyphack/cpython that referenced this pull request Sep 2, 2024
…thon#109835)

Skip test_is_alive_after_fork() of test_threading if Python is built
with Address Sanitizer (ASAN).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants