Python print stops printing
I’ve created a script that only prints a dot (.) when a process with a tag has been processed. For every process there can be a couple of hunderds of dots printed. I noticed that after a while the dot’s didn’t appear anymore.
A bit of googling gave me the answer:
End the print statement with “, flush=True” and then the print command will output immediately.
So the commandprint('.', end='')
needs to be changed toprint('.', end='', flush=True)