-
-
Notifications
You must be signed in to change notification settings - Fork 747
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
[Bug]: MissingMethodException on EnsureSuccessfulAsync on WASM #1918
Comments
We are experiencing a similar issue, while building a request. It does work on some machines but not on the others. Presumably the issue is on Windows10, Windows 11 works ok.
|
Hey, does this issue persist when you downgrade refit versions? To me, a missing method exception suggests that you may have duplicate dlls, although I don't know how this can happen with with |
Refit is not trim-friendly #1389, and it seems like it never will be. When using it in WASM, which trims by default (starting from .NET 7 or 8, I don't remember exactly), you need to either add this library to the exclusion list or disable |
I have created a fully support AOT, no reflection and almost identical to Refit's usage.
|
Describe the bug 🐞
Getting this error on a .NET 8 Blazor Web App, when render mode gets to WASM.
crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
Unhandled exception rendering component: Method not found: System.Threading.Tasks.Task
1<Refit.ApiResponse
1<!0>> Refit.ApiResponse1.EnsureSuccessfulAsync() System.MissingMethodException: Method not found: System.Threading.Tasks.Task
1<Refit.ApiResponse1<!0>> Refit.ApiResponse
1.EnsureSuccessfulAsync()at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[d__14](d__14& stateMachine)
Step to reproduce
Reproduction repository
https://github.com/reactiveui/refit
Expected behavior
Method should be present and request being verified
Screenshots 🖼️
No response
IDE
No response
Operating system
No response
Version
No response
Device
No response
Refit Version
No response
Additional information ℹ️
No response
The text was updated successfully, but these errors were encountered: