Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CaptureMessage stacktraces in IL2CPP builds are missing line numbers #1509

Open
bitsandfoxes opened this issue Dec 6, 2023 · 0 comments · May be fixed by #1567
Open

CaptureMessage stacktraces in IL2CPP builds are missing line numbers #1509

bitsandfoxes opened this issue Dec 6, 2023 · 0 comments · May be fixed by #1567
Labels
Feature New feature or request

Comments

@bitsandfoxes
Copy link
Contributor

bitsandfoxes commented Dec 6, 2023

Currently, if you call SentrySdk.CaptureMessage() and you have options.AttachStacktrace = true the event will look like this:
image
The SDK does capture the stacktrace but the line numbers are missing.

This is due to the line numbers relying on the IL2CPP event processor and the processor relies on an exception - which there is none in the case of just capturing a message.

Gotcha here: The messages triggered by the buttons in the UnityOfBugs scene seem to be affected by whatever event invoke magic Unity is doing under the hood so the actual games might be missing. I recommend adding something like this to the BugFarmButtons.cs script for testing purposes.

private void Update()
{
    if (Input.GetKeyDown(KeyCode.Space))
    {
        SentrySdk.CaptureMessage("Capturing Message");
    }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New feature or request
Projects
Status: No status
Development

Successfully merging a pull request may close this issue.

1 participant