4

I've recently encountered quite a weird problem with my Blazor WebAssembly application in which I've used the Authorization package. Now I'm not quite sure what it is but something that authentication is doing causes the Debug proxy to crash and the browser window just closes. The only output lines I could get, which I guess have something to do with it is:

Exception thrown: 'System.Net.Sockets.SocketException' in Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.dll Exception thrown: 'System.Net.Sockets.SocketException' in System.Private.CoreLib.dll Exception thrown: 'Microsoft.AspNetCore.Connections.ConnectionResetException' in System.Private.CoreLib.dll Exception thrown: 'Microsoft.AspNetCore.Connections.ConnectionResetException' in System.Private.CoreLib.dll

I've found this GitHub issue which I think has to do something with this but I couldn't get any further solutions there...

I've tried it with different browsers to but the new Microsoft Edge as well as Chrome closes completly.

Anyone an idea why this happens?

TheAnachronism
  • 175
  • 1
  • 13

2 Answers2

2

Ok so something that has caused the debug browser NOT to crash is: Not using the password autocomplete for the login page. If I enter the password manually the browser doesn't crash on successful login. I have no idea how or why this works but it seems it does in some weird way.

If anyone has an idea or so please post it so I can mark it as the actual answer to this problem. This here is more of a weird workaround.

TheAnachronism
  • 175
  • 1
  • 13
  • Are you sure that this is the case or just a fluke. I found your question because I have just started experiencing the same thing, but the retyping password doesn't do anything different. I am investigating and will come back if I find anything. Its weird as it was fine on Friday and I (am pretty certain I) haven't changed anything... ?? – Brett JB Sep 01 '20 at 14:11
  • Ever since I've discovered that issue and started manually typing the password I haven't encountered that weird crash again. So I kinda guess it somehow is a workaround. Sorry but I haven't found anything else yet. – TheAnachronism Sep 02 '20 at 15:03
  • 1
    I see what you mean. I have upgraded my Visual Studio to 16.7.2 and the problem has gone away!.. For now :-S Cheers – Brett JB Sep 04 '20 at 10:27
  • 1
    Ok, so I have now saved password on my Chrome browser, logged in and it failed again. Deleted the save password and it works. So you can mark your answer as a solution/workaround I would say. I guess not many others experiencing this. I think it needs reporting to Github. Rgds Brett – Brett JB Sep 04 '20 at 12:23
  • The question is now, where to report it? Sorry but I've never reported something like this^^ – TheAnachronism Sep 05 '20 at 11:13
  • 1
    I had the same problem. Deleting the username/password combination from the autocomplete solved the problem. This was problem only when the project was run in debug mode. – Dejan Mauer Sep 12 '20 at 18:10
  • 1
    Not sure if this is the issue logged by @BrettJB but we are also seeing this behaviour and there is an open GitHub issue at https://github.com/dotnet/runtime/issues/41969 – Richard Hauer Sep 15 '20 at 08:23
  • My blazor webassamby also crash on leaving page with passwords inputs.It happening only if dev tools ls is open in chrome. If I run app in regular browser leaving page with password input woks ok – adopilot Sep 24 '20 at 17:27
1

Hold the Bus Originally I wrote: Ok, I think this is a 'bleeding edge' issue. If you change the server from IIS to 'your app' in the dropdown next to the green 'Debug Start' button, the the server will run standalone and hopefully circumvent some of the issues currently experienced by IIS. Its not a strict 'answer' but should hopefully be a solution... worked for me anyway.

I need to modify that answer and will leave these edits till we figure it out... I just added back some new code that I had removed, thinking they were possibly breaking changes, and it has failed again. I don't understand why since all I have put in is a static BLL Helper class and a controller for helping setup. All very so so. I have removed them again and it still doesn't work. There is a strange issue here. I'll come back when I know more. If you find anything, please post a comment.

Cheers

Brett JB
  • 687
  • 7
  • 24
  • 1
    Interesting! Good find! I switch from IIS Express to "MyApp.Server" and everything is back to working fine. Thanks! – Klom Dark Sep 29 '20 at 03:16