We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
No response
In v23.3 we will begin enforcing unique route names. We will need to force routes with multiple hosts to have a unique name with something like this:
diff --git a/sanic/router.py b/sanic/router.py index b68fde3b..b2e0fc69 100644 --- a/sanic/router.py +++ b/sanic/router.py @@ -139,6 +139,9 @@ class Router(BaseRouter): route.extra.static = static route.extra.error_format = error_format + if len(hosts) > 1 and host: + route.name = f"{route.name}__host_{host.replace('.', '_')}" + if error_format: check_error_format(route.extra.error_format)
The text was updated successfully, but these errors were encountered:
Was this added in 23.3?
Sorry, something went wrong.
No branches or pull requests
Is there an existing issue for this?
Is your feature request related to a problem? Please describe.
No response
Describe the solution you'd like
In v23.3 we will begin enforcing unique route names. We will need to force routes with multiple hosts to have a unique name with something like this:
Additional context
No response
The text was updated successfully, but these errors were encountered: