question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ASP.NET Core 8-p6 Blazor page does not load in new browser window

See original GitHub issue

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

WebAssembly application that is being migrated from .NET7 to .NET8 following instructions:

https://github.com/danroth27/Net8BlazorWebAssembly/blob/main/README.md

When I open a new browser tab and navigate to a razor page it sometimes loads, but most of the times, the request is “pending” in the network tab of the browser. I do see a few System.IO.IOExceptions exceptions:

System.IO.IOException: 'Unable to read data from the transport connection: The I/O operation has been aborted because of either a thread exit or an application request..'

Inner exception:

SocketException: The I/O operation has been aborted because of either a thread exit or an application request.

This is what the logs say:

info: Microsoft.AspNetCore.Hosting.Diagnostics[1] Request starting HTTP/2 GET https://localhost:5001/posts/pooling-bufferwriter - - - info: Microsoft.AspNetCore.Routing.EndpointMiddleware[0] Executing endpoint ‘/posts/{postname} (/posts/{postname})’

I see the InitailzieAsync and OnParametersSetAsync invoked. When I navigate to the same page from the “home page”, it loads correctly.

Expected Behavior

Page would load even when navigating to it from a new tab.

Steps To Reproduce

No response

Exceptions (if any)

I see some IO exceptions.

.NET Version

8.0.100-preview.6.23330.14

Anything else?

Microsoft.AspNetCore.App 8.0.0-preview.6.23329.11 Browser: Edge

Issue Analytics

  • State:closed
  • Created 2 months ago
  • Comments:18 (18 by maintainers)

github_iconTop GitHub Comments

1reaction
halter73commented, Aug 17, 2023

Try the latest 8.0-rc1 sdk from here. Try not to mix the 9.0 SDK with 8.0 packages, but they shouldn’t have diverged too much yet.

The cycle issue appears to be a problem with the application code and we did not expect that to be fixed by updating. Are you passing any parameters with a Parent property to a component?

1reaction
ladeakcommented, Aug 16, 2023

Hi @danroth27 ,

I will give it a go later this week, still on holidays with limited connectivity.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Opening new browser window with Blazor application
I have a problem opening a new window with the Blazor application and "post" parameters. Of course, the problem will probably also apply...
Read more >
Blazor Open a page in a new Browser tab using navigation ...
Could please advise me the way of open a page in new tab using Navigation manager and how to show pdf file in...
Read more >
Big Changes Coming for Blazor in .NET 8
NET 8 is shaping up to be a significant release for Blazor, ... the browser will display the initial page, then load Blazor...
Read more >
How to Build and Secure Web Applications with Blazor
Learn how to build client-side Web apps using Blazor and how to secure them with Auth0 authentication and authorization features.
Read more >
Blazor - .NET in the browser
Abstract: Blazor leverages a number of technologies in smart ways in order to provide a SPA framework that can run .NET code in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found