This PR was merged into the 4.4 branch.
Discussion
----------
[Messenger] Fix mssql compatibility for doctrine transport.
Add logic for locking row for update when the doctrine dbal connection is sqlsrv. This is a quick and dirty solution, but it prevents the need to rewrite the logic due to doctrine dbal limitations.
See issue https://github.com/symfony/symfony/issues/39117
| Q | A
| ------------- | ---
| Branch? | 4.4
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets | Fix#39117
| License | MIT
| Doc PR |
Commits
-------
37be094992 [Messenger] Fix mssql compatibility for doctrine transport.
Add logic for locking row for update when the doctrine dbal connection is sqlsrv. This is a quick and dirty solution, but it prevents the need to rewrite the logic due to doctrine dbal limitations.
See issue https://github.com/symfony/symfony/issues/39117
This PR was merged into the 5.2 branch.
Discussion
----------
[DoctrineBridge] Fix form EntityType with filter on UID
| Q | A
| ------------- | ---
| Branch? | 5.2
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets | Fix#39207
| License | MIT
| Doc PR | -
Convert UUID and ULID to the right format in ORMQueryBuilder
/cc @nicolas-grekas
Commits
-------
9e83bb7634 Fix form EntotyType with uid
This PR was merged into the 4.4 branch.
Discussion
----------
[HttpClient] fix binding to network interfaces
| Q | A
| ------------- | ---
| Branch? | 4.4
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets | Fix#38979
| License | MIT
| Doc PR | -
Fixes support for binding to local interfaces by adding support for [curl's `if!` prefix](https://curl.se/libcurl/c/CURLOPT_INTERFACE.html).
Commits
-------
faa1fd32f9 [HttpClient] fix binding to network interfaces
This PR was merged into the 5.1 branch.
Discussion
----------
[FrameworkBundle] [minor] adjust KernelBrowser::getProfile() typehint
| Q | A
| ------------- | ---
| Branch? | 5.1
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets | n/a
| License | MIT
| Doc PR | n/a
`Profiler::loadProfileFromResponse()` can return `null`. Obviously having a return of `null|false` is unfortunate. Not sure what we can do about that...
Commits
-------
ce046fd120 adjust KernelBrowser::getProfile() typehint
This PR was squashed before being merged into the 4.4 branch.
Discussion
----------
[DependencyInjection] Fix circular in DI with lazy + byContruct loop
| Q | A
| ------------- | ---
| Branch? | 4.4
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets | Fix#39120
| License | MIT
| Doc PR | -
This fix another issue lazy service.
It partially revert #38980 and #39021
Initially, we trusted lazy services to be lazy and not beeing called while building the services graph
=> bug #38970 when lazy deps is injected in a factory, it may be consumed directly to build the object before the graph is fully built
Fixed by #38980 => lazy service are considered as "normal service"
=> bug #39015 some loop are not resolvable with "normal service", but it shouldn't be an issue when servie proxifyied
Fixed by #39021 => lazy service are considered as "normal service" except when proxyfied
=> bug #39120 some loop are not resolvable with "normal service", but it shouldn't be an issue because the lazy service is injected in the constructor and user
Fixed by this PR => that revert to the initial state. lazy service are trusted.
But now, The IterratorArgument injected in a factory (single exception) is not more considered as lazy
Commits
-------
54af139a4e [DependencyInjection] Fix circular in DI with lazy + byContruct loop
This PR was squashed before being merged into the 5.2 branch.
Discussion
----------
[Security] Automatically register custom authenticator as entry_point (if supported)
| Q | A
| ------------- | ---
| Branch? | 5.2 (hopefully?)
| Bug fix? | no
| New feature? | yes
| Deprecations? | no
| Tickets | Fix#37068
| License | MIT
| Doc PR | -
@weaverryan came up with exactly the same issue as proposed by a contributor before (see referenced ticket). Back then, it was decided impossible to fix: see https://github.com/symfony/symfony/pull/37075. However, after some thinking we came up with a way to fix the issue and improve the DX for custom authenticators.
The new authenticators are no longer required to implement `AuthenticationEntryPointInterface` (required for internal authenticators like the `RememberMeAuthenticator` and pre authenticated ones). This PR uses a compiler pass to check if a custom authenticator is supported:
```yaml
security:
firewalls:
main:
# in any case, if an entry_point is already configured it'll not be overriden
# (http_basic remains the entry point here)
http_basic: ~
custom_authenticator: App\Security\CustomAuthenticator
entry_point: http_basic
# if only one custom authenticator implements AuthenticationEntryPointInterface,
# it's automatically configured as the entry point
custom_authenticator: App\Security\CustomAuthenticator
custom_authenticators: [App\Security\CustomAuthenticator, App\Security\NoEntryPointAuthenticator]
# if no custom authenticator implements AuthenticationEntryPointInterface,
# an error is thrown
custom_authenticator: App\Security\NoEntryPointAuthenticator
# if more than one authenticator implements AuthenticationEntryPointInterface,
# the entry point must be configured explicitly (or an error is thrown)
custom_authenticators: [App\Security\CustomAuthenticator, App\Security\AnotherCustomAuthenticator]
entry_point: App\Security\CustomAuthenticator
```
---
I know this is very late for Symfony 5.2. It would be good to decide whether this can be included in the release, in order to smooth out the biggest struggle for people using custom authenticators for the first time.
Commits
-------
cab0672248 [Security] Automatically register custom authenticator as entry_point (if supported)
This PR was squashed before being merged into the 4.4 branch.
Discussion
----------
Add Romanian missing translations
| Q | A
| ------------- | ---
| Branch? | 4.4
| Bug fix? | kinda
| New feature? | no
| Deprecations? | no
| Tickets | Fix#38758
| License | MIT
| Doc PR | n/a
Commits
-------
6aa31a13c7 Add Romanian missing translations
This PR was merged into the 5.3-dev branch.
Discussion
----------
[DomCrawler] Cache discovered namespaces
| Q | A
| ------------- | ---
| Branch? | 5.x
| Bug fix? | no
| New feature? | yes
| Deprecations? | no
| Tickets | Address #39067
| License | MIT
Discovering namespaces is by far the most expensive task when filtering for nodes and the xpath contains prefixes.
When `Crawler::filterRelativeXPath` is called multiple times with (identical) prefixes the slowdown is huge.
This fix brings the runtime of the linked ticket down from 27 seconds to 9 seconds in my test. Compared to a pure PHP version which takes < 0.5 seconds the design of the crawler API is the limiting factor. There are still many repeated namespace queries caused by new Crawler instances. Ideas to solve this are discussed in the ticket.
Commits
-------
a8e85ecbbd Make some CS changes
4c74dead48 Cache discovered namespaces in DomCrawler