dotnet / aspnetcore

ASP.NET Core is a cross-platform .NET framework for building modern cloud-based web applications on Windows, Mac, or Linux.
https://asp.net
MIT License
35.21k stars 9.95k forks source link

TypeError: Failed to fetch in Blazor .net 8.0 with InteractiveAuto #51857

Closed vsfeedback closed 10 months ago

vsfeedback commented 10 months ago

This issue has been moved from a ticket on Developer Community.


I am getting the below error when i am trying to fetch the data from Api in blazor .net8. It works when blazor is rendering at server side but when it tries to render at the client side and api calls, it throws the below exception. Please provide some help here.

    at System.Net.Http.BrowserHttpInterop.<CancelationHelper>d__13`1[[System.Runtime.InteropServices.JavaScript.JSObject, System.Runtime.InteropServices.JavaScript, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a]].MoveNext()
    at Object.S [as fetch_like] (https://localhost:7152/_framework/dotnet.js:3:4466)
    at https://localhost:7152/_framework/dotnet.runtime.8.0.0-rc.2.23479.6.7oq2qdxqkf.js:3:49432
    at Gr (https://localhost:7152/_framework/dotnet.runtime.8.0.0-rc.2.234…lhost:7152/_framework/dotnet.runtime.8.0.0-rc.2.23479.6.7oq2qdxqkf.js:3:49402)
    at https://localhost:7152/_framework/dotnet.runtime.8.0.0-rc.2.23479.6.7oq2qdxqkf.js:3:177753
    at Ul (https://localhost:7152/_framework/dotnet.runtime.8.0.0-rc.2.23479.6.7oq2qdxqkf.js:3:178587)
    at wasm://wasm/00b1e352:wasm-function[350]:0x1faee
    at wasm://wasm/00b1e352:wasm-function[246]:0x1bf8b
    at wasm://wasm/00b1e352:wasm-function[239]:0xf172
    at wasm://wasm/00b1e352:wasm-function[307]:0x1e7e4'

Original Comments

Feedback Bot on 10/31/2023, 09:33 PM:

(private comment, text removed)


Original Solutions

(no solutions)

ghost commented 10 months ago

Thank you for filing this issue. In order for us to investigate this issue, please provide a minimal repro project that illustrates the problem without unnecessary code. Please share with us in a public GitHub repo because we cannot open ZIP attachments, and don't include any confidential content.

ghost commented 10 months ago

This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment. If it is closed, feel free to comment when you are able to provide the additional information and we will re-investigate.

See our Issue Management Policies for more information.