sentry-unity
sentry-unity copied to clipboard
Debug builds: Different `environment` and opt-out for event capture in Editor config
Users are using Debug.isDebugBuild to conditionally initialize the SDK and to change the environment.
The SDK should, by default, report environment=debug when Debug.isDebugBuild is true.
Sentry editor window should have a checkbox to opt-out from capturing events in Debug builds.
Customers also mentioned it's not possible today to set the environment at build time in a way that affects not only the C# events and also the native events. Docs also lack any indication on how to deal with this.
SENTRY_ENVIRONMENT should be picked up at build time and affect not only the C# layer but the native too.
Docs should mention that. This was mainly built for runtime (when init the SDK checks). So it's important to point out in Unity this is a build-time thing too