Virtual IO: allow write() to return None

from https://docs.python.org/2/tutorial/inputoutput.html:

> `f.write(string)` writes the contents of *string* to the file, returning **None**.

Python 3 seems to create a [BufferedWriter](https://docs.python.org/3.4/library/io.html#io.BufferedWriter), which returns the number of bytes written.