Ich hatte ein ähnliches Problem, wenn Benutzer ihre Fotos in iCloud mit iCloud Foto-Bibliothek gespeichert hatten. Ich konnte das Problem beheben, indem ich den Anruf asynchron ausführte. Es sieht so aus
let options = PHImageRequestOptions()
options.synchronous = false
options.networkAccessAllowed = true
Hier ist die ganze Funktion.
func getImageDataFromAsset(asset: PHAsset, completion: (data: NSData?) -> Void) {
let manager = PHImageManager.defaultManager()
let options = PHImageRequestOptions()
options.networkAccessAllowed = true
options.synchronous = false
manager.requestImageDataForAsset(asset, options: options) { (result, string, orientation, info) -> Void in
if let imageData = result {
completion(data: imageData)
} else {
completion(data: nil)
}
}
}
@Vizllx danke für die Antwort eine Idee über Absturzbericht ?. Es sind alle iOS-Versionen passiert. – Madhubalan