Catch uncaught exceptions and better ownership parsing.