sentry-cocoa icon indicating copy to clipboard operation
sentry-cocoa copied to clipboard

SDK version is not displayed in dashboard

Open tustanivsky opened this issue 3 years ago • 2 comments

Description

In sentry-unreal (Sentry plugin for Unreal Engine) we're using sentry-cocoa internally for crash capturing on iOS. After updating it to version 7.22.0 I've noticed that the SDK version is not displayed in dashboard anymore.

A similar issue was confirmed for sentry-unity as well.

unknown .

tustanivsky avatar Jul 27 '22 16:07 tustanivsky

Hello @tustanivsky, thanks for the input, we will investigate this.

brustolin avatar Jul 28 '22 08:07 brustolin

@bitsandfoxes Can you help us out here. We dont have this problem happening with cocoa projects. Maybe something related to the binding for Unity?

brustolin avatar Aug 10 '22 13:08 brustolin

Unity is on Cocoa v7.23.0 right now and does not have this issue. Events reported through the Cocoa SDK show up as sentry.cocoa.unity.

bitsandfoxes avatar Aug 16 '22 10:08 bitsandfoxes

@tustanivsky, can you check the comment above and let us know if you still experience the issue?

philipphofmann avatar Aug 31 '22 06:08 philipphofmann

@tustanivsky, can you check the comment above and let us know if you still experience the issue?

@philipphofmann Yes, Unreal plugin is on Cocoa v7.23.0 as well and this issue still persists (check it out here). As you can see package name is sentry.cocoa.unreal which is correct, though the version is not displayed

tustanivsky avatar Aug 31 '22 07:08 tustanivsky

I stand corrected: It's made its way into the Unity SDK as well: https://github.com/getsentry/sentry-unity/issues/950

bitsandfoxes avatar Sep 01 '22 08:09 bitsandfoxes

Ah, now I think I get it. If you pass down the SDK name sentry.cocoa.unreal or sentry.cocoa.unity the cocoa SDK doesn't send the version properly, @tustanivsky?

philipphofmann avatar Sep 01 '22 12:09 philipphofmann

Ah, now I think I get it. If you pass down the SDK name sentry.cocoa.unreal or sentry.cocoa.unity the cocoa SDK doesn't send the version properly, @tustanivsky?

Yes, correct

tustanivsky avatar Sep 01 '22 12:09 tustanivsky

This has been caused by #1960 - we need to adapt the Unity & Unreal SDKs to fix that.

The issue with the empty version string is caused by this line https://github.com/getsentry/sentry-cocoa/blob/master/Sources/Sentry/SentryOptions.m#L336

Previously if the given version was empty, it was be ignored.

https://github.com/getsentry/sentry-cocoa/blob/master/Sources/Sentry/SentrySdkInfo.m#L51

Now it just writes whatever is given (nullptr)

vaind avatar Sep 05 '22 13:09 vaind

I've updated the respective issues in Unreal & Unity with the info that we need to use PrivateSentrySDKOnly.

What is missing with the current code, however, is the option to set only a name or a version, not both. Can someone make the changes to PrivateSentrySDKOnly to expose that? Ideally also a getter for both name & version because it's also used by the Dart SDK to add info to the events coming from Dart - reading the now deprecated options.sdkVersion

vaind avatar Sep 05 '22 13:09 vaind

Yep, we can change that easily. How important / urgent is that for you, @vaind?

philipphofmann avatar Sep 06 '22 16:09 philipphofmann