ousttrue / pymeshio

3d model reader/writer for python
http://pypi.python.org/pypi/pymeshio/
92 stars 27 forks source link

StringIO streams are not io.IOBase streams #33

Open Tcll opened 9 years ago

Tcll commented 9 years ago

what I'm doing: model = pmd_read( StringIO( string()(0) ) )

string()(0) is part of my automated frontend for my program's import/export scripts. which returns a string of the imported file.

pmd_read is forwarded from an extended library used by the script, which forwards pymeshio.pmd.reader.read

I'm not able to get the file() stream as the file is closed before the script is called. (the file data is backed up as array('B',[]) before string()() converts it for the script)

Tcll commented 9 years ago

got it working by commenting out the assert(isinstance(ios, io.IOBase)) codes.