The problem is that, after readline() reaches the end of the file, it will continue to return empty lines. You need something that ends the loop so that you can start over on the beginning of the file:

from time import sleep
while True:
with open ("sample.txt", 'r') as test:
for line in test:
print line.rstrip()
sleep(3)

If you really want to use readline, then you need to test for the end of file. While readline is reading actual lines, it will always return at least a newline character. If it returns nothing, then it has reached the end of the file. Thus:

from time import sleep
while True:
with open ("sample.txt", 'r') as test:
while True:
line = test.readline()
if not line:
break
print line.rstrip()
sleep(3)

Email codedump link for How to print a file line by line in specific interval continuously using python?