Post

Replies

Boosts

Views

Activity

PHPhotoLibrary.performChanges completionHandler not called when deleting assets on iOS 26
In my app, I use api provided in Photos framework to delete specified photo. But after upgrading to iOS 26, the delete function in some iOS device no longer work. The api will never triggers the system confirmation dialog, and the completionHandler is never called. In the iOS Photos app, deletion works correctly on the same assets, but calling the API from my app does not work. Steps to Reproduce Make sure the app has Full Photo Library Access. Execute the following code: PHPhotoLibrary.shared().performChanges({ let assetsToBeDeleted = PHAsset.fetchAssets(withLocalIdentifiers: delUrls, options: nil) PHAssetChangeRequest.deleteAssets(assetsToBeDeleted) }, completionHandler: completionHandler) Expected Behavior The system should present a confirmation dialog asking the user to delete the selected photos. After the user confirms, the deletion should occur, and the completionHandler should be called with success or error. Actual Behavior The system delete confirmation dialog does not appear. The completionHandler is never called. Environment iOS Versions: 26.1 / 26.0.1 It looks like api bug. I want to check Is it a know issue and will be fixed. Thanks
2
0
229
Nov ’25
disk full error when writing big file and enable iCloud Photos
Hello~I want to ask a storage issue I had recently. I found that my file writing will fail frequently if the iOS device enable iCloud Photos and the used storage is more than device storage. ex. iCloud Photos 707.8 GB used and choose to optimize iPhone Storage iOS Device UI shows that 185 GB is available (total 256 GB in device) What I need is to write a big file to upload later and I use FileHandle to generate it: ex. let fileWriter = try? FileHandle(forWritingTo: url) while !bufferIsAtEnd() { let data = readChunckFromBuffer() do{ try fileWriter.write(contentsOf: data) }catch{ return false } } fileWriter.close() The file needs about 40GB space to write, but I always get disk full error even though iOS UI shows me the device space is enough ( 185GB ) This issue disappeared if I turn off iCloud Photos. I think that the available 185 GB seems to be locked by iCloud storage optimization(The total device storage 256GB is smaller than 707GB used in iCloud Photos) and makes my file writing failed. I could not always turn off iCloud Photos since it is inconvenient but I do not know how to resolve the disk full issue when iCloud Photos enabled. Any suggestion will be very appreciated!
1
0
651
Apr ’24
High bitrate video streaming in avplayer sometimes audio disappears
Hello, I used AVPlayer in my project to play network movie. Most movie could play normally, but I found the sound will disappear sometimes if I play specified 4K video network stream. The video will continue playing but audio stops after video is played for a while. If I pause player and then resume, the sound will be back but disappeared again after several seconds Check AVPlayerItem status: isPlaybackLikelyToKeepUp` == true isPlaybackBufferEmpty` = false player.volume > 0 According the value above, it seems not cause by empty playback buffer or volume issue. I am so confused for this situation. Movie information Video Format : AVC Format/Info : Advanced Video Codec Format profile : High L5.1 Codec ID : avc1 Codec ID/Info : Advanced Video Coding Bit rate mode : Variable Bit rate : 100.0 Mb/s Width : 3 840 pixels Height : 2 160 pixels Display aspect ratio : 16:9 Frame rate mode : Constant Frame rate : 29.970 (30000/1001) FPS Audio Format : AAC LC Format/Info : Advanced Audio Codec Low Complexity Codec ID : mp4a-40-2 Duration : 5 min 19 s Bit rate mode : Constant Bit rate : 192 kb/s Nominal bit rate : 48.0 kb/s Channel(s) : 2 channels Channel layout : L R Sampling rate : 48.0 kHz Frame rate : 46.875 FPS (1024 SPF) Does anyone know if AVPlayer has this limitations when playing high-bitrate movie streams, and are there any solutions?
0
0
594
Nov ’24