You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 5, 2021. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 5, 2021. It is now read-only.
Segfault when iterating through Python globals dictionary #177
This bug manifested itself as a failure of the unit test PyObjectTest.testDictCopy(). It can also be triggered by the following minimal snippet (Python 3.8, 64-bit Ubuntu Linux 20.04) (after setting the necessary jpy configuration properties and calling PyLib.startPython()):
The iteration succeeds for two loops, printing Entry: __name__ -> __main__ and Entry: __doc__ -> None. At the start of the third iteration it crashes with a segmentation fault. The culprit appears to be builtins.call("next", it) in the iterator returned by PyDictWrapper.EntrySet.iterator(). This calls through to PyObject.call(). The control flow continues into PyLib_CallAndReturnObject in org_jpy_PyLib.c, and eventually to this line:
Activity
pont-us commentedon Sep 2, 2020
Here's a minimal Java source file to reproduce the problem.
pont-us commentedon Sep 2, 2020
Attached: log file generated by running the test script above with
JPy_DiagFlags = JPy_DIAG_F_ALLset insrc/main/c/jpy_diag.c.hs_err_pid18349.log
ag-tcm commentedon Feb 6, 2021
@pont-us I came across this bug. Are you aware of any workaround? Thanks!