[pybsddb] berkeleydb segfaulting with Python 3.13
Jacob Henner
jacobhenner at outlook.com
Wed May 14 04:00:01 CEST 2025
berkeleydb is segfaulting on Arch Linux amd64, with Python 3.13 and
either libdb 6.2.32 or libdb 5.3.28. Both Python 3.13.0 and 3.13.3 were
confirmed to be affected. 3.12.10 is not affected.
This reproducer [1] (for a separate issue) will trigger this segfault,
but it seems to be trivially invoked by `berkeleydb.hashopen(...)`
without any additional steps.
Stack trace:
#0 0x00007a69663ced7a n/a (libc.so.6 + 0xb8d7a)
#1 0x00007a696637b437 n/a (libc.so.6 + 0x65437)
#2 0x00007a696637c1e4 n/a (libc.so.6 + 0x661e4)
#3 0x00007a6965e9e05a __db_errfile (libdb-6.2.so + 0x12005a)
#4 0x00007a6965e9e634 __db_errx (libdb-6.2.so + 0x120634)
#5 0x00007a6965ec98f5 __env_set_create_dir (libdb-6.2.so + 0x14b8f5)
#6 0x00007a6965f8bbc9 DBEnv_set_lk_detect (_berkeleydb.abi3.so + 0x12bc9)
#7 0x00007a69666f87b1 method_vectorcall_VARARGS (libpython3.13.so.1.0 + 0xf87b1)
#8 0x00007a69666ead3f _PyObject_VectorcallTstate (libpython3.13.so.1.0 + 0xead3f)
#9 0x00007a69668462fc _PyEval_EvalFrameDefault (libpython3.13.so.1.0 + 0x2462fc)
#10 0x00007a696685182d _PyEval_EvalFrame (libpython3.13.so.1.0 + 0x25182d)
#11 0x00007a69668ba10e run_eval_code_obj (libpython3.13.so.1.0 + 0x2ba10e)
#12 0x00007a69668ba467 run_mod (libpython3.13.so.1.0 + 0x2ba467)
#13 0x00007a69668bc659 pyrun_file (libpython3.13.so.1.0 + 0x2bc659)
#14 0x00007a69668bcc5c _PyRun_AnyFileObject (libpython3.13.so.1.0 + 0x2bcc5c)
#15 0x00007a69668e78a9 pymain_run_file_obj (libpython3.13.so.1.0 + 0x2e78a9)
#16 0x00007a69668e80a6 pymain_main (libpython3.13.so.1.0 + 0x2e80a6)
#17 0x00007a696633d488 n/a (libc.so.6 + 0x27488)
#18 0x00007a696633d54c __libc_start_main (libc.so.6 + 0x2754c)
#19 0x00005e053566b075 _start (/home/arch/.pyenv/versions/3.13.3/bin/python3.13 + 0x1075)
ELF object binary architecture: AMD x86-64
--
Jacob Henner
[1] This reproducer
https://gist.github.com/JacobHenner/8af2eeb7bfa29475aa203abcd526dccc
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.jcea.es/pipermail/pybsddb/attachments/20250513/31944705/attachment.htm>
More information about the pybsddb
mailing list