Use spotlight without supplying a DSN
Problem Statement
I want to be able to use spotlight without having to add a DSN.
Solution Brainstorm
Don't throw when spotlight is enabled, but no DSN is configured.
I have no clue whether this is an intended use case, but it would be nice if it's possible.
Are you willing to submit a PR?
Yes
### 🛑 Blocked by
- [ ] https://github.com/getsentry/sentry-cocoa/issues/4620
- [ ] https://github.com/getsentry/sentry-java/issues/3981
Yeah sounds good, afaik other sdks do it as well
e.g https://github.com/getsentry/sentry-ruby/issues/2226 and same feature request on .net https://github.com/getsentry/sentry-dotnet/issues/3481
From the Dart SDK perspective it's pretty much just a change in the init assertion, would there be more needed on the native SDKs to make it possible?
would there be more needed on the native SDKs to make it possible?
probably the same, I don't think the native sdks currently allow using spotlight without dsn as well.
Blocked by https://github.com/getsentry/sentry-dart/issues/2282 <- I want this issue done first
would there be more needed on the native SDKs to make it possible?
probably the same, I don't think the native sdks currently allow using spotlight without dsn as well.
@buenaflor It looks like the Android SDK needs a dsn: sentry.java
if (!options.isEnabled() || (dsn != null && dsn.isEmpty())) {
close();
return false;
} else if (dsn == null) {
throw new IllegalArgumentException(
"DSN is required. Use empty string or set enabled to false in SentryOptions to disable SDK.");
}
@buenaflor I think this is unblocked as #2282 has been fixed with https://github.com/getsentry/sentry-dart/pull/2285
@kahest this is not fully unblocked yet because the cocoa and android sdk doesn't support this feature yet (we use the native sdk spotlight option there)
I'll open an issue for that in the cocoa and android repo