Skip to content
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

Maximum concurrent tasks option doesn't work in iOS, when going offline download task doesn't fail #684

Closed
bshankar-coder opened this issue Jul 11, 2022 · 7 comments
Labels
bug Something isn't working

Comments

@bshankar-coder
Copy link

Maximum concurrent tasks option in iOS not working, flutter downloader downloads all items. When going offline mode downloading tasks not failing in iOS.

Steps to reproduce the behavior:

Used the example given by flutter_downloder plugin, did the configuration mentioned in flutter_downloader plugin iOS integration section from https://pub.dev/packages/flutter_downloader.

  1. Added example.
  2. Setup iOS config - Enable background mode, Added sqlite library, configured App Delegate, Disabled ATS completely, Configured maximum number of concurrent tasks to be 2.
  3. Clicked on multiple items to download.
  4. More than 2 items downloading at a time. (All of them)
  5. Switched off internet.
  6. Running downloads halted.
  7. Came back online downloads starts running again.

Expected behavior

Maximum concurrent tasks should work as it works for Android. In this case only 2 items must download others must remain in queue.
Like Android when going offline downloads must fail.

Screenshots
Screenshot 2022-07-11 at 5 53 44 PM

Device information:

  • Device: [iPhone 13 Pro - Simulator]
  • OS: [iOS 15.2]
  • plugin version [v1.7.2]

Additional context

Output of flutter doctor -v

[✓] Flutter (Channel stable, 2.10.2, on macOS 12.2.1 21D62 darwin-arm, locale en-IN)
    • Flutter version 2.10.2 at /Users/[email protected]/development/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 097d3313d8 (5 months ago), 2022-02-18 19:33:08 -0600
    • Engine revision a83ed0e5e3
    • Dart version 2.16.1
    • DevTools version 2.9.2

[✓] Android toolchain - develop for Android devices (Android SDK version 32.1.0-rc1)
    • Android SDK at /Users/[email protected]/Library/Android/sdk
    • Platform android-32, build-tools 32.1.0-rc1
    • Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.11+0-b60-7772763)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 13.2.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • CocoaPods version 1.11.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2021.1)
    • 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 11.0.11+0-b60-7772763)

[✓] VS Code (version 1.68.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.40.0

[✓] Connected device (3 available)
    • sdk gphone64 arm64 (mobile) • emulator-5554                        • android-arm64  • Android 12 (API 31) (emulator)
    • iPhone 13 Pro (mobile)      • 1EE2C303-EE3A-4368-89E8-313046FB03DF • ios            • com.apple.CoreSimulator.SimRuntime.iOS-15-2 (simulator)
    • Chrome (web)                • chrome                               • web-javascript • Google Chrome 103.0.5060.114

[✓] HTTP Host Availability
    • All required HTTP hosts are available

• No issues found!
@bshankar-coder bshankar-coder added the bug Something isn't working label Jul 11, 2022
@hemachandsai
Copy link

+1

2 similar comments
@vinuthna-tricon
Copy link

+1

@vishwajitrkt
Copy link

+1

@deckikwok
Copy link

+1
quite critical for my case since it is causing ext services to go 403

@bartekpacia
Copy link
Collaborator

bartekpacia commented Aug 17, 2022

Hi, thanks for the report. I confirm I can reproduce this problem. I hope to find some time to work on the fix, but no promises, unfortunately :)

Maximum concurrent tasks option in iOS not working, flutter downloader downloads all items. When going offline mode downloading tasks not failing in iOS.

Are these 2 independent issues?

@bartekpacia
Copy link
Collaborator

Just found out that this is the duplicate of #332. Please continue the discussion there.

@bartekpacia bartekpacia closed this as not planned Won't fix, can't repro, duplicate, stale Aug 18, 2022
@bshankar-coder
Copy link
Author

Hi, thanks for the report. I confirm I can reproduce this problem. I hope to find some time to work on the fix, but no promises, unfortunately :)

Maximum concurrent tasks option in iOS not working, flutter downloader downloads all items. When going offline mode downloading tasks not failing in iOS.

Are these 2 independent issues?

Yes there are two issues, one being about concurrency and other is when we go offline in Android downloads fail but in iOS this it doesn't.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants