You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Symfony version(s) affected: ^4.4.22, ^5.2.7 and ^5.3.0
Description
Since the commit 2876c we can no longer use URL Env Var Processor functionality to fill router.request_context.base_url in the configuration, because the method Symfony\Component\Routing\RequestContext::fromUri does not accept null.
How to reproduce
To reproduce this we can set an environment variable: ROUTER_REQUEST_CONTEXT_URL with a url like: https://symfony.com with nothing as a path, then set some parameters like:
Make Symfony\Component\Routing\RequestContext::fromUr accepts null.
Error as shown in console
CRITICAL [php] Uncaught Error: Symfony\Component\Routing\RequestContext::fromUri(): Argument #1 ($uri) must be of type
string, null given, called in /home/me/myProject/var/cache/dev/ContainerXfMbE5x/App_KernelDevDebugContainer.php on line
2098
The text was updated successfully, but these errors were encountered:
amouhzi
changed the title
[DependencyInjection] [Routing] BC break key:path:url: doesn't work anymore in configuration since 5.2.7
[DependencyInjection] [Routing] BC break router.request_context.base_url with key:path:url: doesn't work anymore in configuration since 5.2.7
Sep 30, 2021
amouhzi
changed the title
[DependencyInjection] [Routing] BC break router.request_context.base_url with key:path:url: doesn't work anymore in configuration since 5.2.7
[DependencyInjection] [Routing] BC break: router.request_context.base_url with key:path:url: doesn't work anymore in configuration since 5.2.7
Sep 30, 2021
Symfony version(s) affected: ^4.4.22, ^5.2.7 and ^5.3.0
Description
Since the commit 2876c we can no longer use URL Env Var Processor functionality to fill
router.request_context.base_url
in the configuration, because the methodSymfony\Component\Routing\RequestContext::fromUri
does not accept null.How to reproduce
To reproduce this we can set an environment variable: ROUTER_REQUEST_CONTEXT_URL with a url like:
https://symfony.com
with nothing as a path, then set some parameters like:Possible Solution
Two possible solutions:
Error as shown in console
The text was updated successfully, but these errors were encountered: