wdWriteWithStream does not work with dio 5.0.1
Hello, thanks for this very nice package.
It seems that since updating to dio 5, on Web, the wdWriteWithStream functions gives an error. Catching this error gives a DioError: null, but digging forward seems to indicate that the stream is consumed twice along the line.
It works with Android though.
Best regards.
It seems that forcing the content type to be "application/octet-stream" into the client solves the error. It prevents from trying to guess the content type from the stream and consuming it...
client.c.options.contentType = "application/octet-stream";
@nicolaspernoud thanks very much. I seem to have found another problem that "dart: io" is not suitable for the web platform. I need time to properly reconstruct the project. The problem you mentioned may be caused by the modification of the "_transformData" method in "dio: 5.0". I may fix the bug and fully test the web platform to make it universal during project reconstruction.
Good news. By the way, there is another problem that I found, but I think it is caused by dio as well : it it not possible to upload large (several Gb) files with web : it seems that dio does not really stream the data (!?).