subprocess stout to file: how to change buffer settings

I’m running Django on Apache and mod_wsgi. I have subprocesses that run fine, but the redirect of stdout to file is buffered and only gets written in chunks of 4096 bytes.
The command i use is:
process = subprocess.Popen(cmd, stdout=file, stderr=file, close_fds=True)
I have tried to add a parameter in Popen bufsize=0 for unbuffered but that does not change anything. Where i can change a setting to decrease the buffer, or even unbuffered if that is not a bad idea (similar to python -u). Thanks for any advice.