Skip to content

Commit with _PyCode_GetVarCounts() broke buildbots #133224

Closed
@sobolevn

Description

@sobolevn

Example: https://buildbot.python.org/#/builders/1636/builds/305/steps/6/logs/stdio

  test_var_counts (test.test_code.CodeTest.test_var_counts) ... Fatal Python error: Segmentation fault

Current thread 0x000003ffb3d77740 [python] (most recent call first):
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/test_code.py", line 974 in test_var_counts
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/unittest/case.py", line 615 in _callTestMethod
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/unittest/case.py", line 669 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/unittest/case.py", line 725 in __call__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/unittest/suite.py", line 122 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/unittest/suite.py", line 84 in __call__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/unittest/suite.py", line 122 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/unittest/suite.py", line 84 in __call__
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/unittest/runner.py", line 259 in run
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/single.py", line 84 in _run_suite
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/single.py", line 42 in run_unittest
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/single.py", line 162 in test_func
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/single.py", line 118 in regrtest_runner
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/single.py", line 165 in _load_run_test
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/single.py", line 210 in _runtest_env_changed_exc
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/single.py", line 319 in _runtest
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/single.py", line 348 in run_single_test
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/worker.py", line 92 in worker_process
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/worker.py", line 127 in main
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/test/libregrtest/worker.py", line 131 in <module>
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/runpy.py", line 88 in _run_code
  File "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/Lib/runpy.py", line 198 in _run_module_as_main

Current thread's C stack trace (most recent call first):
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python", at _Py_DumpStack+0x2e [0x12be1e6]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x12d237e]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x12d2698]
  Binary file "linux-vdso64.so.1", at __kernel_sigreturn+0x0 [0x3ffdc4fe4d8]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x127e454]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10bb114]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python", at _PyCode_SetUnboundVarCounts+0xbe [0x10be136]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/build/lib.linux-s390x-3.14/_testinternalcapi.cpython-314d-s390x-linux-gnu.so", at +0x9826 [0x3ffa5109826]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x1113148]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python", at _PyObject_MakeTpCall+0xb4 [0x10b4a1c]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b4c44]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python", at PyObject_Vectorcall+0x42 [0x10b4cda]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python", at _PyEval_EvalFrameDefault+0x4862 [0x1202372]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x1222c84]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x1222e96]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b4876]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b7d18]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b7e86]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b60aa]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b639a]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python", at PyObject_Call+0x3e [0x10b63f6]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python", at _PyEval_EvalFrameDefault+0x763a [0x120514a]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x1222c84]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x1222e96]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b4876]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b5dba]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b5fb6]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x1159664]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x1159768]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python", at _PyObject_MakeTpCall+0xb4 [0x10b4a1c]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python" [0x10b4c44]
  Binary file "/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x/build/python", at PyObject_Vectorcall+0x42 [0x10b4cda]
  <truncated rest of calls>

Extension modules: _testinternalcapi, _testcapi (total: 2)

Refs #133128
CC @ericsnowcurrently

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.14bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)type-crashA hard crash of the interpreter, possibly with a core dump

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions