Open plougsgaard opened 8 years ago
Not sure how to reproduce it, but looks like it happens when using fixed length request. I will look into it.
Android: RNFetchBlobBody.java : 199: header += "Content-Disposition: form-data; name=" + name + "; filename=" + field.filename + "\r\n";
IOS: RNFetchBlobReqBuilder.m: 203: [formData appendData:[[NSString stringWithFormat:@"Content-Disposition: form-data; name=\"%@\"; filename=\"%@\"\r\n", name, filename] dataUsingEncoding:NSUTF8StringEncoding]];
IOS have '\"' But Android not have。
@wkh237 Did you find anything ?
@havishhuda
it worked for me
RNFetchBlobBody.java : 199:
header += "Content-Disposition: form-data; name=\"" + name + "\"; filename=\"" + field.filename + "\"\r\n";
Hi @hujiudeyang facing the same problem here.
Everything works fine on android 5.0 and 5.1, IOs works fine too.
But on 6.0+ I have the same problem.
[Error: unexpected end of stream]
Did you solve this?
@wkh237 did you test this, or have some kinda of fix?
The error occurs in react-native-fetch-blob/index.js
I am using Android Oreo 8.0 on Galaxy S9 and Oreo 8.1 on PixelXL2 RN 0.55.0 React 16.3.2 react native fetch blob 0.10.8
Problem
I am making presigned
putObject
requests like this (to AWS S3):And it worked perfectly until I updated my Android SDK (to these versions):
I don't know what the versions were before and I don't think I can downgrade them either. Any clue where to start?
Edit:
PUT
ing withhttpie
still works as it did before.Versions
console.warn
in chrome dev tools consoleThis is what the dev tools give me before crashing the app with the
unexpected end of stream
error.Stacktrace from
adb logcat
Edit 2016-10-11
The same code is working on iOS (10.0.2).