Moulde
Moulde

Reputation: 3506

"Please use a provisioning profile associated with team ID" When trying to distribute IOS app

I have a iphone app that i would like to submit to the app store.

The app is not yet submitted to the app store. The app is created in iTunes Connect. The app has been ad hoc distributed using a different appleID early in the development.

When i click "Distribute" in the Organizer after running "Archive" i get the following error:

ERROR ITMS-9000: "This app contains an embedded provisioning profile that 
is not associated with your account. Please use a provisioning profile associated with 
Team ID XXXXXXXXXX." at SoftwareAssets/SoftwareAsset (MZltmspSoftwareAssetPackage)

The developer account i am using has access to three different teams, and the team ID in the error message (XXXXXXXXXX) is one of the other teams that the developer account is a member of, and is the one that the app has previously been ad hoc distributed using.

I followed this guide on youtube, on how to set up the certificates and provisioning profiles, etc. http://www.youtube.com/watch?v=rRlOdp4uZoo

It seems that the project somehow still has a connection to the old team, but i don't understand why and how. In the general settings for the target, i have selected the correct team. And I also tried searching through the project files for the old team ID, but got no results. I can find multiple results in the project files if i search for the new team ID, but not the old.

Does anyone know how to solve this issue? The other answers i have found on SO is related to trying to update an already released app, with another developer account. Which is not the case here since the app has never been submitted to the app store before.

Thanks in advance

Upvotes: 1

Views: 1193

Answers (1)

njahnke
njahnke

Reputation: 1387

Be careful that you do not create your app in iTunes Connect using the wrong account. To be safe, you must log in to iTunes Connect using an "Agent" account of the desired Team. This may be different from your usual developer Apple ID. Then, log in with those same credentials when Xcode prompts "Log in to iTunes Connect" when submitting your app to the Store.

Upvotes: 1

Related Questions