[issue46490] Add "follow_symlinks=False" support for "os.utime()" on Windows

2022-01-23 Thread Delgan
New submission from Delgan : Hi. Currently, trying to use "os.utime(path, timestamps, follow_symlinks=False)" raises a exception on Windows: "NotImplementedError: utime: follow_symlinks unavailable on this platform". Looking at the Win32 API it seems possible to

[issue40399] IO streams locking can be broken after fork() with threads

2020-04-29 Thread Delgan
Delgan added the comment: Yeah, I just wanted to illustrate the issue with a more realistic example. The thread is often abstracted away by a class or a library. Conclusion: do not abstract it away. :) I've noticed that the mere fact of using "sys.stderr.write()", without even

[issue40399] IO streams locking can be broken after fork() with threads

2020-04-28 Thread Delgan
Delgan added the comment: Thank you for having looked into the problem. To be more specific, I don't generally mix threads with multiprocessing, but it's a situation where there is one global and hidden consumer thread listening to a queue for non-blocking logging. Actually, I think

[issue40399] Program hangs if process created right after adding object to a Queue

2020-04-28 Thread Delgan
Delgan added the comment: Another curiosity: if 'print("Consumed:", queue.get())' is replaced by either 'print("Consumed")' or 'queue.get()', then the program keeps running without stopping. Only a combination of both makes the program to hang. Also r

[issue40399] Program hangs if process created right after adding object to a Queue

2020-04-28 Thread Delgan
Delgan added the comment: I noticed the bug is reproducible even if the child process does not put object in the queue: import multiprocessing import threading import time if __name__ == "__main__": queue = multiprocessing.SimpleQueue() def con

[issue40399] Program hangs if process created right after adding object to a Queue

2020-04-26 Thread Delgan
New submission from Delgan : Hi. I have a very basic program: - one multiprocessing SimpleQueue - one consumer thread - one loop: - add one item to the queue - create a new process with itself add one item to the queue - wait for the process to end For some unknown reason, it will hangs

[issue38900] Add a glossary entry for "callable" objects

2019-11-23 Thread Delgan
Delgan added the comment: I agree, it's straightforward. I just thought it could be useful to have a proper definition in the official documentation. For example, this question on StackOverflow actually received many views: https://stackoverflow.com/questions/111234/what-is-a-callable What

[issue38900] Add a glossary entry for "callable" objects

2019-11-23 Thread Delgan
New submission from Delgan : Hi. Quick use case explanation about this: I would like to document my function, stating that it accepts any "callable" object and linking to a proper definition of such object. For example, I'm already doing this when my function accepts a &q

[issue38762] Logging displays wrong "processName" if "sys.modules" is cleared in child process

2019-11-10 Thread Delgan
New submission from Delgan : Hi. In order to display the process name in logs, the "logging" module checks for the presence of "multiprocessing" in "sys.modules" before calling "current_process()". If "multiprocessing" is not found in &