iOS Question Apple rejects my App

db0070

Active Member
Licensed User
Longtime User
I unistalled the debug app, then I tested it on my device (using hosted server) in release mode (using Ad Hoc provisional files). Then I turned my device in Airplane mode. My app did not crash - so I do not know why Apple is saying the App crashes. How do I find out what or where the crash is when I can't make it crash on my device? In the crash report they gave me 6 text files, and in all of them this is included in the reports: -

Thread 0 name: Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x0000000181c4c2e8 0x181c2a000 + 140008
1 libsystem_pthread.dylib 0x0000000181d612f8 0x181d5e000 + 13048
2 libsystem_c.dylib 0x0000000181bbafbc 0x181b58000 + 405436
3 libc++abi.dylib 0x0000000181357068 0x181355000 + 8296
4 libc++abi.dylib 0x0000000181357210 0x181355000 + 8720
5 libobjc.A.dylib 0x0000000181380810 0x181378000 + 34832
6 libc++abi.dylib 0x000000018136f54c 0x181355000 + 107852
7 libc++abi.dylib 0x000000018136f5b8 0x181355000 + 107960
8 libdispatch.dylib 0x0000000181ab6a28 0x181ab5000 + 6696
9 libdispatch.dylib 0x0000000181abe200 0x181ab5000 + 37376
10 FrontBoardServices 0x000000018482e7f8 0x1847ee000 + 264184
11 FrontBoardServices 0x000000018482e49c 0x1847ee000 + 263324
12 FrontBoardServices 0x000000018482ea38 0x1847ee000 + 264760
13 CoreFoundation 0x00000001820df77c 0x181ff4000 + 964476
14 CoreFoundation 0x00000001820df6fc 0x181ff4000 + 964348
15 CoreFoundation 0x00000001820def84 0x181ff4000 + 962436
16 CoreFoundation 0x00000001820dcb5c 0x181ff4000 + 953180
17 CoreFoundation 0x0000000181ffcc58 0x181ff4000 + 35928
18 GraphicsServices 0x0000000183ea8f84 0x183e9e000 + 44932
19 UIKit 0x000000018b7555c4 0x18b6e2000 + 472516
20 Salat Calculator 0x0000000100e87f40 0x100e80000 + 32576
21 libdyld.dylib 0x0000000181b1c56c 0x181b1b000 + 5484
 

db0070

Active Member
Licensed User
Longtime User
My appeal has been rejected with the following remarks, and since I cannot make my app crash, I am now at a loss on how to proceed further:

The App Review Board evaluated your app and determined that the original rejection feedback is valid. Your app does not comply with App Store Review Guideline 2.1.

If you are unable to reproduce this issue, or require further technical help, you may want to contact Developer Technical Support, who can provide discrete code-level assistance.

When trying to reproduce the issue, please ensure you are running your app on a device with the most up-to-date version of iOS. Note that apps are reviewed in a production environment, not on a simulator.

For other questions or to provide additional information about your app, please respond in Resolution Center in iTunes Connect, where a reviewer who is familiar with your app can assist you.

We hope you will consider making the necessary changes to be in compliance with the App Store Review Guidelines and will resubmit your revised binary.

Best regards,
 
Upvote 0

db0070

Active Member
Licensed User
Longtime User
I removed GPS and resubmitted the app, and I got the following rejection. I enclosed the crash logs. Any help will be grateful:-

Guideline 2.1 - Performance - App Completeness


We were unable to review your app as it crashed on launch. We have attached detailed crash logs to help troubleshoot this issue.

During review, your app crashed on iPad Air 2 running iOS 11.2.5.

Next Steps

To resolve this issue, please revise your app and test it on a device to ensure it will launch without crashing.
 

Attachments

  • noGPSCrashLogs.zip
    88.1 KB · Views: 289
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
This means that the problem is not in related to the location permissions.

Searching google for

"Application Specific Information: abort() called"

Suggests that it might be a certificate issue. Worth revoking the current store certificate and creating a new one certificate and provision profile. This might explain why it only crashes in the review.
 
Upvote 0

db0070

