I don't get it. Can someone explain to me how this is different or better than:
infile = open('site.log'); outfile = open('err.log', 'w')
for line in infile:
if 'ERROR' in line:
outfile.write(line)
infile.close(); outfile.close()
Sure, you're saving a line with the files being automatically closed at the end of your scope, but hardly "MIND == BLOWN".What am I missing?