Ios share extension does not work when installed by testflight but works installed by xcode - ios

Installed with testflight the application does appear in the list of target applications to share an image with. When I select my application icon in the list I do get a normal Post dialog. After pressing "Post" in the dialog the application does open but nothing else happens.
When the same version of application is installed with xcode the shared file is delivered and the application displays the shared image.
I am not even sure how to debug such an issue as the application installed by testflight does not appear in the list of installed applications in xcode Devices window. Nothing that I can find in device logs either.
Please suggest any approach to troubleshooting the issue.
Update: I found a way to get much more detailed logs from device than the one provided by xcode's "Devices" window: deviceconsole utility. This gives at least some information to approach troubleshooting.
Update 1: It turns out that the application installed through ad hoc ipa file exported from the same archive that was submitted to testflight shows the same problem. This allows much quicker testing turn around.
This answer indicates that the problem can be caused by "Deployment Target" of extension set above the ios version of test device. I did try different combination of this setting in the application and extension, nothing helped thus far.
Update 2: I created code-level support request with apple for this issue and provided full source of the application to them. After few months of apathetic communications they concluded that the problem is due to a bug and suggested to create report Apple Bug Reporter. I did that and after another few months of more apathetic communications the issue was promptly closed on the basis that the application does not crash. Frustrating, but I still need to resolve the problem, now looks like without help from vendor.

If the deployment target is higher than the version number of the actual phone, your code cannot run. So the only choice is reducing the deployment target of the extension to be the same as the app.
I’d check if you have somehow set different deployment targets for debug and release.

Related

Xcode 9 issues after cloning repo

This is an app I'm helping out with remotely. I have some issues right after cloning repo..
Assets folder is marked as modified. git status results: modified: AppName/Resources/Images.xcassets/AppIcon.appiconset/Contents.json. One of many compile warnings says "A 1024x1024 app store icon is required for iOS apps". Is new 1024x1024 asset placeholder the modification that was made?
Many warnings:
The app is running well in App Store and has support for iPhoneX, so if I clone, shouldn't all this stuff be sorted out already? I still see layout issues when I run in simulator on any device size that were apparently fixed for iphoneX compatibility. When I was running Xcode 8.3 I didn't have these issues.
I need to add a feature, push and make build available on TestFlight, but I'm worried about pushing with all these compile errors & bet it wont even archive with missing 1024x1024 asset.
Question:
Should I just go back to previous version of Xcode rather than sticking with 9.1 or resolve all this stuff myself? Devs aren't really available for me to consult with since initial app was developed through full-service software dev company.
Im mainly in contact with business ops/project managers who don't really have knowledge of tech at this level. Im no seasoned dev myself so I'd like some advice here before expressing concerns with managers or getting strings pulled to talk with devs who last worked on it.
I'm hoping the first comment isn't that this question doesn't belong here. I think its a fine line.
Thanks for your time.
The app in the appstore could be submitted and released to the appstore with issues listed in the issue navigator of the xcode on posted screenshot.
So, switching to a version of Xcode which was used for a last submit to the app store by previous developers does not guarantee that those issues will be not present.
There is only one issue which you have to resolve is "1024x1024 app store icon is required for iOS app" and this can be done only within Xcode 9

Application Loader stuck at "Authenticating with the iTunes store" when uploading an iOS app

