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

The path returned by FilePicker.platform.saveFile does not exist on ios #1504

Open
1 of 4 tasks
kjxbyz opened this issue May 7, 2024 · 2 comments
Open
1 of 4 tasks
Labels
new issue An issue that hasn't yet been seen from the maintainer stale

Comments

@kjxbyz
Copy link

kjxbyz commented May 7, 2024

Before creating an issue, make sure that you are on the latest file_picker version and that there aren't already any similar opened inssues. Also, check if it isn't described on the Wiki, specially on Troubleshooting page.

Also, sometimes a simple flutter clean and flutter build again with latest file_picker version, may end up by fixing cached issues, so I encourage you to first do so.

Describe the bug
The path returned by FilePicker.platform.saveFile does not exist on ios

Platform

  • Android
  • iOS
  • Web
  • Desktop

Platform OS version
What version did it happen?

How are you picking?

final savedPath = await FilePicker.platform.saveFile(
                          fileName: '${DateFormat("yyyy-MM-dd'T'HH:mm:ss").format(DateTime.now())}.png',
                          type: FileType.image,
                          bytes: bytes,
                        );

Details to reproduce the issue
The path returned by FilePicker.platform.saveFile does not exist on ios

Error Log

flutter: │ 🐛 savedPath: /private/var/mobile/Containers/Shared/AppGroup/B14C6240-7E8C-49CE-99BB-8F7AF53EA84A/File Provider Storage/ep-signature-2024-05-07T14:08:14.png
flutter: └───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
flutter: \^[[38;5;196m┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────<…>
flutter: \^[[38;5;196m│ 'package:image_cropper_platform_interface/src/method_channel/method_channel_image_cropper.dart': Failed assertion: line 72 pos 12: 'await File(sourcePath).exists()': is not true.<…>
flutter: \^[[38;5;196m├┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄<…>
flutter: \^[[38;5;196m│ #0   _AssertionError._doThrowNew (dart:core-patch/errors_patch.dart:51:61)<…>
flutter: \^[[38;5;196m│ #1   _AssertionError._throwNew (dart:core-patch/errors_patch.dart:40:5)<…>
flutter: \^[[38;5;196m│ #2   MethodChannelImageCropper.cropImage (package:image_cropper_platform_interface/src/method_channel/method_channel_image_cropper.dart:72:12)<…>
flutter: \^[[38;5;196m│ #3   <asynchronous suspension><…>
flutter: \^[[38;5;196m│ #4   SignatureUtil.cropImage (package:expert_planet/modules/mine/utils/signature_util.dart:117:25)<…>
flutter: \^[[38;5;196m│ #5   <asynchronous suspension><…>
flutter: \^[[38;5;196m│ #6   MineDialogs.showUploadBottomSheet.<anonymous closure>.<anonymous closure>.<anonymous closure> (package:expert_planet/modules/mine/utils/mine_dialogs.dart:1512:48)<…>
flutter: \^[[38;5;196m│ #7   <asynchronous suspension><…>
flutter: \^[[38;5;196m├┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄<…>
flutter: \^[[38;5;196m│ ⛔ null<…>

Screenshots and/or video
If applicable, add screenshots or video to help explain your problem.

Flutter Version details

[✓] Flutter (Channel stable, 3.19.6, on macOS 14.4.1 23E224 darwin-x64, locale zh-Hans-CN)
    • Flutter version 3.19.6 on channel stable at /Users/ying/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 54e66469a9 (3 周前), 2024-04-17 13:08:03 -0700
    • Engine revision c4cd48e186
    • Dart version 3.3.4
    • DevTools version 2.31.1

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/ying/Android/sdk
    • Platform android-34, build-tools 34.0.0
    • ANDROID_HOME = /Users/ying/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.10+0-17.0.10b1087.21-11572160)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.3)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15E204a
    • CocoaPods version 1.15.2

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

[✓] Android Studio (version 2023.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.10+0-17.0.10b1087.21-11572160)

[✓] IntelliJ IDEA Ultimate Edition (version 2024.1.1)
    • IntelliJ at /Applications/IntelliJ IDEA.app
    • Flutter plugin version 79.0.3
    • Dart plugin version 241.15989.9

[✓] Connected device (5 available)
    • sdk gphone64 x86 64 (mobile) • emulator-5554                        • android-x64    • Android 13 (API 33)
      (emulator)
    • Kimmy's iPhone (mobile)      • 00008020-000A1D110A32002E            • ios            • iOS 17.4.1 21E236
    • iPhone 15 Pro Max (mobile)   • 24AF00F3-A044-453B-A4EF-01834A59AA46 • ios            •
      com.apple.CoreSimulator.SimRuntime.iOS-17-4 (simulator)
    • macOS (desktop)              • macos                                • darwin-x64     • macOS 14.4.1 23E224
      darwin-x64
    • Chrome (web)                 • chrome                               • web-javascript • Google Chrome
      124.0.6367.119
    ! Error: Browsing on the local area network for Kimmy's Apple Watch. Ensure the device is unlocked and discoverable
      via Bluetooth. (code -27)

Additional context
Add any other context about the problem here.

@kjxbyz kjxbyz added the new issue An issue that hasn't yet been seen from the maintainer label May 7, 2024
@kjxbyz
Copy link
Author

kjxbyz commented May 7, 2024

Sorry, I seem to have missed this configuration.

<key>UISupportsDocumentBrowser</key>
<true/>

Copy link

This issue is stale because it has been open for 7 days with no activity.

@github-actions github-actions bot added the stale label May 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new issue An issue that hasn't yet been seen from the maintainer stale
Projects
None yet
Development

No branches or pull requests

1 participant