cannot import .mid files on IOS with UIDocumentPicker

I am implementing a file picker which allows users to select a .mid file stored on iPad. These midi files contain patch libraries for the Virus TI synthesizer. I think they have kind of syses data inside.

I have set the documenttype for the document picker to ["public.midi-audio"]. IT shows the midi files correctly and it allows me to select them.

Now the problem: When I test my app in simulator, as soon as I select a mid file, the didPickDocumentsAt function s not called. Instead an error message pops up:

Couldn't communicate with a helper application
Try your operation again.If that fails, quit and relaunch the application and try again.


I do not understand this message since my own app should be the helper application?

Now I wonder, is this error related to how the document picker performs within a simulated iPad. Or is it related to my code, or the selected files? Any thoughts on this would be highly appreciated!

Replies

When I test my app in simulator

What do you see on a real device?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"
Hi Eskimo!

Thanks, gave it a try, and it seems to works fine on a real iPad.
So the simulator doesn't seem to simulate that good, strange.
Is it something which can be solved or worked around?

greets,
Maarten

So the simulator doesn't seem to simulate that good, strange.

Yeah, that is quite strange. My advice here is to retest with Xcode 12 beta and, if it still fails, file a bug against the simulator.

Please post your bug number, just for the record.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"