Active Member
Licensed User
Longtime User
I re-created the certificates and provisioning profile - just got rejected again. I updated another app that uses the same csr file, and that went through ok. Can I confirm that the hosted server option uses Xcode version 9?
I came across this bit here, I wonder if it has anything to do with rejection, as the app that is rejected uses dates, while the one that just went through does not:
(this is found in this link https://stackoverflow.com/questions/43580282/crash-application-on-appstore-and-some-device)

"actually i have issue with date formater which i use in didLunch i am use @"dd-MMM-yyyy, hh:mm a" pattern and i use that date string by split, so when user have 24 hours app is crash and when have 12 hours its running file, after i solved by
NSLocale *locale = [[NSLocale alloc] initWithLocaleIdentifier:mad:"en_US_POSIX"];
[_dateFormatter setLocale:locale];"

If so, how do I implement in B4i?
 
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
Can I confirm that the hosted server option uses Xcode version 9?
Yes. And it is not related as you can still use Xcode 8 as well.

"actually i have issue with date formater which i use in didLunch i am use @"dd-MMM-yyyy, hh:mm a" pattern and i use that date string by split, so when user have 24 hours app is crash and when have 12 hours its running file, after i solved by
NSLocale *locale = [[NSLocale alloc] initWithLocaleIdentifier:mad:"en_US_POSIX"];
[_dateFormatter setLocale:locale];"

If so, how do I implement in B4i?
Interesting...

https://www.b4x.com/android/forum/threads/unparseable-date.77394/#post-490332
 
Upvote 0

db0070

Active Member
Licensed User
Longtime User
Modified so that the Locale is set to US, still rejected - I am going to request Apple for Technical Support. Their TSI suggests that I should "Run Build and Analyze in Xcode" and "Attach and symbolicate any crash logs" neither of which I can do as I using the hosted server. I hope they will still be able to help

The mad thing is, I can't make it crash!!!!
 
Upvote 0

db0070

Active Member
Licensed User
Longtime User
Help! Apple Developer Technical Support (DTS) first said: -
"All of the common causes of this type of problem are published at the following link, which includes the recommended workflow for testing and isolating Release build issues:
TN2431 - App Testing Guide. The problems covered are those which are frequently missed during development and can therefore surface in App Review, customer environments or distribution app testing. "

To which I replied that I have followed the App Testing Guide as far as I can, but do not have the capability to use debug tools on a Mac as I am using B4X hosted service, to which they replied:-

"We’ve determined that your question should be addressed by the support channel for b4x - the third-party resource you are using. DTS supports developers using Apple-authored tools and frameworks only. We are unable to provide support for third-party tools, development environments, tutorials or other resources."

I note in the crash log that they are testing on IOS 11.3 which is in beta, while my devices are running IOS 11.2.6
 

Attachments

  • attachment-4965170703320312788crashlog-78D91FD2-BC44-4C60-B3DC-47DD9C8D9D35.txt
    69.1 KB · Views: 1,708
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
I note in the crash log that they are testing on IOS 11.3 which is in beta, while my devices are running IOS 11.2.6
The previous crash logs came from iOS 11.2.5 so it doesn't look related.

Submit a completely new app with very few features from your full app. Don't publish it. Just see that your certificates are configured correctly.
 
Upvote 0

db0070

Active Member
Licensed User
Longtime User
Success! I think I have found the bug, but I don't know why it crashes or how to solve it. What I did was to comment out the line Button1_Click when the app starts and submitted the app - exactly as the original. And it passed. Button1_Click calculates the timing calculations and puts the times on the front screen. I want the times to be seen when the app is launched, rather then the user to click on a button to show the calculation. After the app is launch, the user presses Button1_Click and apparently, no crash at apple review. Question is why do I need a delay on launch before Button1_Click? And how do I make sure I have the correct delay?
I am only showing the relevant bits of my code below, for brevity:-

B4X:
Private Sub Application_Start (Nav As NavigationController)
    x.LocManager.Initialize("LocManager")
    NavControl = Nav
    App.RegisterUserNotifications(True, True, True) 'request permission for notifications
    App.ApplicationIconBadgeNumber = 0
    If App.LaunchOptions.IsInitialized Then
        Dim ln As Notification = App.LaunchOptions.Get("UIApplicationLaunchOptionsLocalNotificationKey")
        hd.ToastMessageShow("In Application Start",True)
        If ln.IsInitialized Then
            hd.ToastMessageShow("Application was started from a notification: " & ln.AlertBody, True)
        End If
    End If
    ge.Initialize("ge")
    x.ShowX(False)
End Sub

Public Sub ShowX(alarms As Boolean)
    If pg2.IsInitialized = False Then
        pg2.Initialize("pg2")
        pg2.Title = "Title"
        pg2.Initialize("pg2")
        pg2.RootPanel.LoadLayout("s_calc")
    End If
    Main.Page1_Resize(Main.ActivityWidth,Main.ActivityHeight)        
    Main.navControl.ShowPage(pg2)
    LocManager.Initialize("LocManager")
    pnlGPS.Visible = False
    pnlAbout.Visible=True
    StartGPS
    pnlOpt.Visible = False
    btnOptions.Visible = True
    Main.ge.ResolveCoordinate(lat,lng)
    'Button1_Click
'**** Commenting out the above line passes Apple's review ********
    pnlAbout.Visible=False
End Sub

Sub Button1_Click
    pnlRose.Visible =  False
    timesArray.Initialize
    timesArray = XCalc.newCalculation(txtLat.Text,txtLng.Text,dd,timesArray)
    Main.ge.ResolveCoordinate(lat,lng)
 
    timeNow = DateTime.Now
    timeDiff1 = DateTime.DateTimeParse(DateTime.Date(DateTime.Now),timesArray.F)  - timeNow
.
End Sub
 
Upvote 0

Computersmith64

Well-Known Member
Licensed User
Longtime User
Probably in one of these methods:
B4X:
 timesArray = XCalc.newCalculation(txtLat.Text,txtLng.Text,dd,timesArray)
    Main.ge.ResolveCoordinate(lat,lng)
I think Erel is correct. If your calculation is relying on txtLat & txtLng to have values in them, they probably aren't populated immediately after the app starts - because the GPS won't have initialized yet.

- Colin.
 
Upvote 0

db0070

Active Member
Licensed User
Longtime User
Yesterday, finally, my App went through. What I did was to remove Button_Click from Application_Start and put it in Application_Active, and also, for good measure added checks to see if the variables have some meaningful values. I guess why it did not crash on my iPhone 6 or iPad was because Apple is testing on the latest devices that run faster and so reached newCalculation sub first, even though the sub that opens and reads the filemap to initialise the variables is called first.
 
Upvote 0
Top