Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refreshing a page (F5) Fails to load when using URL with Guid & double data type #47149

Closed
1 task done
nssidhu opened this issue Mar 11, 2023 · 1 comment
Closed
1 task done
Labels
area-blazor Includes: Blazor, Razor Components ✔️ Resolution: Answered Resolved because the question asked by the original author has been answered. Status: Resolved

Comments

@nssidhu
Copy link

nssidhu commented Mar 11, 2023

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

I am using Blazor Server (.net 7)
When I have URL with Parameter of datatype guid or double, the page Refresh using F5 fails to reload the page.
The internal navigation from the Code works fine, but fails for the following conditions

  1. When refreshing page (F5)
  2. Typing the for URL in the new window also results into same error as in Initial checkin of some samples and a readme #1

Expected Behavior

It should reload the Page without any error in both scenario

Steps To Reproduce

Link to Repo.
https://github.com/nssidhu/BlazorAppGuidInURL

Try navigating to the page using left menu for counter
It will successfully navigate,
Now Reload the Page using F5 or browser's reload button

Also look at the .gif to see the scenarios where it fails

Exceptions (if any)

image

2023-03-10_22-12-47

.NET Version

.net 7

Anything else?

No response

@dotnet-issue-labeler dotnet-issue-labeler bot added area-blazor Includes: Blazor, Razor Components untriaged labels Mar 11, 2023
@MackinnonBuck
Copy link
Member

Thanks for reaching out. It looks like the URL is being identified as potentially having a file extension in the name, which causes it to not match the desired route. You can fix this by using app.MapFallbackToPage("{**path}", "/_Host").

@MackinnonBuck MackinnonBuck closed this as not planned Won't fix, can't repro, duplicate, stale Mar 13, 2023
@MackinnonBuck MackinnonBuck added the ✔️ Resolution: Answered Resolved because the question asked by the original author has been answered. label Mar 13, 2023
@ghost ghost added the Status: Resolved label Mar 13, 2023
@ghost ghost locked as resolved and limited conversation to collaborators Apr 12, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-blazor Includes: Blazor, Razor Components ✔️ Resolution: Answered Resolved because the question asked by the original author has been answered. Status: Resolved
Projects
None yet
Development

No branches or pull requests

3 participants