-
Notifications
You must be signed in to change notification settings - Fork 148
File download issue with files size 2GB+ #407
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
i have made some modifications and now it works fine issue was to fix some sort of OKio bug content length's max value was set to Integer.MAX_VALUE !!!! Caution : I don't have any particular knowledge of Java and don't know any breaking effects !!!
i have modified reportProgress parameter (Only contentLength() with originalBody.contentLength()) and also for isDownloadComplete methods first condition now react-native will receive correct total value and isDownloadComplete will be triggred at final complete |
Could you create a pull-request? Makes it easier to check and test |
Versions Information:
Issue:
Used Code:
###What's happing
I am downloading files larger then 2 gb in progress callback the total is fixed to
2147483647
(Approx 1.9999GB) (Also The 32-bit Java int cango to a maximum of 2,147,483,647), but received works perfectly fine (it's values go beyond total with file size 2GB+).
while downloading large file
received(process callback params)
works correctly even for 2GB+ fileProcess callback keep triggering until full
received
is equal to real file size and then it is not calledbut still task.then (Promise resolved) never triggered
!!!!Important: Full file is downloaded and saved even though promise never resolve
The text was updated successfully, but these errors were encountered: