io.open is too strict on py2 - cannot write non unicode text