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

Profiling: Error out in the editor if added to unsuported platform #3354

Closed
bruno-garcia opened this issue May 7, 2024 · 3 comments · Fixed by #3371
Closed

Profiling: Error out in the editor if added to unsuported platform #3354

bruno-garcia opened this issue May 7, 2024 · 3 comments · Fixed by #3371

Comments

@bruno-garcia
Copy link
Member

Set Up is quite complex:

In some platforms you need Sentry.Profiling in some you don't and others neither are supported
We have series of notes and warnings, and tabs:
image

Ideally we have a compiler error if Sentry.Profiling is added to an unsupported version, so it's clear Sentry.Profiling isn't supported on Android

Customers are copying the snippet and adding both packages without picking on the fine print and having a bad experience during set up.

@bitsandfoxes
Copy link
Contributor

Can we do that with a bit of MSBuild magic? Can we pick up the targeted platform there together with what packages are installed?

@bitsandfoxes
Copy link
Contributor

@jamescrosswell raised a good point: We could put the platform specific options behind guards like we do here

#if __MOBILE__
public partial class SentryOptions
#else

@vaind
Copy link
Collaborator

vaind commented May 15, 2024

Can we do that with a bit of MSBuild magic? Can we pick up the targeted platform there together with what packages are installed?

this should do the trick 🤞 https://github.com/getsentry/sentry-dotnet/pull/3371/files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants