How to share app in debug mode?

I am testing an app with a small group of people with iPhones, none of whom have xcode or know how to use it. The app is connecting to a server with an expired SSL certificate, and it will be some time before it can be renewed due to workplace obstacles. We would like to start testing now, rather than waiting for the certificate issue to be fixed, but when I put the app into TestFlight it goes into release mode and will not connect to the expired cert.

Is there a way for me to easily share this app in debug mode so that we can start testing now?

Replies

There’s two things here:

  • TestFlight doesn’t require that you submit release builds. It should accept a debug build just fine.

  • There’s no strict correlation between the build configuration and your TLS server trust evaluation. Presumably you have code that tweaks the server trust evaluation based on the build configuration. If so, you could tweak that to make this decision based on other factors.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Then how is the debug build done? To tell you the truth, I didn't even know about the distinction. I had xcode set to debug but when I did the compile and upload and put the app into beta test it will not connect, even when loading it on the same phone. I don't have any exceptions anywhere, it just works in debug but not in release. Even when I do the build/install out of xcode it stops working if I set the build to release mode.

To clarify, I am using MDWamp for communication, which uses the CFNetwork layer. I suppose it's possible that the mdwamp code has exceptions, but I don't have access to change that layer.

Then how is the debug build done?

That depends on how you’re building your product. The standard mechanism is based on build configurations:

  • The project defines a set of build configurations. You can see these in the Info tab of the project editor. By default these are Debug and Release.

  • When you configure a build setting, you can apply that value to a specific build configuration. For example, the standard app templates configure the Active Compilation Conditions (SWIFT_ACTIVE_COMPILATION_CONDITIONS) so that DEBUG is set in the Debug build configuration and not in the Release one.

  • In the scheme editor (Product > Scheme > Edit Scheme) you set the build configuration to use for each action. By default the Run action uses Debug and the Archive action uses Release.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Ohh so you are saying if I change the archive action to use debug then it may work? I will try that, thanks.

  • Hey Malibu, did it work? Were you able to upload a debug mode build to Testflight?

Add a Comment