Restore re-execution middleware in templates.#63005
Merged
ilonatommy merged 6 commits intodotnet:mainfrom Aug 6, 2025
Merged
Conversation
javiercn
reviewed
Aug 6, 2025
javiercn
approved these changes
Aug 6, 2025
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR restores the status code pages re-execution middleware setup in Blazor Web templates that was previously disabled due to a parameter name change issue. The middleware configuration uses the new parameter name createScopeForStatusCodePages to ensure proper scope creation for status code handling.
Key changes:
- Restores
UseStatusCodePagesWithReExecutemiddleware configuration in Blazor templates - Temporarily disables a failing CI job that was using old parameter names
- Updates both main Program.cs files to include the middleware with the correct parameter syntax
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWebCSharp.1/Program.cs |
Adds status code pages middleware with re-execution to "/not-found" path |
src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWebCSharp.1/Program.Main.cs |
Adds the same middleware configuration in the main program variant |
.azure/pipelines/ci-public.yml |
Temporarily disables a CI job that fails with the old parameter naming |
Closed
2 tasks
This was referenced Aug 6, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
After offline discussion with @javiercn, the decision about temporary disabling the job that is using the old version of packages was made. Detailed issue description: #62851.
This PR:
The best overload for 'UseStatusCodePagesWithReExecute' does not have a parameter named 'createScopeForStatusCodePages').