Skip to content

Hot reloading a change in Blazor WebAssembly app after hitting a breakpoint causes browser to crash #75492

@danroth27

Description

@danroth27

Description

When I hot reload a change to the IncrementCount method in a default Blazor WebAssembly app after hitting a breakpoint and then continuing execution, sometimes the browser crashes.

Reproduction Steps

  • Create a new Blazor WebAssembly app
  • F5 to debug
  • Set a breakpoint in Counter.IncrementCount()
  • Click the Counter button
  • F5 to continue
  • Add the following line of code to IncrementCount: var a = new int[,] { { 0, 1 }, { 2, 3 } };
  • Hot reload the change
  • If the browser doesn't crash at this point, click the Counter again to trigger the breakpoint
  • F5 to continue
  • Remove the line of code previously added
  • Hot reload the change
  • Repeat the previous steps to hit the breakpoint, continue execution and add the code

Expected behavior

Change is hot reloaded successfully

Actual behavior

Browser crashes

Regression?

Unknown

Known Workarounds

None

Configuration

Version 17.4.0 Preview 2.0 [32909.200.d17.4]
7.0.100-rc.1.22431.12
Microsoft Edge 105.0.1343.33 (Official build) (64-bit)
Windows 11

C:\test> dotnet --info
.NET SDK:
 Version:   7.0.100-rc.1.22431.12
 Commit:    f1cf61e1c0

Runtime Environment:
 OS Name:     Windows
 OS Version:  10.0.22000
 OS Platform: Windows
 RID:         win10-x64
 Base Path:   C:\Program Files\dotnet\sdk\7.0.100-rc.1.22431.12\

Host:
  Version:      7.0.0-rc.1.22426.10
  Architecture: x64
  Commit:       06aceb7015

.NET SDKs installed:
  6.0.303 [C:\Program Files\dotnet\sdk]
  6.0.400 [C:\Program Files\dotnet\sdk]
  6.0.401 [C:\Program Files\dotnet\sdk]
  7.0.100-rc.1.22431.12 [C:\Program Files\dotnet\sdk]

.NET runtimes installed:
  Microsoft.AspNetCore.App 6.0.8 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 6.0.9 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 7.0.0-rc.1.22427.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 6.0.8 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 6.0.9 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 7.0.0-rc.1.22426.10 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.WindowsDesktop.App 6.0.8 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 6.0.9 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 7.0.0-rc.1.22427.1 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]

Other architectures found:
  x86   [C:\Program Files (x86)\dotnet]
    registered at [HKLM\SOFTWARE\dotnet\Setup\InstalledVersions\x86\InstallLocation]

Environment variables:
  Not set

global.json file:
  Not found

Other information

No response

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions