title: XPC and Exception handling
body: <p>I have an <em>LaunchAgent</em> using <em>HockeyApp</em> for crash reporting. Now I noticed that uncaught exception where not reported by <em>HockeyApp</em>, like they would have been in a normal macOS app.</p>
  
  <p>For example:</p>
  
  <pre><code>- (void)upperCaseString:(NSString *)aString withReply:(void (^)(NSString *))reply {
      NSArray *array = [NSArray array];
      reply([array objectAtIndex:23]);
  }
  </code></pre>
  
  <p>Never reaches <code>NSUncaughtExceptionHandler</code>, but the console logs:</p>
  
  <pre><code>&lt;NSXPCConnection: 0x7fe97dc0f110&gt; connection from pid 44573: Warning: Exception caught during invocation of received message, dropping incoming message and invalidating the connection.
  </code></pre>
  
  <p>The question is how to get unhandled exception reported with <em>HockeyApp</em>.</p>