We have been trying to submit an app to the iTunes store using Application Loader for three days and keep getting stuck at the "Authenticating with the iTunes store" step.
We have read many forums (including stackoverflow) and tried what was suggested:
making a new provisioning profile
using different or multiple versions of Application Loader
changing proxy settings
rebooting the Mac
uploading at a different time of the day, etc.
We have even left it running overnight and have not had success with getting past this step. Unfortunately, no feedback is given about what the issue may be, and we have not gotten any error messages. We have submitted multiple apps without any difficulty in the past but are completely stuck this time!
How were you able to solve it?
This only started happening to me today (May 2017) and no answers in this thread solved my issue. The resolution for me was from here;
https://forums.developer.apple.com/thread/76803
Open Terminal. Change to home directory,
cd ~
Move the current transporter directory,
mv .itmstransporter/ .old_itmstransporter/
Invoke the following file to let Transporter update itself.
"/Applications/Xcode.app/Contents/Applications/Application Loader.app/Contents/itms/bin/iTMSTransporter"
Wait till it updates, then open Xcode and attempt upload.
You have to agree to a new sign up in Application Loader. Select "Application Loader" under the "Xcode -> Open Developer Tool" menu (the first menu to the right of the Apple in the menu bar). Once you open Application Loader there will be a prompt to agree to new terms and then to login again into your iTunes account. After this any upload method will work.
Just wait. In a few minutes all will be ok.
Dec 10th 2019, Xcode Version 11.2.1, MacOS X 10.15.1
I was facing exactly same issue yesterday and I thought it might be network issues, at least it looks like so. But this morning I had tried couple different networks and several VPN connections, none of them is working!
The highest voted answer here asks me to reset a cache folder named .itmstransporter under my home dir, the run a program iTMSTransporter under a specific folder, but I can't find both of them.
But soon I figured that it is the cache folder for the people who uses the legacy uploader program: Application Loader, which is deprecated by Apple and can be no longer found in Xcode 11. Then I found that the latest Xcode has located iTMSTransporter here:
/Applications/Xcode.app/Contents/SharedFrameworks/ContentDeliveryServices.framework/itms/bin/iTMSTransporter
And its cache folder is here:
/Users/your_user_name/Library/Caches/com.apple.amp.itmstransporter/
I removed my existed cache folder, and run iTMSTransporter without any parameter, it soon started to output logs and download a bunch of files, and finished in 2 or 3 minutes. Then I tried again to upload my ipa file, it works!!!
CONCLUTION:
Either the old Application Loader, or the latest Xcode, uses a Java program iTMSTransporter to process the ipa file uploading.
To function correctly, iTMSTransporter requires a set of jar files downloaded from Internet and cached in your local folder.
If your cache is somehow broken, or doesn't exist at all, directly invoking iTMSTransporter with functional parameters such as --upload-app in our case, iTMSTransporter DOES NOT WARN YOU, NOR FIX CACHE BY ITSELF, it just gets stuck there, SAYS NOTHING AT ALL! (Whoever wrote this iTMSTransporter, you seriously need to improve your programming sense).
Invoking iTMSTransporter without any parameter fixes the cache.
A functional cache is about 65MB, at Dec 10th 2019 with Xcode Version 11.2.1 (11B500)
I was stuck at "Authenticating with the iTunes Store" today. I had used the same version and build number as a previous submission. After I updated the build number, the upload went fine. I don't know if it's related, or if it was a coincidence.
I had the same issue for months, I just removed hotspot shield and private tunnel applications from my computer and tried to upload my app and everything worked just fine. so I suggest if you have installed any VPN application on your computer, remove the application and then try uploading your app from either application loader or xcode's organizer.
Try answer mentioned in this Reference Link, it really worked for me and for others as well.
Mentioning answer here as well.
Open Terminal and run:
cd ~
mv .itmstransporter/ .old_itmstransporter/
"/Applications/Xcode.app/Contents/Applications/Application Loader.app/Contents/itms/bin/iTMSTransporter"
iTMSTransporter will then update itself, then you can try uploading in XCode again or via application loader.
There is no magic fix. Itunes is just working bad. Lately is having more and more issues and it takes more and more to update and send an ipa to the store.
I had this issue with AppLoader and Xcode organiser too and after trying multiple times it just went through.
Changing network connection helped.
Turned off wifi on my phone
Enabled 3G
Created HotSpot
Connected my mac to the hotspot and got through the authetication issue
In my case, I hadn't agreed to the newest Developer Agreement. Just run Application Loader once, click on [Accept] to agree, then quit the Application Loader and the Upload to App Store should work fine.
Following worked for me.
Open another instance of Application Loader.
( Select "Application Loader" under the "Xcode -> Open Developer Tool" menu)
"Agree" to the terms.
After completing Step 2. First instance of Application Loader proceeded to the next step and build got submitted.
I have also encounter the same issue. One possible solution is to go to Xcode -> Preferences -> Accounts and from the left menu select on App ID then click on the View Details and tap on the refresh button. while reloading you will get following error
The selected team's agent, 'ADMIN NAME' must agree to the latest
Program License Agreement.
If you will not get above error, Following solution will not work.
It means that you need to login into the developer account using Admin login and accept that latest agreement.
Then you will be able to upload binary on the app store.
The updated answer for Xcode 11.x.x and Transporter application, open terminal:
rm -rf ~/.itmstransporter/
"/Applications/Transporter.app/Contents/itms/bin/iTMSTransporter"
Wait a while
Problem solved!
I'm running MacOS Mojave 10.14.6, Xcode 11.3.1 and Transporter 1.1.1, and always got stuck at the Authentication with App Store stage, no matter how long I wait, I tried uploading using Xcode, using xcrun altool, Transporter, nada.
Finally I got it working by exporting the ipa file to a new Macbook (10.15.3, Xcode 11.3.1, Transporter 1.1.1), and used the Transporter app to upload it there.
The key difference is the Transporter tool on my new Macbook asked for a 6-digit code as authentication while the old Macbook did not, I suspect the authentication token on my old device expired but the system didn't ask for a new one when trying to upload the app. I had 2-FA enabled.
So I think forcing a manual re-authentication when you upload the app is the answer, the only other difference is the MacOS version, but I didn't test if it'll make a difference.
I solved the problem by removing ~/Library/Caches/com.apple.amp.itmstransporter.
For safety, renaming will be better,
cd ~/Library/Caches
mv com.apple.amp.itmstransporter com.apple.amp.itmstransporter.old
Then, xcrun altool uploaded my ipa successfully.
By the way, I'm using Xcode 11.x & 12.2, macOS Catalina.
In 2020 Dec, the fix did finally worked for me was restarting my mac.
Today I ran into this issue, on Xcode 11.2.1 I solved it by going to Xcode -> Preferences -> Accounts -> Tapped on the '-' next to my Apple ID, then signed in again. This fixed it for me!
In April 21, 2021, I followed #DawnSong's answer, outlined in the image below but I also restarted my Mac and voila it worked.
Spec
Xcode 12.4
macOS Big Sur 11.2.3
You may try to relogin your ITC account via Application Loader.
Just try a different Internet connection. I tried all the solutions above but none worked. However, when I tried using my cellular connection (instead of my DSL connection that stands behind a firewall), it worked immediately.
It might be a network issue. If you are running inside a virtual machine (e.g. VMWare or VirtualBox), try setting the network adapter mode from the default NAT to Bridged.
All i did was duplicate my Application Loader.app in /Applications and
ran both Application loaders at the same time.
this solution is out there, it used to work for me, but today not even that! what I did and worked is that (2 instances) + uploading with XCode (organizer). Had to try a couple of times and it worked.
hope this helps someone, this bug has been there for quite a lot of time now() an apple doesn't seem to care too much
Another reason could be that you have changed the machine from which you're submitting the app. Or the user account on the machine. The new machine may lack the private key and/or certificate for the App Store. Although a certificate with the correct name is displayed in Xcode.
In this case, go to https://developer.apple.com -> certificates, use the plus sign (+) to add a new certificate (distribution), and follow the steps to request a certificate for the private key on your current machine. After installing the certificate, authentication may work.
For me I tried almost all the suggestions given above but the problem still reoccurred after the first success in uploading to App store. Until I found this website. In summary, do the following
Open terminal
Run this command:
rm -rf ~/.itmstransporter/
“/Applications/Xcode.app/Contents/Applications/Application
Loader.app/Contents/itms/bin/iTMSTransporter”
Note: this command(which is different from others above) will delete your ITMSTansporter folder and create a new one and ensure that xcode is quitted before running this command.
3. Start Xcode and all should be well.
Using Xcode 12.3 Distribute App and xcodebuild both got stuck today at this point.
I finally was able to solve this. Peeking around my system I found 3 versions of iTMSTransporter.
Printing the version of each using ./iTMSTransporter -version gives the following results:
/Applications/Transporter.app/Contents/itms/bin/ has version 2.0.0
/Applications/Xcode.app/Contents/SharedFrameworks/ContentDeliveryServices.framework/Versions/A/itms/bin/ has version 2.1.0
/usr/local/itms/bin/ has version version 1.9.3
So it looks that old version in /usr/local/itms was used by Xcode. After deleting /usr/local/itms I was able to upload my binary within Xcode 12.2 and using the xcodebuild command line tool.
Check your firewall
Network settings - (Check with network admin, usually they have blocked apple services unknowingly)
Check your system data/time.
I had same sort of issue, I resolved it by getting direct access to internet.
Also check Application Loader logs to see at which point it gets stuck.
I think I followed all the approaches given, but none worked for me.
My own approach that seems to work for me is to go thru the initial steps to upload a binary, then, after selecting the binary, do NOT click Send; instead close the window, and in the new window that will appear, start anew: hopefully it will go thru.
Found the solution:
I was uploading the build, Every activity went well except “Authenticating with the iTunes store”.
I disconnected my LAN cable and Connected my MAC with my mobile hotspot. and authentication problem was solved. If you have a limited internet plan then as soon as you pass authentication stage, again connect your LAN so that it will upload the app from you LAN cable's internet connection.
my upload failed each time when I uncheck the "include bitcode" option when uploading. So I checked the "include bitcode" option and upload went well.
Check your Firewall, If it is "On" then just Off it, then try

