Skip to content

Using Unity as a Library does not report crashes/fatals #1727

@Esildor

Description

@Esildor

Environment

How do you use Sentry?
Sentry SaaS

Which version of the SDK?
2.1.0

How did you install the package?
Git-URL

Which version of Unity?
6000.0.4f1

Is this happening in Unity (editor) or on a player like Android, iOS, Windows?
Android

Steps to Reproduce

  1. Download and open the Unity as a Library (UaaL) example.
  2. Install Sentry as a package.
  3. Run the setup wizard to ensure the Sentry plugin is activated.
  4. Ensure that Android Native Support is enabled.
  5. Add this script this script to the project. This will add buttons to simulate various crashes via UnityEngine.Diagnostics.Utils.ForceCrash(). To the top left of the screen.
  6. Continue setting up the UaaL project per the instructions in Unity's Github docs
  7. Build and run on a device
  8. Press any of the ForcedCrashCategory buttons, for example: Engine Crash - FatalError, Engine Crash - AccessViolation, etc.

Expected Result

Unity engine-level crashes/fatal issues are reported to Sentry.

Actual Result

No fatal crash is reported. It's also worth noting: Performing these steps in a non-UaaL project reports fatal level crashes to Sentry as expected, see the image below.

Any logs or screenshots

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    FeatureNew feature or requestUaaL

    Projects

    Status

    In Progress

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions