Installing an app extension on a device?

I am trying to install my app extension on my iPhone but I am getting the following error:

This application or a bundle it contains has the same bundle identifier as 
this application or another bundle that it contains. Bundle identifiers must be unique.


The application container has a package ID: com.companyName.AppName and a package ID for the application extension com.companyName.AppName.WidgetApp.

I tried to sign the extension with the same grant, also I set a different AppID from the Apple developer site and new provisioning profiles for the app extension, and also tried to set the Widget extension subscription to automatic, but still the same error and the app cannot be launched on device.

What should I do to install my app extension on my device?

Here are screenshots of my General tab for my app and extension:

Application: enter image description here

Expansion: enter image description here



source to share

3 answers

The command execution clean

worked for me.

This is done through the Xcode menu item; Product > Clean




I had this exact issue and it was due to duplicate framework included in the assembly. I have included both test and non-test versions of the same dynamic framework. Once I removed one, the installation proceeded as expected.

I share this in the hope that it will help someone else if they come across this particularly obscure situation.



In Swift:

If you have installed pods, you need to change the package id as org.cocoapods.podName in general identity. Make sure the deployment target of all containers must be the same for the deployment target of projects.



All Articles