miguelpruivo / flutter_file_picker

File picker plugin for Flutter, compatible with mobile (iOS & Android), Web, Desktop (Mac, Linux, Windows) platforms with Flutter Go support.
MIT License
1.29k stars 632 forks source link

FIle image picker doesn't work on latest IOS 14 #405

Closed lecicdjuro closed 3 years ago

lecicdjuro commented 3 years ago

file_picker:2.0.1+1

Describe the bug I have granted photos permission before a pick image files, and after i pick one, i got an error

Issue details

  1. IOS
  2. 14
  3. jpg
  4. pick a single file type image

Error Log

Flutter Version details 1.22.0-12.1.pre

miguelpruivo commented 3 years ago

Related to #406.

miguelpruivo commented 3 years ago

@lecicdjuro this should be fixed with 2.0.1+2. Would you mind give it a try and see if it's working for you?

lecicdjuro commented 3 years ago

@miguelpruivo The issue is still present. The first pick works ok, and also every next if you choose the same file, but if i choose some other item from the picker, I get an error message ERROR] Could not create a bookmark: NSError: Cocoa 257 "The file couldn’t be opened because you don’t have permission to view it." }

miguelpruivo commented 3 years ago

@lecicdjuro yes, there’s still an issue with it for iOS 14. I’m investigating.

miguelpruivo commented 3 years ago

Hey y'all, could you please give it a try pointing to:

file_picker:
    git:
      url: https://github.com/miguelpruivo/flutter_file_picker
      ref: fix/ios14-picker

And let me know if it's working for you?

There are still a few minor issues with the PHPicker on their end (Apple) that have been reported and they're fixing it, but it should be stable enough for it to work.

Specially, that one that you've mentioned @lecicdjuro, check it here.

miguelpruivo commented 3 years ago

This should be fixed with 2.0.6.

Feel free to reopen this or report on #407 if you still encounter any issue related to it.

Thank you!

adnankhan74444 commented 3 years ago

[ERROR] Could not create a bookmark: NSError: Cocoa 257 "The file couldn’t be opened because you don’t have permission to view it." }

miguelpruivo commented 3 years ago

@adnankhan74444 ignore it. That hasn't any effect.

sproutlyCaleb commented 2 years ago

I am getting this error. The picker opens fine and I am able to select images from my gallery but afterwards I get this error.

file_picker: ^4.2.7

***** Picker:<PHPickerViewController: 0x10af2a2b0> didFinishPicking:( "<PHPickerResult: 0x2833bf240>", "<PHPickerResult: 0x2833a2f40>", "<PHPickerResult: 0x2833a3800>" )

***** Could not load the picked given file: Error Domain=NSItemProviderErrorDomain Code=-1000 "Cannot load representation of type public.item" UserInfo={NSLocalizedDescription=Cannot load representation of type public.item, NSUnderlyingError=0x283d0aeb0 {Error Domain=NSCocoaErrorDomain Code=4101 "Couldn’t communicate with a helper application." UserInfo={NSUnderlyingError=0x283d000c0 {Error Domain=PHAssetExportRequestErrorDomain Code=3 "(null)" UserInfo={NSUnderlyingError=0x283d0b9c0 {Error Domain=CloudPhotoLibraryErrorDomain Code=1005 "Disk space is very low" UserInfo=0x28338ae80 (not displayed)}}}}}}