We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
dio
5.3.2
flutter doctor -v
[✓] Flutter (Channel stable, 3.13.2, on macOS 13.5 22G74 darwin-x64, locale en-PK) • Flutter version 3.13.2 on channel stable at /Users/mac/development/flutter • Upstream repository https://github.com/flutter/flutter.git • Framework revision ff5b5b5fa6 (12 days ago), 2023-08-24 08:12:28 -0500 • Engine revision b20183e040 • Dart version 3.1.0 • DevTools version 2.25.0 [✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0) • Android SDK at /Users/mac/Library/Android/sdk • Platform android-34, build-tools 34.0.0 • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231) • All Android licenses accepted. [✓] Xcode - develop for iOS and macOS (Xcode 14.3.1) • Xcode at /Applications/Xcode.app/Contents/Developer • Build 14E300c • CocoaPods version 1.12.1 [✓] Chrome - develop for the web • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome [✓] Android Studio (version 2022.3) • Android Studio at /Applications/Android Studio.app/Contents • Flutter plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/9212-flutter • Dart plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/6351-dart • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231) [✓] VS Code (version 1.81.1) • VS Code at /Users/mac/Downloads/Visual Studio Code.app/Contents • Flutter extension version 3.72.0 [✓] Connected device (3 available) • iPad (mobile) • c484fc9175af0406e9a9afc9b14328a6ae72695e • ios • iOS 15.7 19H12 • macOS (desktop) • macos • darwin-x64 • macOS 13.5 22G74 darwin-x64 • Chrome (web) • chrome • web-javascript • Google Chrome 116.0.5845.140 [✓] Network resources • All expected network resources are available. • No issues found!
3.1.0
//Uploading file to presigned url
try { final response = await dio.put( 'url', data: File(file.filePath).openRead(), options: Options( contentType: file.mimeType, sendTimeout: Duration(seconds: 5), headers: { "Content-Length": File(file.filePath).lengthSync(), }, ), ); } catch (e) { if (kDebugMode) { print("error ${e.toString()}"); } rethrow; }
//Downloading file from presigned url
final response = await dio.download( 'download_url', 'savedPath', options: Options(receiveTimeout: Duration(seconds: 5)), );
On IOS it must throws an error after 5 seconds if internet turns off.
it throws error after 5 seconds if uploading/downloading not completed in duration with the availability of internet.
The text was updated successfully, but these errors were encountered:
The issue is also reproducible in version 4.0.6.
Sorry, something went wrong.
The flow is connect -> send/receive, so it should be connectTimeout here.
connect
send/receive
connectTimeout
No branches or pull requests
Package
dio
Version
5.3.2
Output of
flutter doctor -v
Dart Version
3.1.0
Steps to Reproduce
//Uploading file to presigned url
//Downloading file from presigned url
Expected Result
On IOS it must throws an error after 5 seconds if internet turns off.
Actual Result
it throws error after 5 seconds if uploading/downloading not completed in duration with the availability of internet.
The text was updated successfully, but these errors were encountered: