[issue4944] os.fsync() doesn't work as expect in Windows
Emil Styrke
report at bugs.python.org
Thu Mar 26 07:40:11 CET 2015
Emil Styrke added the comment:
I have experienced this issue with Python 2.7.8 and 2.7.9. It is almost the same issue as the OP experiences as far as I can tell: spawn some Python threads that each create a file, flush, fsync, close, then start a subprocess which uses the file through the Windows API. One thing that may differ is that I create the file and spawn the child from the same thread.
I tried with close_fds=True, and it indeed works then, but like the OP, in my production code I need to get the output from the process, so it is not a usable workaround for me.
Test script and child program code is available at https://gist.github.com/anonymous/5d7d198cd3c22b31fa2a (the file upload button doesn't work for me it seems). Running the script on my machine will print at least one failure most of the time, but not always.
----------
nosy: +Emil.Styrke
versions: +Python 2.7
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue4944>
_______________________________________
More information about the Python-bugs-list
mailing list