Skip to content

Commit 966ee12

Browse files
authored
Update debugger break on NavigateTo guidance (#34892)
1 parent cd5d280 commit 966ee12

File tree

1 file changed

+9
-6
lines changed
  • aspnetcore/blazor/tutorials/movie-database-app

1 file changed

+9
-6
lines changed

aspnetcore/blazor/tutorials/movie-database-app/part-2.md

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -468,22 +468,25 @@ Add a movie to the database. In the following example, the classic sci-fi movie
468468

469469
When you select the **:::no-loc text="Create":::** button, the movie data is posted to the server and saved in the database.
470470

471-
:::moniker range=">= aspnetcore-9.0"
472-
473-
<!-- UPDATE 10.0 Revert when https://github.com/dotnet/aspnetcore/issues/53996 is addressed -->
471+
:::moniker range=">= aspnetcore-9.0 < aspnetcore-10.0"
474472

475473
:::zone pivot="vs"
476474

477-
A Visual Studio debugger regression breaks with a <xref:Microsoft.AspNetCore.Components.NavigationException> on the line that navigates back to the `Index` page:
475+
In .NET 9, the Visual Studio debugger may break with a <xref:Microsoft.AspNetCore.Components.NavigationException> on the line that navigates back to the `Index` page:
478476

479477
![Debugger regression: A navigation exception is thrown on the NavigateTo call.](~/blazor/tutorials/movie-database-app/part-2/_static/debugger_regression.png)
480478

481-
To resolve this problem until the debugger is updated by a future Visual Studio release:
479+
To resolve this problem:
482480

483481
1. Deselect the checkbox for **Break when this exception type is user-handled**.
484482
2. Select the **Continue** button in the menu bar to continue execution.
485483

486-
The exception won't be thrown when the <xref:Microsoft.AspNetCore.Components.NavigationManager.NavigateTo%2A> method is executed throughout the rest of the tutorial series.
484+
The exception isn't thrown when a <xref:Microsoft.AspNetCore.Components.NavigationManager.NavigateTo%2A> method is executed throughout the rest of the tutorial series.
485+
486+
In .NET 10 or later:
487+
488+
* Updates to the way that <xref:Microsoft.AspNetCore.Components.NavigationManager.NavigateTo%2A> manages navigation never result in a <xref:Microsoft.AspNetCore.Components.NavigationException>.
489+
* The Visual Studio debugger doesn't break when processing <xref:Microsoft.AspNetCore.Components.NavigationManager.NavigateTo%2A> calls with a valid endpoint.
487490

488491
:::zone-end
489492

0 commit comments

Comments
 (0)