I've been trying to write my output to the same line and have already searched Stackoverflow. It seems what works for everyone else is not working for me !! Here's my code:
count = float(len(emails))
counter = 0
symbols = ["/","-","|","\\","|"]
for e in emails:
print '%s inserting emails %s%%\r' % (symbols[counter % 5], counter / count * 100),
sys.stdout.flush()
counter += 1
The comma after the print still causes a carriage return !!
| inserting emails 3.312%
\ inserting emails 3.313%
| inserting emails 3.314%
/ inserting emails 3.315%
- inserting emails 3.316%
| inserting emails 3.317%
\ inserting emails 3.318%
What is the issue?