January 2010
Sun Mon Tue Wed Thu Fri Sat
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31            

September 05, 2005
Smart Crash Reports: Beta 3

Thank you for your comments on Smart Crash Reports! Now, to announce the changes and our current plans on the matter:

I have created beta 2 (and 3) of the product. About the only change users will notice (although an important one) is that Smart Crash Reports will now send crash reports both to the developer and Apple. We think it's not a good idea to make Apple "miss" any of these crash reports, so new beta (likely to become final) fixes this. So now the crash dialog looks like this:

Other changes apply to the SDK:

  • SDK: Made it possible to register narrow match specifiers after the broader ones were registered. This allows the developers to register a generic handler for all products of the company, and some custom handler for a specific product.
  • SDK: Made it possible to pass NULL as inMatchString in the UnsanitySCR_RegisterMatchSpecifier to make it choose the main bundle identifier.


A few notes on the installation. The API will be forthcoming for that, so developers who want to install Smart Crash Reports from within their application, will have to add an additional .a (or .o) file to their project and call a single function UnsanitySCR_InstallIfNeeded(). No additional files or calls would be required - the SCR InputManager will be packed directly into the .a file (this is the same technology we use for APEInstall() in the Application Enhancer SDK). The API will determine whether SCR has to be installed based on its presence on the user machine and its version, and do all the magic for you. Otherwise, if you don't want to install it yourself, there will be a downloadable package at http://www.unsanity.com/smartcrashreports/ that you can point users to.

Anyway, here is a link to the new beta:
http://www.unsanity.net/beta/smartcrashreports-10b3.dmg

Thanks!

UPDATE 09/13: Beta 6 (FC) is out!

 Posted by slava at 01:17 AM | Comments (10) | TrackBack (0)
Related:
Comments

I'm just trying out the Smart Crash Reporter in our application Life Balance right now after reading about it on Ars Technica. I did find one small problem in the header file. There needs to be a double underscore in __cplusplus, not just a single one.

Posted by: Stuart A. Malone on September 5, 2005 6:54 AM

Oops, thanks for pointing that out, Stuart! Fixed in 1.0b3.

Posted by: slava on September 5, 2005 7:00 AM

I'm trying out Beta 3 in my application and UnsanitySCR_RegisterMatchSpecifier() is returning -54, permErr. Where is it trying to write stuff?

Also, I really would prefer to not have anything in /Library/InputManagers/ if possible. It is acceptable to me to have an extra folder in my app's bundle, but not in another folder.

I know how to crash my app :-) so I want this to work! Thanks!

Posted by: Philippe Casgrain on September 7, 2005 8:03 AM

Philippe: it tries to save to /Library/Preferences/.

As for not having it as an input manager, unfortunately, not much we can do about it -- the system expects InputManagers to be in that folder (or ~/Library/InputManagers). Luckily, I've added the installation API in the 1.0b4 (out soon) that will allow you to install SCR in one function call.

Posted by: slava on September 7, 2005 8:08 AM

OK, I changed the permissions on /Library/Preferences and UnsanitySCR_RegisterMatchSpecifier() returns noErr.

May I comment that it should not write there? I do not run as an admin user, so normally I can't access this folder. Shouldn't SCR write to ~/Library/Preferences/ if it can't access /Library/Preferences/?

I installed SCR in ~/Library/InputManagers/.

Also, my app is a CFM app. It will be Mach-O at some point in the future, but not now. So I installed SCR in our "Cocoa" bundle, a plug-in with Mach-O code. UnsanitySCR_RegisterMatchSpecifier() works fine (returns noErr) but when I crash the app, I do not get "Send to MyCompany & Apple", only "Apple". Is it because the crash did not occur in the Mach-O bundle?

Posted by: Philippe Casgrain on September 7, 2005 8:38 AM

Oh, and by the way "BombApp" works: it shows the "Send to Unsanity & Apple" button. What am I missing?

Posted by: Philippe Casgrain on September 7, 2005 8:42 AM

Philippe, for the future, it'll try writing to both locations if the global one fails. This was an oversight on our part and not intentional.

For the Question you had about CFM, just register using the bundle ID of the CFM application (or pass NULL). What does your CFM crash look like?

