Menu
Eystein Bye

September 13th, Apple released iOS 10 giving developers the ability to make their own iMessage extensions. Writing an iMessage extension was fun, getting it approved in the App Store proved a bit more tedious.

If your iMessage App is embedding a framework, you most likely have seen this error message:

ERROR ITMS-90205: “Invalid Bundle. The bundle at ‘${bundlePath}’ contains disallowed nested bundles.”
ERROR ITMS-90206: “Invalid Bundle. The bundle at ‘${bundlePath}’ contains disallowed file ‘Frameworks’.”

The reason is that the frameworks should not be located in the extension target, but in the host/stub application.

Xcode 8 does not expose the ability to embed a framework in the stub application target containing your iMessage App. This is because your stub application does not contain a Run Script build phase. So you will need to use a workaround to move the framework to the correct location in the app bundle. Apple has published this workaround guide. In this guide you need to create an aggregate target that contains a Run Script build phase to move the frameworks to the correct location.

Since we were using Cocoapods to embed the frameworks we had to add the move script as the last build phase of the extension target itself.

After making these changes we were able to submit the iMessage app to the AppStore, and 30 hours later it was approved.

This posting was originally posted on medium.com