if not os.path.exists(txt_fn):
print 'text file {} does not exists'.format(txt_fn)
continue
Error:
print 'text file {} does not exists'.format(txt_fn)
^
SyntaxError: invalid syntax
I am currently running python 2.7, so most likely issue i can think of is inconsistency with the version as the syntax might be in python 3.0 not supported but couldn't find a proof or fix it.