Fails to distribute my app: "Your app contains non-public API usage."

After I fixed some bugs and refactored my project which has been release on App Store, it fails to distribute. The Xcode shows the following error message:
Your app contains non-public API usage. Please review the errors, correct them, and resubmit your application.
The app references non-public symbols in Payload/XXX.app/XXX: UICreateCGImageFromIOSurface
XXX is the app name.
I've search the entire project, and didn't find any this keyword (UICreateCGImageFromIOSurface). How can I fix this?
Remove Reveal.framework from your project. This should not be linked in release mode of your binary.
You app contains code not only from sources, but from all statically linked libraries. You have to check all of those for containing private call. Looks like at least Reveal library contains it.
Double check any third-party libraries you are using in your project
I was facing the issue and after checking my pods file, I found that Look Back - Framwork which is available for debug builds only as for as I know. So removing that fixed the issue. Successfully submitted app through Xcode 6.1 for Apple Testflight beta testing :)
Never ship an app linked against the Reveal library. Reveal exposes
your app to deep introspection and will likely cause your app to be
rejected by the Apple review team. Reveal is intended for internal
development and debugging purposes only.
The Reveal service will stop automatically while the iOS host app is
not the frontmost app. It will automatically start again when the app
is re-opened.
Reveal supports inspection of applications compiled against iOS 6 and
later. The iOS Deployment Target build setting must also be 'iOS 6.0'
or later. You may see link errors if this is not the case.
Reveal uses Bonjour to connect with the running iOS application. If
you are running the iOS application on a device, it will need to be
on the same network as the Reveal Mac app to be able to connect with
it. If you have any problems connecting to your application check
your firewall and proxy setting to ensure they are not blocking
communications.
Find out more...
cordova plugin rm cordova-plugin-ionic-webview
cordova plugin add cordova-plugin-ionic-webview#4.1.0

