'System.PlatformNotSupportedException', reason: 'Operation is not supported on this platform. (System.PlatformNotSupportedException)
See original GitHub issuePlease mark the type framework used:
- Other: net6.0-maccatalyst
Please mark the NuGet packages used:
- Sentry
- Sentry.Serilog
- Sentry.Extensions.Logging
- Version: 3.15.0
Seems like Sentry doesn’t yet support net6.0-maccatalyst
target, app crashes on startup with
(I also looked into supplying my own http factory, but property is internal)
Application Specific Information:
*** Terminating app due to uncaught exception 'System.PlatformNotSupportedException', reason: 'Operation is not supported on this platform. (System.PlatformNotSupportedException)
at System.Net.Http.NSUrlSessionHandler.get_SupportsAutomaticDecompression()
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
--- End of stack trace from previous location ---
at System.Net.Http.HttpClientHandler.InvokeNativeHandlerMethod(String name, Object[] parameters)
at System.Net.Http.HttpClientHandler.GetSupportsAutomaticDecompression()
at System.Net.Http.HttpClientHandler.get_SupportsAutomaticDecompression()
at Sentry.Internal.Http.DefaultSentryHttpClientFactory.Create(SentryOptions options) in /_/src/Sentry/Internal/Http/DefaultSentryHttpClientFactory.cs:line 34
at Sentry.Internal.SdkComposer.CreateTransport() in /_/src/Sentry/Internal/SdkComposer.cs:line 37
at Sentry.Internal.SdkComposer.CreateBackgroundWorker() in /_/src/Sentry/Internal/SdkComposer.cs:line 112
at Sentry.SentryClient..ctor(SentryOptions options, IBackgroundWorker worker) in /_/src/Sentry/SentryClient.cs:line 52
at Sentry.SentryClient..ctor(SentryOptions options) in /_/src/Sentry/SentryClient.cs:line 39
at Sentry.Internal.Hub..ctor(SentryOptions options, ISentryClient client, ISessionManager sessionManager, ISystemClock clock, IInternalScopeManager scopeManager) in /_/src/Sentry/Internal/Hub.cs:line 51
at Sentry.SentrySdk.InitHub(SentryOptions options) in /_/src/Sentry/SentrySdk.cs:line 53
at Sentry.SentrySdk.Init(SentryOptions options) in /_/src/Sentry/SentrySdk.cs:line 97
at Serilog.SentrySinkExtensions.Sentry(LoggerSinkConfiguration loggerConfiguration, Action`1 configureOptions) in /_/src/Sentry.Serilog/SentrySinkExtensions.cs:line 341
Issue Analytics
- State:
- Created a year ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
System.PlatformNotSupportedException: 'Operation is not ...
System.PlatformNotSupportedException: 'Operation is not supported on this platform.' when upgrading ServiceStack to .netcore 2.0.
Read more >System.PlatformNotSupportedException: Operation is not ...
Looks a bit like you got the library for the wrong platform. You need to make sure you build for linux to run...
Read more >System.PlatformNotSupportedException:“Operation is not ...
The reason the compilation APIs are not supported is because the compilers (e.g. CS compiler) doesn't ship as part of the .NET runtime....
Read more >*System.PlatformNotSupportedException:** 'Operation is ...
Hello Guys , So i tried to run this game in xamarin forms , but when i try compile : System.Drawing.Bitmap mybitmap =...
Read more >Security - PlatformNotSupportedException (Operation is ...
Security - PlatformNotSupportedException (Operation is not supported on this platform) is thrown on an attempt to run a Xamarin app (E4908) on ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@anpin thanks so much for the help. i have raised an upstream issue here https://github.com/dotnet/runtime/issues/67529
on potential workaround would be to catch PlatformNotSupportedException and assume SupportsAutomaticDecompression is false. @mattjohnsonpint thoughts?
@SimonCropp - the workaround sounds fine to me. I made a PR with that.