Friday, August 14, 2026
HomeiOS Developmentios - Unable so as to add useful resource after setting shouldMoveFile...

ios – Unable so as to add useful resource after setting shouldMoveFile to NO

[ad_1]

Lately we added a change in our app that modified the useful resource addition to Pictures – Till now we referred to as addResourceWithType:fileURL:choices: with PHAssetResourceCreationOptions.shouldMoveFile set to YES, and once we modified it to NO (the default worth) we noticed rather more asset creation failures. Particularly we see a brand new error code within the process – PHPhotosErrorNotEnoughSpace. One can clearly see a connection between including extra storage to the file system and an asset creation failure that’s associated to storage, however we’re struggling to know just a few issues:

  1. The storage of the gadget is all the time greater than the video dimension, often by a large amount – We noticed failures for gadgets with 120GB free storage, whereas the video dimension was 200MB.
  2. Typically we save numerous sources to the file system, so it’s fairly stunning to see supposedly storage points when including a comparatively low quantity of additional storage.
  3. The asset creation is a part of an even bigger process of encoding a video to a file system, after which transferring/copying it to Pictures. Is it that massive of a distinction to repeat a video of 100MB-200MB as a substitute of transferring it, such that the general process failure will enhance drastically?

Respect any assist.

[ad_2]

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments