-
-
Notifications
You must be signed in to change notification settings - Fork 58
feat: Add OptionConfiguration to replace Runtime/BuildTime
#1888
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
Conversation
|
samples/unity-of-bugs/Assets/Scripts/SentryOptionConfiguration.cs
Outdated
Show resolved
Hide resolved
83d68eb to
3c7e7b1
Compare
vaind
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Runtime/BuildTime config got deprecated but will still be called last as keep backwards compatibility. I've updated the config window with a warning label.
What do you think about only showing the new option on the UI by default and only show the original options (i.e. as in the screenshot), when any of the original options are actually set in the existing config?
| options.SampleRate = 1.0f; | ||
| // Here you can programmatically modify the Sentry option properties used for the SDK's initialization | ||
|
|
||
| #if UNITY_ANDROID || UNITY_IOS |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be simpler but we would lose on the ability to catch native exceptions happening at startup. Is that worth it?
After giving it a try I think that's fair. I've updated the window logic. |
Co-authored-by: Bruno Garcia <bruno@brunogarcia.com>
…ntry-unity into feat/options-config
Co-authored-by: Bruno Garcia <bruno@brunogarcia.com>

Fixes #1621
Based on the issue description: The aim is to have users no longer need to know or care about
RuntimeandBuildTimedifferences. They write their code in once place, we use the same options at any time.Platform specifics can be controlled via the Unity precompile directives. We include a sample of those with the generated template:
The Runtime/BuildTime config got deprecated but will still be called last as keep backwards compatibility. I've updated the config window with a warning label that shows as long as there are either Runtime or BuildTime configs.