XE4 Deployment error

Good afternoon all. Apologies if SO isn't the place to ask, I wasn't sure there was an 'errors stack exchange' or such, and whether or not any XE4 users would be visitors there.
I'm currently trying out the XE4 trial, and I'm wanting to see just whether the iOS implementation is as easy as they made it look.
I've got my remote profile all setup and working, and I've made a small application that only contains a progress bar. Now, when I deploy that application to the simulator, it runs on the iOS simulator as expected.
However, when I try to deploy to a device, I get the following error;
[DCC Error] E2597 ld: warning: directory not found for option '-FC:\Users\Scott\Documents\RAD Studio\SDKs\iPhoneOS5.0.sdk\System\Library\PrivateFrameworks'
I've tried Debug, Ad-hoc, and App Store profiles, but they all return the same error. The folder 'PrivateFrameworks' doesn't even exist. There's one called 'Frameworks' in the 'Library' folder, but nothing else. I considered that maybe it's an incorrect SDK library path, but the only one with such a path is 'UIFoundation'. Changing the path to 'frameworks' like the others are returns this;
[DCC Error] E2597 ld: warning: can't parse __DATA/__objc_imageinfo section in C:\Users\Scott\Documents\RAD Studio\SDKs\iPhoneOS5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
That file DOES exist (99KB) but the error remains (and so I assume that changing the SDK lib path wasn't the right thing to do). It's like it's not even attempting to deploy over to the mac for compilation due to a file or folder issue.
Any ideas?
You could look at the checklist in the Troubleshooting: Cannot Deploy to the iOS Device help topic.
If you have not run your iOS app on the iOS Simulator, make sure you satisfy the requirements here:
Troubleshooting: Cannot Deploy to the iOS Simulator
Make sure your iOS device is connected to your Mac by USB cable.
Specify the iOS Device as the target platform in the Project Manager.
Complete the Provisioning page. (Your developer certificate is required for code signing)
Set the required Project Options for your iOS app:
Specify your application icons - Application Options.
Specify info.plist keys such as UIDeviceFamily - Version Info.
Install the Xcode command-line tools on your Mac. (Required for code signing your iOS app)
There are links in the documentation above with details about some of the steps involved.
I had extactly the same issue. It happened when trtying to deploy to the iOS 5.0 simulator (not even an iOS device).
It appears that UIFoundations (PrivateFrameworks) gets pulled across and cached when you setup the SDK for iOS 6.1 on XE4.
Make sure the sumulators are installed on Xcode in preferences. Restart Xcode (make sure the PA server is running). Setup a connection profile with the 6.1 SDK in options on XE4 and it works.
Hope this makes sense but it solved my issue.
Add the missing framework into your SDK. Tools->Options->SDK Manager, go to Frameworks and click the yellow button. Also remember to press "Update Local File Cache" after you're done. You will find that you will need to fetch more Frameworks and Libraries in the future.

IOS MDM Server IOS App OTA Deployment

We've built an MDM server using a mac mini.
We have 2 applications to push out to a number of users. One app will push and download on the remote devices with out a problem. The other displays an error "The app could not be installed at this time"
This second application is an older application.. however we are building it for 6.0. In the console we see this.
ipad SpringBoard[65] <Warning>: could not save thumbnail for downloading icon: image=(null) path='/var/mobile/Library/SpringBoard/DownloadingIconImageCache/
This app can be built an installed when a device is connected to the build computer. We have all of the signing the same as the first application. We can also archive the app without any errors. What would cause this app to not install, or what should we start with?
Several notes/ideas:
a) Take a look at this (they mention the same problem)
Trouble installing AD-HOC distribution through safari
iOs application crash on install
Ad-hoc distribution fail
http://community.phonegap.com/nitobi/topics/not_installing_my_application_in_ipod
b) Can you please post your manifest (if you are installing inhouse apps)?
Please double check that that if you pointing to icons in this manifest, the links are correct.
Ok this took days to figure this out... In my situation at some point another icon was added into the build settings. We did change the name of the bundle so I'm assuming that xcode automatically populates the icon information?
In the info tab check to make sure you only have one property for 'icon files' (to be clear you should have the ability to open the drop down menu and expose sub menus... What I had was 2 'icon file' sections.) After I deleted the second set of icon files it pushed fine.
Hope that helps others figure out a very frustrating situation

Resources