displaying the timer every 1000 requests instead of every 10000

This commit is contained in:
kakwa 2016-09-09 00:03:42 +02:00
parent f5f6099abe
commit a4225b4810
1 changed files with 2 additions and 2 deletions

View File

@ -18,7 +18,7 @@ while True:
response = h1.getresponse()
h1.close()
counter += 1
if counter % 10000 == 0:
if counter % 1000 == 0:
new_time = time.time()
print( str(int(10000 / (new_time - old_time))) + " req/s (10000 requests in " + str(new_time - old_time) + " seconds)")
print( str(int(1000 / (new_time - old_time))) + " req/s (1000 requests in " + str(new_time - old_time) + " seconds)")
old_time = time.time()