The main problem was that I forgot to do seek(0). Thanks alot people. Though, as many times before, the problem was due to misunderstanding of how python works. I assumed file.read()[xx:yy] was to be understood as, in the file, read from index xx to place yy. That is, [10:20] was the same as, read from 10th char to 20th. Sort of.
Is it true then to say that every .read of a file, places an index-offset (?) from where the next read starts? That is, I need to rewind the file, or else the read will start from where the last read stopped? -- https://mail.python.org/mailman/listinfo/python-list