Skip to content

Picker freezes when picking a Sony RAW format (and possibly other non-supported format) #824

@BillBunting

Description

@BillBunting

Describe the bug
When displaying the picker, choosing a Sony RAW formatted file causes the picker to freeze displaying a progress view.

To Reproduce
Steps to reproduce the behavior:

  1. Call:
let picker = YPImagePicker(configuration: config)
self.addChild(picker);
self.view.addSubview(picker.view)
picker.didMove(toParent: self);

picker.didFinishPicking { [unowned picker] items, _ in
// NEVER RETURNS with RAW files. 
            self.selectedItems = items
            /// code 
           picker.dismiss(animated: true, completion: nil)
       } 

with config 

var config = YPImagePickerConfiguration()
       
       config.usesFrontCamera = false
       config.shouldSaveNewPicturesToAlbum = false
       config.startOnScreen = .library
       config.screens = [.library, .photo]
       config.onlySquareImagesFromCamera = false
       config.showsPhotoFilters = false
       
       config.library.mediaType = .photo
       config.library.onlySquare = false
       config.library.isSquareByDefault = false
       
       config.icons.capturePhotoImage = config.icons.capturePhotoImage.withRenderingMode(.alwaysTemplate)

  1. Select a raw file (tap an image) then select Next
  2. Observe the app freezes displaying a progress view over the selected image and in the navigation bar.

Expected behavior
Return the RAW image or display an error that the format is not supported.

Screenshots
If applicable, add screenshots to help explain your problem.

Environment (please complete the following information):

  • Device: any iPhone or iOS device
  • OS: iOS 18 (or prior)
  • Xcode Version 16.1
  • Swift Version 5

Installation Type

  • Cocoapods

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions