fluttercommunity / fluttercommunity/flutter_downloader
Warning: Attempt to present <UIDocumentPickerViewController: 0x12a5bdb70> on <BaseNavigationController: 0x104875800> whose view is not in the window hierarchy!
- Dominant language
- Kotlin
- Stars
- 940
- Forks
- 561
- Avg merge
- 1h 18m
- Merged PRs (30d)
- 1
Description
IOS and flutter are mixed development, and flutter is integrated into the IOS project. Find the following problem.
How to solve this problem, thank you.
**** Custom file type supported: public.zip-archive
* +[FileUtils resolveType:withAllowedExtensions:] [Line 58]
2020-08-11 10:55:29.004708+0800 Fresenius[17522:10638996] Warning: Attempt to present on whose view is not in the window hierarchy!
2020-08-11 10:55:29.326806+0800 Fresenius[17522:10639118] flutter: [MethodChannelFilePicker] Platform exception: PlatformException(multiple_request, Cancelled by a second request, null)
2020-08-11 10:55:29.327257+0800 Fresenius[17522:10639118] [VERBOSE-2:ui_dart_state.cc(157)] Unhandled Exception: PlatformException(multiple_request, Cancelled by a second request, null)
#0 StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:569:7)
#1 MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:156:18)
#2 MethodChannel.invokeMethod (package:flutter/src/services/platform_channel.dart:329:12)
#3 MethodChannelFilePicker._getPath (package:file_picker_platform_interface/method_channel_file_picker.dart:66:39)
#4 MethodChannelFilePicker.getFiles (package:file_picker_platform_interface/method_channel_file_picker.dart:25:7)
#5 FilePicker.getMultiFile (package:file_picker/file_picker.dart:84:65)
#6 _DdrPageFileUploadViewState.obtainFile (package:ddr_flutter_engine/WebComponents/PageFileUploadView/DdrPageFileUploadView.dart:55:41)
#7 _DdrPageFileUploadViewState.build. (package:ddr_flutter_engine/WebComponents/PageFileUploadView/DdrPageFileUploadView.dart:348:13)
#8 _InkResponseState._handleTap (package:flutter/src/material/ink_well.dart:779:19)
#9 _InkResponseState.build. (package:flutter/src/material/ink_well.dart:862:36)
#10 GestureRecognizer.invokeCallback (package:flutter/src/gestures/recognizer.dart:182:24)
#11 TapGestureRecognizer.handleTapUp (package:flutter/src/gestures/tap.dart:504:11)
#12 BaseTapGestureRecognizer._checkUp (package:flutter/src/gestures/tap.dart:282:5)
#13 BaseTapGestureRecognizer.acceptGesture (package:flutter/src/gestures/tap.dart:254:7)
#14 GestureArenaManager.sweep (package:flutter/src/gestures/arena.dart:156:27)
#15 GestureBinding.handleEvent (package:flutter/src/gestures/binding.dart:222:20)
#16 GestureBinding.dispatchEvent (package:flutter/src/gestures/binding.dart:198:22)
#17 GestureBinding._handlePointerEvent (package:flutter/src/gestures/binding.dart:156:7)
#18 GestureBinding._flushPointerEventQueue (package:flutter/src/gestures/binding.dart:102:7)
#19 GestureBinding._handlePointerDataPacket (package:flutter/src/gestures/binding.dart:86:7)
#20 _rootRunUnary (dart:async/zone.dart:1196:13)
#21 _CustomZone.runUnary (dart:async/zone.dart:1085:19)
#22 _CustomZone.runUnaryGuarded (dart:async/zone.dart:987:7)
#23 _invoke1 (dart:ui/hooks.dart:275:10)
#24 _dispatchPointerDataPacket (dart:ui/hooks.dart:184:5)
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the Flutter call at Ddr_flutter_engine/WebComponents/PageFileUploadView/DdrPageFileUploadView.dart lines 55 and 348, then trace MethodChannelFilePicker.getFiles and the iOS FileUtils.resolveType:withAllowedExtensions: entry at line 58. Reproduce the custom public.zip-archive request in the mixed Flutter/iOS setup. Done means file selection no longer presents from a view outside the window hierarchy and does not produce multiple_request or an unhandled exception.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- dart, flutter, ios
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100