I am developing custom keyboard extension. It worked fine in both simulator and device until now.
After some small changes (adding import AudioToolbox
in one class and one command) it suddenly stopped working on the device. The app compiles and runs but then I acivate my keyboard XCode shows following error:
Lost connection to "My iPhone".
Restore the connection to "My iPhone" and run "xxx.xxx.xxx.xxx-Keyboard"
again, or if "xxx.xxx.xxx.xxx-Keyboard" is still running, you can
attach to it by selecting Debug > Attach to Process > xxx.xxx.xxx.xxx-Keyboard.
This error looks like the one that appears when iPhone cable is unplagged but the cable is all right in this case.
My keyboard itself is not launched - when activated (using globe key) there is few seconds delay (which is normal when my keyboard is loading in debug) and then the previously active keyboard is shown.
There are month of development in that project and I am completely stack so any help is very much appreciated.
Solution that worked for me: