25
votes

I'm developing an iPhone app and doing ad-hoc distribution for beta testing. My users are sending me crash logs that say this:

Identifier:      MyAppName
Version:         ??? (???)
Code Type:       ARM (Native)

I can't understand how to replace those question marks with a real version number. I've configured my Info.plist to include a CFBundleVersion and a CFBundleShortVersionString, but that didn't help... crash logs still just contain question marks instead of the version number I expect.

How do I set my version so it will show up in crash logs?

EDIT Apparently, due to a possible bug in the iPhone CrashReporter, there's no way to set the "Version" properly. But is there a workaround? Some other way to insert a version number (e.g. a build number or SCM revision number) in the crash log metadata?

3
Hey Dan - it sounds like you're doing everything right. The value in your Info.plist should be the only version number I think... Maybe this is a bug?Ben Gotow
all of the crash logs I see on my phone, from several release applications, all have Version: ??? (???), so I think this just is how it is.David Maymudes

3 Answers

28
votes

The easiest method is to save the UDIDs of all the binaries you distribute, and compare them to the UDIDs in the crash dumps. UDIDs are different for each build you make.

To retrieve the UDID:

$ dwarfdump -u /path/to/MyApp.app/MyApp
UUID: 864F3D54-F165-3356-3292-2C9C48E97C55 (armv6) /path/to/MyApp.app/MyApp

And compare it to the crashlog:

Binary Images:
    0x1000 -    0x5ffff +MyApp armv6  <864F3D54F165335632922C9C48E97C55> /var/mobile/Applications/5FB3933B-348E-42D7-B99F-76DE284D2148/MyApp.app/MyApp
3
votes

This seems to be the case for all iPhone apps, including the ones from Apple. You can look through all of the iPhone application crash logs for your devices in Console:

FILES/~/Library/Logs/CrashReporter/MobileDevice/...

Everything in that list shows up with unknown versions for me, except for MobileSafari, which has slightly different information:

OS Version:          iPhone OS 2.2.1 (5H11)
Date:                2009-02-15 02:19:06 -0600

All other applications, including Apple's Calendar & Mail apps, show up with question marks for their version numbers.

It seems that other developers have noticed the same thing. It is probably a bug in the iPhone's CrashReporter program.

2
votes

For adhoc and beta testing, just change your identifier. MyAppNameV1.0b36 instead of MyAppName Obviously this won't work for your App Store version, but it will get you through beta testing.

Note that this probably requires a wildcard ad hoc profile, but these can be easily made through the developer portal.