-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
Route not found with UTF-8 parameter name #41909
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
Comments
I don't think UTF-8 parameter names were ever officially supported. If it worked in Symfony 2, it might be due to implementation details that were not doing anything incompatible with them. But the advanced usage of regex introduced in the url matcher rewrite might have changed that. |
We could make it officially supported as a new feature, with proper test cases. |
Well, I'll try to create a PR for this at the end of week :) |
Any news @TeLiXj ? |
Not for now @OskarStark, I'm very busy this days |
Sure, but should we? I know PHP supports all kinds of weird variables. Like $☃️... https://3v4l.org/5YOfc But I am not sure all kinds of characters has to be supported. I would rather document that only |
…rekas) This PR was merged into the 6.1 branch. Discussion ---------- [Routing] Allow using UTF-8 parameter names | Q | A | ------------- | --- | Branch? | 6.1 | Bug fix? | no | New feature? | yes | Deprecations? | no | Tickets | Fix #41909 | License | MIT | Doc PR | - Commits ------- dfd852d [Routing] Allow using UTF-8 parameter names
Uh oh!
There was an error while loading. Please reload this page.
Symfony version(s) affected: 5.3.2 (at least)
Description
Routes with an UTF-8 parameter name can't be found.
How to reproduce
In YAML
or attributes
Possible Solution
I don't know, I suppose that is a regression because I remember using this on Symfony 2 many years ago.
Additional context
I have tried with YAML, annotations and attributes and only in the last 5.3 version.
Any route with UTF-8 characters works fine, only fails with UTF-8 parameters name.
The
routing.yaml
haveAnd add
utf8: true
to route options doesn't work eitherThe text was updated successfully, but these errors were encountered: