-
Notifications
You must be signed in to change notification settings - Fork 25k
Description
Description
I try to send a large FormData in a fetch request with only strings and bool.
If i send more than exactly 230 lines in _parts (params of the FormData request), a native crash occur on iOS.
I there a limitation on this ? I can't find infos
IMPORTANT UPDATE
This crash only occur in debug
React Native Version
0.70.5
Output of npx react-native info
System:
OS: macOS 13.2.1
CPU: (8) arm64 Apple M1
Memory: 55.70 MB / 16.00 GB
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 19.8.1 - /opt/homebrew/bin/node
Yarn: 1.22.19 - ~/Documents/Dev/bilnetmobile-bls/node_modules/.bin/yarn
npm: 9.5.1 - /opt/homebrew/bin/npm
Watchman: 2023.03.20.00 - /opt/homebrew/bin/watchman
Managers:
CocoaPods: 1.11.3 - /opt/homebrew/bin/pod
SDKs:
iOS SDK:
Platforms: DriverKit 22.4, iOS 16.4, macOS 13.3, tvOS 16.4, watchOS 9.4
Android SDK: Not Found
IDEs:
Android Studio: 2021.3 AI-213.7172.25.2113.9014738
Xcode: 14.3/14E222b - /usr/bin/xcodebuild
Languages:
Java: 11.0.17 - /Users/bil/.jenv/shims/javac
npmPackages:
@react-native-community/cli: Not Found
react: 18.1.0 => 18.1.0
react-native: 0.70.5 => 0.70.5
react-native-macos: Not Found
npmGlobalPackages:
react-native: Not Found
Steps to reproduce
- Write a fetch request with a content-type multipart/form-data
- Append 230+ lines in the FormData
- Test on iOS
- Crash
Snack, code example, screenshot, or link to a repository
export const myRequest = async countries => {
fetch(url, {
method: "POST",
headers: {
"Content-Type": "multipart/form-data",
...headers
},
body: myFormData,
lang: 'fr'
})
.then(response => response.json())
.catch(e => console.error(e))
}
