python-irodsclient icon indicating copy to clipboard operation
python-irodsclient copied to clipboard

[#722] fix segfault and hung threads on KeyboardIinterrupt during parallel get

Open d-w-moore opened this issue 6 months ago • 3 comments

Wherein we close down threads in an orderly way, so that things don't leave things to be disposed in the wrong order for the ever persnickety SSL shutdown logic.

Experiments show that SIGTERM actually does induce the Python interpreter to shut down non-daemonic threads, so installing a signal handler for that may not be necessary in the end.

d-w-moore avatar May 19 '25 17:05 d-w-moore

After a bit of manual testing, will attempt to make a proper test for SIGINT and SIGTERM to ensure things are left in an ok state.

d-w-moore avatar May 19 '25 17:05 d-w-moore

A GUI for example that maintains background asynch parallel transfers using PRC could trap and guard against Ctrl-C thusly:

from irods.parallel import abort_asynchronous_transfers
signal(SIGINT, lambda *_:exit(0 if abort_asynchronous_transfers() else 0))

d-w-moore avatar Jun 05 '25 18:06 d-w-moore

Looks like we have a conflict.

Seems this PR is close to completion?

korydraughn avatar Jul 08 '25 18:07 korydraughn

Just checking to see if this PR is still being considered for 3.3.0.

alanking avatar Dec 05 '25 21:12 alanking

Just checking to see if this PR is still being considered for 3.3.0.

Will check its currency to see whether the segfault is still a concern. If so, then I think we can consider it for this release.

d-w-moore avatar Dec 08 '25 08:12 d-w-moore