Skip to content

Revert internals destruction and add test for internals recreation #10521

Revert internals destruction and add test for internals recreation

Revert internals destruction and add test for internals recreation #10521

Triggered via pull request January 22, 2026 18:08
Status Failure
Total duration 27m 9s
Artifacts

ci.yml

on: pull_request
Manylinux on 🐍 3.13t β€’ GIL
0s
Manylinux on 🐍 3.13t β€’ GIL
🐍 3.10 β€’ CUDA 12.2 β€’ Ubuntu 22.04
8m 41s
🐍 3.10 β€’ CUDA 12.2 β€’ Ubuntu 22.04
🐍 3 β€’ NVHPC 25.11 β€’ C++17 β€’ x64
0s
🐍 3 β€’ NVHPC 25.11 β€’ C++17 β€’ x64
🐍 3 β€’ ICC latest β€’ x64
0s
🐍 3 β€’ ICC latest β€’ x64
🐍 3.9 β€’ Debian β€’ x86 β€’ Install
0s
🐍 3.9 β€’ Debian β€’ x86 β€’ Install
Documentation build test
0s
Documentation build test
Matrix: centos
Matrix: clang
Matrix: deadsnakes
Matrix: gcc
Matrix: inplace
Matrix: mingw
Matrix: 🐍
Waiting for pending jobs
Matrix: 🐍
Matrix: win32-debug
Matrix: win32
Matrix: windows-2022
Matrix: windows_arm_clang_msvc
Matrix: windows_arm_clang_msys2
Matrix: windows_clang
Fit to window
Zoom out
Zoom in

Annotations

7 errors
🐍 (macos-latest, 3.14, -DCMAKE_CXX_STANDARD=14) / πŸ§ͺ
Process completed with exit code 139.
🐍 (ubuntu-latest, 3.14t, -DCMAKE_CXX_STANDARD=17 -DPYBIND11_TEST_SMART_HOLDER=ON) / πŸ§ͺ: tests/test_multiple_interpreters.py#L437
test_import_in_subinterpreter_concurrently RuntimeError: Subprocess failed with exit code -11. Code: ```python def test(): import sys sys.path.insert(0, '/home/runner/work/pybind11/pybind11/build/tests') import collections import mod_per_interpreter_gil_with_singleton as m objects = m.get_objects_in_singleton() expected = [ type(None), # static type: shared between interpreters tuple, # static type: shared between interpreters list, # static type: shared between interpreters dict, # static type: shared between interpreters collections.OrderedDict, # static type: shared between interpreters collections.defaultdict, # heap type: dynamically created per interpreter collections.deque, # heap type: dynamically created per interpreter ] # Check that we have the expected objects. Avoid IndexError by checking lengths first. assert len(objects) == len(expected), ( f"Expected {expected!r} ({len(expected)}), got {objects!r} ({len(objects)})." ) # The first ones are static types shared between interpreters. assert objects[:-2] == expected[:-2], ( f"Expected static objects {expected[:-2]!r}, got {objects[:-2]!r}." ) # The last two are heap types created per-interpreter. # The expected objects are dynamically imported from `collections`. assert objects[-2:] == expected[-2:], ( f"Expected heap objects {expected[-2:]!r}, got {objects[-2:]!r}." ) assert hasattr(m, 'MyClass'), "Module missing MyClass" assert hasattr(m, 'MyGlobalError'), "Module missing MyGlobalError" assert hasattr(m, 'MyLocalError'), "Module missing MyLocalError" assert hasattr(m, 'MyEnum'), "Module missing MyEnum" import gc from concurrent.futures import InterpreterPoolExecutor, as_completed futures = future = None with InterpreterPoolExecutor(max_workers=16) as executor: futures = [executor.submit(test) for _ in range(32)] for future in as_completed(futures): future.result() del futures, future, executor for _ in range(5): gc.collect() ``` Output: Fatal Python error: Segmentation fault <Cannot show all threads while the GIL is disabled> Stack (most recent call first): File "<string>", line 49 in <module> Current thread's C stack trace (most recent call first): Binary file "/opt/hostedtoolcache/Python/3.14.2/x64-freethreaded/lib/libpython3.14t.so.1.0", at _Py_DumpStack+0x47 [0x7f41dd95cf54] Binary file "/opt/hostedtoolcache/Python/3.14.2/x64-freethreaded/lib/libpython3.14t.so.1.0", at +0x16631f [0x7f41dd96631f] Binary file "/lib/x86_64-linux-gnu/libc.so.6", at +0x45330 [0x7f41dd445330] Binary file "/opt/hostedtoolcache/Python/3.14.2/x64-freethreaded/lib/libpython3.14t.so.1.0", at _Py_Dealloc+0x1c [0x7f41dd9e894c] Binary file "/opt/hostedtoolcache/Python/3.14.2/x64-freethreaded/lib/libpython3.14t.so.1.0", at PyDict_GetItemWithError+0xdd [0x7f41dd9df87d] Binary file "/home/runner/work/pybind11/pybind11/build/tests/mod_per_interpreter_gil_with_singleton.cpython-314t-x86_64-linux-gnu.so", at +0xccfb [0x7f41d892fcfb] Binary file "/home/runner/work/pybind11/pybind11/build/tests/mod_per_interpreter_gil_with_singleton.cpython-314t-x86_64-linux-gnu.so", at +0xd67e [0x7f41d893067e] Binary file "/home/runner/work/pybind11/pybind11/build/tests/mod_per_interpreter_gil_with_singleton.cpython-314t-x86_64-linux-gnu.so", at +0xedde [0x7f41d8931dde] Binary file "/opt/hostedtoolcache/Python/3.14.2/x64-freethreaded/lib/libpython3.14t.so.1.0", at _Py_Dealloc+0x83 [0x7f41dd9e89b3] Binary file "/opt/hostedtoolcache/Python/3.14.2/x64-freethreaded/lib/libpython3.14t.so.1.0", at +0x1fa81a [0x7f41dd9fa81a] Binary file "/opt/hostedtoolcache/Python/3.14.2/x64-freethreaded/lib/libpython3.14t.so.1.0", at _Py_Dealloc+0x83 [0x7f41dd9e89b3] Binary file "/opt/hostedtoolcache/Python/3.14.2/x64-freethreaded/lib/libpython3.14t.so.1.0", at +0x2eff08 [0x7f41ddaeff08] Binary file "/opt/hostedtoolcache/Python/3
🐍 3.10 β€’ CUDA 12.2 β€’ Ubuntu 22.04
Process completed with exit code 2.
🐍 (windows-2022, 3.8, -DPYBIND11_FINDPYTHON=OFF) / πŸ§ͺ
Process completed with exit code 1.