Posted by: Rosyna on September 7, 2005 8:44 AM

I tried registering with both NULL and "com.MyCompanyName". The plist file looks like this:


Rules


CompanyName
MyCompanyName
MatchString
com.MyCompany
SubmitEmail
SCR-51C189D0CB


CompanyName
MyCompanyName
MatchString
com.MyCompanyName
SubmitEmail
SCR-51C189D0CB


So I think it is registering properly. Here is the top of my crash log:

Date/Time: 2005-09-07 12:02:11.850 -0400
OS Version: 10.4.2 (Build 8C46)
Report Version: 3

Command: MyApp Debug Tests
Path: /Volumes/DevSource/Development/prod/MyApp/Install/MyApp/Contents/MacOS/MyApp Debug Tests
Parent: WindowServer [24996]

Version: 10.0.006 (10.0.006© MyCompany 2005)

PID: 15738
Thread: 0

Exception: EXC_BAD_ACCESS (0x0001)
Codes: KERN_PROTECTION_FAILURE (0x0002) at 0x00000020

Thread 0 Crashed:
0 MyApp Debug Tests 0x0245a8dc pstrcpy__FPUcPCUc + 44 (pluginUtil.cpp:0)
1 MyApp Debug Tests 0x0236707c shape_to_floater__FP5shape + 732 (ShapeRen.cpp:0)
2 MyApp Debug Tests 0x021269e4 convert_to_floater_proc__FP7cruiser + 212 (Floaters.cpp:0)
3 MyApp Debug Tests 0x022adffc commit_to_floater__FP7cruiser + 1244 (PluginFloater.cpp:0)
4 MyApp Debug Tests 0x022ad8c8 commit_to_floater_dialog__FP7cruiser + 824 (PluginFloater.cpp:0)
5 MyApp Debug Tests 0x02304b0c do_rotate_document__Fd + 76 (RotaPict.cpp:0)
6 MyApp Debug Tests 0x0264e23c CMDRotateCanvas90CW__FRC9CMDParams + 60 (MenuCommands.cpp:0)
7 MyApp Debug Tests 0x02173818 execute_command__FQ23std59basic_string,Q23std12allocator>RC9CMDParams + 152 (FuncDisp.cpp:0)
8 MyApp Debug Tests 0x020daf78 do_menu__FlsP11palette_obj + 232 (DoMenu.cpp:0)
9 MyApp Debug Tests 0x025c2730 do_mouse_down__FP11EventRecordb + 288 (MainDisp.cpp:0)
10 MyApp Debug Tests 0x025c3340 Dispatch__14MainDispatcherF11EventRecordP15IdleStateParamsb + 1936 (MainDisp.cpp:0)
11 MyApp Debug Tests 0x0223213c main_loop__Fb + 252 (MyApp.cpp:0)
12 MyApp Debug Tests 0x0222f348 main + 72 (MyApp.cpp:0)

I hope this helps...

Posted by: Philippe Casgrain on September 7, 2005 9:08 AM

Philippe,

In this case, your best bet is to register for "My App Debug Tests". Since CFM crash logs contain no bundle IDs in the threads but only the main CFM fragment name, then Smart Crash Reports would be catching the app name in the crashed thread.

As for the preferences/permissions issues, as Rosyna stated, we will fix this tomorrow in the updated version.

Thanks for testing this out!

Posted by: slava on September 7, 2005 11:47 AM

Slava,

When I register with "My App Debug Tests", crashdump crashes :-) So we're closer to getting it working...

Isn't crashdump part of the Crash Reporter engine?

I have one app bundle but the "MacOS" folder actually contains all my executables: Debug, Release, Debug with Tests, Release with Tests, etc... Maybe that is confusing to the Crash Reporter.

I was able to restore normal Crash Reporter functionality only after I renamed ~/Library/InputManagers/ to ~/Library/InputManagersBackup/

Posted by: Philippe Casgrain on September 7, 2005 12:16 PM
Post a comment
Keep comments on topic. If a comment is unrelated to this post, it may be removed or moderated.





Remember Me?

(you may use HTML tags for style)