Route constraints invoked for paths which do not use the route constraint #57572
Labels
area-routing
✔️ Resolution: Answered
Resolved because the question asked by the original author has been answered.
question
Status: Resolved
Is there an existing issue for this?
Describe the bug
Using a {parameter} in one route and a {*catchall} in another route causes a RouteHandlers to be invoked unrelated requests
Example:
the
my_route_constraint
will be invoked with "tiles" as the routeKey value ofpartner
even though the path is not using that constraint, and is more specific (starts with /tiles/) for certain requestsexample:
Expected Behavior
If you specify a prefixed route, it should not hit a route constraint?
Steps To Reproduce
Here is a repo that reproduces the issue:
https://github.com/onionhammer/repro-routing-issue/blob/master/Program.cs
Reference test.http for example requests
Exceptions (if any)
No response
.NET Version
8.0.401
Anything else?
No response
The text was updated successfully, but these errors were encountered: