I'm receiving an IOError when trying to create a file using open() in python, which only seems to occur for a single filename. The directories definitely exist and permissions are granted, the loop created around 1000 files successfully. When epic = "CON" in the code below I receive the "No such file or directory" error, but it works fine for other values.
f = open('data\\LSE\\%s.csv' % epic.strip(),'w')
f.write(u.read())
f.close()
Could this be a race issue? The files are created quite quickly.
I'm new to python so if there's something obvious I missed, apologies!
print repr(epic)print?