Adding provisioning profile to new device on existing project - ios

I'm confused as to how to add a provisioning profile to a new device. So I'm using Xcode 4.3.2, and TestFlight. I was given a pre-existing project and a team license via the company I'm helping out. The provisioning profile on developer.apple.com had certain devices already set up. So I added all these devices as testers to TestFlight, sent out an archived build, no problems, worked fine.
Now, one of the testers wants to try out testing on an iPad. So, I sent them an invite via TestFlight, and their device automatically registered on TestFlight. I see their UDID, and device, etc. However, their device is listed under "Teammates Devices Not On This Profile". So, I followed the prompts, exported the missing UDID to a file, and uploaded the file to the Provisioning Portal. I see the iPad now under "Devices" in the Provisioning Portal, however it is listed with 0 profiles associated. How to I associate the provisioning portal of this app with the iPad? Is there some simple step I'm missing? Keep in mind this iPad is in a foreign location, so I have no control over it. I need to tell them what they need to do (or automate it myself). Please help!

You need to add the device to the provisioning profile. Then, build the project again using the updated provisioning profile. And upload that build to test flight.
Or, I believe TestFlight has a new feature that allows you to simply update the build with the new profile without having to create a new build.

Related

Do I need an iPhone for TestFlight? [duplicate]

I have enrolled to Apple Developer Program to release my first app. My app's bundle ID is the same at developer.apple.com, at appstoreconnect.apple.com and in my XCode project. However, XCode still gives the error in "Signing & Capabilities" tab:
Failed to create provisioning profile.
There are no devices registered
in your account on the developer website. Plug in and select a device
to have Xcode register it.
And another error:
No profiles for ‘com.xxx.yyy’ were found
Xcode couldn't find any iOS
App Development provisioning profiles matching ‘com.xxx.yyy’.
First error message made me think that a physical connection to an iPhone is required to create a provisioning profile.
I have never connected a physical device to my Mac before. I made my tests by iOS simulator. I was planning to do my physical device testing via Testflight.
Do I have to physically (via a USB cable) connect an iPhone to my Mac in order to create a provisioning profile? If not, what might be wrong?
Is it required to have provisioning profile in XCode to be able to use Testflight or publish an app to App Store?
Do I have to physically (via a USB cable) connect an iPhone to my Mac in order to create a provisioning profile?
Yes, if you want to use automatic signing. An automatic provisioning profile unites a computer and a device and an app; it says that this computer is allowed to build this app onto this device. Until Xcode sees the device, it can’t create the profile.
The alternative is to switch to manual signing. It’s more work but now you can generate the profiles yourself.
You do NOT need a physical iOS device (iPhone or similar) to upload an app to App Store! Whether for real or TestFlight.
I realize this qn is old now, but I'm writing this for people like me, who stumble in here fighting the same problem... 😏
What you need to upload apps on App Store:
A MacOS machine (not too old)
A paid Apple Developer Account
An app signing certificate from the above account
A provisioning profile, with or without a physical device
When trying to create a new provisioning profile in your Apple Developer Account, the first option is:
iOS App Development
Create a provisioning profile to install development apps on test devices.
See:
If you chose this option, you need a physical device! In fact, the way I understand it, you are supposed to register the UDIDs of ALL the phones and tablets that you want to test your app on...
If, like me, you don't have an iOS device, you can instead chose the last option in the list:
Developer ID
Create a Developer ID provisioning profile to use Apple services with your Developer ID signed applications.
See:
This one only requires an Apple Developer ID!
At the end of your create-provisioning-profile process, you have to download your profile and open it in Finder to install it (in XCode or whatever you're using). In your project, you have to switch from "automatic signing" to "manual signing". In XCode, this is done here:
If, like me, you had already downloaded your app signing certificate and installed it in your KeyChain app, you may run into this error when trying to apply your provisioning profile:
"Provisioning profile 'your profile name' doesn't include signing certificate 'your certificate name'".
The way I solved this error was:
In KeyChain:
Exporting my Apple Developer certificate to a .p12 file.
Deleting my Apple Developer certificates.
Re-importing the exported certificate file to keychain.
In XCode:
Close and re-start XCode
In the "Signing & Capabilities" tab in the project, de-select the newly downloaded profile and then select it again.
Now, it works! 🙂 From there, you should be able to follow any tutorial for uploading an app to App Store.

Firebase App Distribution - "Waiting for developer" message

I'm developing an iOS application and using App Distribution to distribute my test releases to QA Team, I didn't had any problem before, everything was smooth and pretty (estrange considering iOS development hehe)... but recently I face a problem that I can't resolve and I didn't found any documentation about it.
I constantly adds new Testing devices to the project (as the QA team grows) and follow the same steps...
Adds the new account to my tester list in Firebase.
Get the register attempt with the UDID of the new device.
Register the new device UDID in the Apple Developer Console
Distribute a new release of the app through App Distribution.
Install the certificate in the device
And voila, download the new distribution.
But this case is different... because in this iPhone XS Max with the latest iOS version, the download button never appears, and we just can see the following message: "Waiting for developer".
I try a lot of different solutions, redownload and import the Profile, to redistribute the app, create new profiles, force new devices in Fastlane, delete and readd the UDID in developer console... dammit... I create new certificates in my rage hahaha... but the problem persist, anyone face this problem before?
Update
I sent a ticket to Firebase support center, and they told me that the UDID wasn't in the distribution profile, so my solution was recreate the profile, because download and import the ad-hoc profile didn't work.
This issue isn't a Firebase problem, it was a classic issue related to iOS signing hell.
I had the same problem when tried to add device for Firebase Testing.
I made all instructions from Firebase troubleshooting.
If you're installing an Ad Hoc distribution, the Waiting for developer
button appears when the developer hasn't yet configured their app to
run on your test device. To make their app available to you, the
developer must complete the following steps:
Add the test device's UDID in the Apple Developer portal (the UDID is emailed to the developer when you register the device to
Firebase).
Include the device in the app's provisioning profile.
Build the app using the updated provisioning profile.
Distribute the new build using the Firebase console, the CLI, or fastlane.
https://firebase.google.com/docs/app-distribution/troubleshooting?platform=ios#waiting-dev-ios
Than I noticed that all of my provision files (for me it was folder /Users/user/Library/MobileDevice/Provisioning Profiles) not include UDID of new device. Every file can be previewed if you will choose view mode or right click on it, select "Get Info" and expand "Preview" block. If you will scroll to bottom you will see block "PROVISIONED DEVICES" with codes of your devices.
For me the problem solved when I found files which descriptions had "IOS Team Provisioning Profile: my.bundle.name" and "Developer Profile Name: my.bundle.name" ("Developer Profile Name" is profile name which you see in your Profiles list at https://developer.apple.com/account/resources/profiles/list).
I moved 2 files (which descriptions started from "IOS Team Provisioning Profile: my.bundle.name" and "Developer Profile Name: my.bundle.name") from /Users/user/Library/MobileDevice/Provisioning Profiles to another folder (I was afraid to lose it and not removed, just moved)
Opened XCode
Selected menu XCode -> Preferences
Selected Accounts
Chose my e-mail account name
Selected MyTeamName and clicked button "Download Manual Profiles"
Selected my Personal Profile and clicked button "Download Manual Profiles"
After it in the folder "Provisioning Profiles" appeared two new provision files and I found the name of my device in the bottom of their descriptions.
Than i cleaned project rebuild app-file and distributed it on test and all worked.

"TestFlight Users In The Provisioning Profile" doesn't coincide with users in the AdHoc provisioning profile

I have created a totally new TestFlight account, when I add the build to the account I see 79 users under TestFlight Users In The Provisioning Profile. The problem is that I have built the application using an ADHoc provisioning profile that contains just 3 devices, so why I'm seeing the full list of devices that I've registered with the Apple Developer Portal and not just the device that are available in the Provisioning profile (as stated by the sentence TestFlight Users In The Provisioning Profile) ?
I occasionally run into this problem and get it working again after trying a few things.
Restart Xcode. (It's amazing how often that solves the problem.)
Make sure that you are bundling the correct provisioning profile with the app when archiving and exporting. If you're using Xcode 6, the process has been changed a bit and you might be including the wrong profile. (Look in your Build Settings and then also look at the details on each screen as you are exporting the archive.)
Try re-generating your provisioning profile.
Make sure you have refreshed your account in Xcode so that it has the latest provisioning profile.
If those don't work, try creating a new signing certificate and generating your profile with that.
Then refresh your account in Xcode again.
If that's still not working, try removing your account from Xcode completely, restarting Xcode, and adding your account again.
Those are some of the tricks I use to get things working again. Maybe there is a more definitive answer out there.
I have also face the same problem.
This is because the provisioning profile you create from apple developer account.
Have that 79 devices register with that apple developer account.
Please check that account once.

Not able to give build permission to device on TestFlight

I want to give build permission to a particular device on TestFlight.
I have added that device on developer.apple.com and also added to provisioning profile I have uploaded to TestFlight. Also I have uploaded that profile to TestFlight.
I am able to add all other devices but not this particular device. On TestFlight it shows this device under Teammate devices not on this profile section. It does not show check box i.e. I can't add this device to build. :
How can I solve it?
Update : Below is what I tried but did not work unfortunately.
Created a new adhoc profile.
Removed all Xcode profiles and refreshed them to have newly created profile in Xcode.
Set Build Settings->Code signing identity->Provisioning profile to this new ad hoc profile.
Created .ipa signed with new profile and uploaded build to TestFlight.
Uploaded new profile to TestFlight.
Create a new profile on Apple's dev site. Name it something DIFFERENT from the current name. I usually append the date to mine so I KNOW which is which. Then, make sure you select the new one when building. If you have multiples with the same name it's a guessing game as to which one Xcode will choose when building your app. #rckoenes is correct - the UDID is NOT in the profile that is in the app that you uploaded to TestFlight. Using unique names will help alleviate this problem.
Add device UDID to devices on developer.apple.com then recreate developer provisioning profile and download it.After open it choose provisioning profile in XCode->targets->CodeSigning.Archive project and upload it to testFlight.

Add additional beta testers to IOS app

I have an IOS app currently being beta tested by a few people. I have a few more testers that I would like to add and distribute my beta app to. Can I simply add the devices and activate them in my distribution provisioning profile? Or do I need to download the updated profile and create a new archive with the updated device list?
If I do need to create a new archive, will the archives I sent the original testers still be valid or do they need the newly created one also? No code changes have been made.
You have to download the updated provisioning profile and rebuild the app using that profile.
An "Ad-hoc distribution profile" contains the list of allowed devices, and the app will
not install on other devices.
The previous version of the app continues to work on the devices that it was built for.
You need to add the new devices in the Provisioning Portal. Then add those devices to your Ad Hoc Distribution Provisioning Profile. You then have to download the provisioning profile and build an new archive with that profile. The previous archive is still valid and there is no impact to the previous testers.
The provisioning profile and application is installed on the users device user A and user B just have slightly differed versions. This is why I have automated setting CFBundleShortVersionString and CFBundleVersion as a build script. I display the version and build number in my about page. Also Crashlytics and TestFlight key off them.
What will kill all Ad Hoc builds you have in the field is deleting your certificate in the provisioning profile. But loosing your private key to the certificate would be a pain but not terminal. You would have to make a new one and recreate all you provisioning profiles and give new builds to all your testers. It will not effect your apps in the app store. Your distribution certificate is used by you to sign and certify your build. Apple then can know it really came from you they then remove your signing and resign it for the App Store.
My Check List
Add device in portal Edit TestFlight Distribution Profile
Add new devices
Delete old TestFlight Distribution Profile in the Xcode Organizer
Click refresh in the Xcode Organizer
Select TestFlight Distribution Profile in build setting
Commit project settings change from above step (committing increments my CFBundleVersion)
Build new archive
Up load to TestFlight
Notify / Authorize only the new devices / users

Resources