iOS 11 UIPasteboard can't determine if file is managed

We use UIPasteboard for transfering audio files to and from other apps, in wav format. This has worked since iOS 5.

However when trying to build under Xcode 9.3.1 and running under iOS 11 this is printed to the console:


2018-05-22 13:56:53.475509-0700 ***[613:66838] [default] [ERROR] Failed to determine whether URL /private/var/mobile/Containers/Data/Application/***/tmp/.com.apple.Pasteboard.O7u8eq/audio (n) is managed by a file provider


And the items fail to get added to the pasteboard.

I've tried setting a file provider:


[board setItemProviders:@[[[NSItemProvider alloc] initWithItem:items typeIdentifier:(NSString *)kUTTypeAudio]]];
[board setValue:items forPasteboardType:(NSString *)kUTTypeAudio];


To no avail.

Replies

I get a very similar error when sharing an image from Photos to a share extension

[ERROR] Failed to determine whether URL /var/mobile/Media/PhotoData/OutgoingTemp/02B57086-EFA9-4727-8810-280D030A3BC5/RenderedPhoto/IMG_0727.JPG (n) is managed by a file provider



I havent found the solution yet


Did you ever figure this out?

Nope.

BUGGED

On iOS 12, I have same error when I drag & drop an (audio) file into collectionView from FileApp.