implemented read/write on python containers