[issue32485] Multiprocessing dict sharing between forked processes

2018-11-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: Gus, dict don't have a has_key() method in Python 3. multiprocessing objects are generally not fork-safe: multiprocessing has its own mechanisms to duplicate objects between processes, but you cannot assume that after calling fork() yourself, objects will

[issue32485] Multiprocessing dict sharing between forked processes

2018-11-09 Thread Ned Deily
Change by Ned Deily : -- nosy: +pitrou ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue32485] Multiprocessing dict sharing between forked processes

2018-11-08 Thread Tal Einat
Tal Einat added the comment: Is this supposed to work at all? Does multiprocessing support sharing resources between processes forked outside of its own abstractions? Reading the docs[1], calling os.fork() directly doesn't seem to be the way that the multiprocessing module is supposed to be

[issue32485] Multiprocessing dict sharing between forked processes

2018-11-07 Thread Gus Goulart
Gus Goulart added the comment: This is probably a bug that was fixed sometime in Python 3x. Testing on 3.7.1, Python gracefully errors out: ``` ➜ cpython git:(bpo-32485) ✗ python issue_32485.py Same manager, same mux Starting test_sameProcessSameThread Traceback (most recent call last):

[issue32485] Multiprocessing dict sharing between forked processes

2018-08-14 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- nosy: +pablogsal ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue32485] Multiprocessing dict sharing between forked processes

2018-05-15 Thread Leonard Lausen
Change by Leonard Lausen : -- nosy: +Leonard Lausen ___ Python tracker ___ ___

[issue32485] Multiprocessing dict sharing between forked processes

2018-01-03 Thread Raymond Hettinger
Change by Raymond Hettinger : -- nosy: +davin ___ Python tracker ___ ___

[issue32485] Multiprocessing dict sharing between forked processes

2018-01-03 Thread Christian Heimes
Christian Heimes added the comment: Don't worry about your choice of words. We usually use the C definition of the term crash. An exception is just a bug, but a segfault may be a security issue. -- ___ Python tracker

[issue32485] Multiprocessing dict sharing between forked processes

2018-01-03 Thread André Neto
André Neto added the comment: You are right, it does not segfault (sorry for the abuse of language). It raises an exception while accessing the shared dictionary. The exception varies but typically is: Traceback (most recent call last): File "multiprocessbug.py",

[issue32485] Multiprocessing dict sharing between forked processes

2018-01-03 Thread Christian Heimes
Christian Heimes added the comment: Does it it actually crash (segfault) or are you merely getting an exception? I'm just getting bunch of exception: Traceback (most recent call last): File "multiprocessing_crash.py", line 155, in

[issue32485] Multiprocessing dict sharing between forked processes

2018-01-03 Thread André Neto
New submission from André Neto : I'm working on a project where I need to share state between several processes (forked using gunicorn). I'm using dictionaries obtained from a multiprocessing SyncManager to achieve this. The issue is that if I have multiple forked