I writed simple code for test, how much files may be open in python script:
for i in xrange(2000): fp = open(\'files/file_%d\' % i, \'w\') fp.write(s
Since this is not a Python problem, do this:
for x in xrange(2000): with open('files/file_%d' % x, 'r') as h: print h.read()
The following is a very bad idea.
fps.append(h)