This PR was merged into the 3.4 branch.
Discussion
----------
[FrameworkBundle] fix describing routes with no controllers
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Spotted by @jpauli during a training.
Commits
-------
a1c612aedf [FrameworkBundle] fix describing routes with no controllers
This PR was merged into the 3.4 branch.
Discussion
----------
[DI] move RegisterServiceSubscribersPass before DecoratorServicePass
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #29550
| License | MIT
| Doc PR | n/a
From https://github.com/symfony/symfony/issues/29550#issuecomment-446351365: The fact that `RegisterServiceSubscribersPass` runs after `DecoratorServicePass` makes it impossible to decorate a service implementing `ServiceSubscriberInterface` if the decorator does not implement it.
Commits
-------
c3271d9385 [DI] move RegisterServiceSubscribersPass before DecoratorServicePass
This PR was merged into the 3.4 branch.
Discussion
----------
[TwigBridge][Form] Prevent multiple rendering of form collection prototypes
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #29489 <!-- #-prefixed issue number(s), if any -->
| License | MIT
prevents attemt to render of prototype in CollectionType when it has been rendered already.
(see [Deprecated calling FormRenderer::searchAndRenderBlock for fields which were already rendered.](https://github.com/symfony/symfony/blob/master/UPGRADE-4.2.md#form))
Commits
-------
ffd272243b [TwigBridge][Form] Prevent multiple rendering of form collection prototypes
This comment was misleading.
It's true that no groups (ie.: `Default`) are setted into validation process but it's not clear from the comment.
I suppose that is better to be more explicit about this process.
BTW I'm still not sure if `FormValidator` reference is necessary as we can change it and we should remember to update this comment and this does not seems to fit.
WDYT, is better to leave `FormValidator` out of this comment?
For reference: https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Form/Extension/Validator/Constraints/FormValidator.php#L46-L92
This PR was merged into the 4.3-dev branch.
Discussion
----------
[FrameworkBundle] Stop calling Kernel::boot() twice in cli
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29505
| License | MIT
| Doc PR | n/a
Allows custom `Kernel::boot()` implementations to not be aware of the protected `Kernel::$booted` prop.
Commits
-------
97e15fe1b5 [FrameworkBundle] Stop calling Kernel::boot() twice in cli
This PR was merged into the 4.3-dev branch.
Discussion
----------
[EventDispatcher][VarDumper] optimize perf by leveraging Closure::fromCallable()
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Callables are notably slower than closures. Let's turn then to closures thanks to `Closure::fromCallable()`.
This doesn't affect performance for run-once listeners.
And improves performance for events that are dispatched several times.
Same for VarDumper's casters.
Commits
-------
d6a594bf42 [EventDispatcher][VarDumper] optimize perf by leveraging Closure::fromCallable()
This PR was squashed before being merged into the 4.3-dev branch (closes#28931).
Discussion
----------
[PhpUnitBridge] Added ClassExistsMock
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/issues/10528
I've thought about this before, and bumped into it again when trying to test #28898
This PR allows to mock `class|interface|trait_exists` to enable specific code path testing
Commits
-------
62caec1a79 [PhpUnitBridge] Added ClassExistsMock
This PR was merged into the 4.1 branch.
Discussion
----------
Optimize perf by replacing call_user_func with dynamic variables
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
This provides similar boost as in https://github.com/symfony/symfony/pull/29245, but on more places and without complexity increase. Check eg. https://github.com/fab2s/call_user_func for proof
Fabpot failure unrelated
Commits
-------
0c6ef01713 Optimize perf by replacing call_user_func with dynamic vars
This PR was squashed before being merged into the 3.4 branch (closes#29408).
Discussion
----------
[Security] getTargetPath of TargetPathTrait must return string or null
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes (possible bug)
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
Since the return type is string the default return value must be also string.
Commits
-------
8d4b787dd9 [Security] getTargetPath of TargetPathTrait must return string or null
This PR was squashed before being merged into the 4.3-dev branch (closes#29504).
Discussion
----------
[Validator] Add support for UATP card validation
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
[UATP](https://en.wikipedia.org/wiki/Universal_Air_Travel_Plan) (Universal Air Travel Plan) is the airline owned payment network accepted by thousands of merchants for rail, air, hotel and travel agency payments. This PR adds support for UATP cards so they can be validated using the Symfony Validator component.
According to https://en.wikipedia.org/wiki/Payment_card_number, all UATP cards start with `1`, have a length of 15 digits and follow the [Luhn algorithm](https://en.wikipedia.org/wiki/Luhn_algorithm). Test card numbers can be generated from https://www.myfakeinfo.com/creditcard/uatp-debit-card.php
Commits
-------
2446a1763d [Validator] Add support for UATP card validation
This PR was merged into the 3.4 branch.
Discussion
----------
[HttpFoundation] Fix HeaderBag::get phpdoc
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
When setting `$first` to `false`, the default value is wrapped into an array meaning you need to pass a string as the default value instead of an array of strings.
Commits
-------
5196dac7a8 Fix HeaderBag::get phpdoc
This PR was squashed before being merged into the 4.3-dev branch (closes#29168).
Discussion
----------
[Console] Add hyperlinks support
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #21207
| License | MIT
| Doc PR |
For details about this see https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda
Here's one idea/use case which could utilize this feature (not implemented in this PR as it requires more work)
![stack trace with anchors](https://user-images.githubusercontent.com/496233/48305600-00d4c300-e52e-11e8-94e6-33713ff09d50.png)
I checked this in cmd.exe as well and no sideffects there
Commits
-------
db750ed8ae [Console] Add hyperlinks support
This PR was merged into the 4.3-dev branch.
Discussion
----------
[PhpUnitBridge] install PHPUnit 7 on PHP 7.1 and fix requir. for PHPUnit 6
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Added support of PHPUnit 7.4 if PHP version is 7.1+ (release link: https://packagist.org/packages/phpunit/phpunit#7.4.5).
Also I found that PHPUnit 6.5 required PHP 7.0, not 7.2 (proof: https://packagist.org/packages/phpunit/phpunit#6.5.13)
Commits
-------
30609bfa70 [PhpUnitBridge] install PHPUnit 7 on PHP 7.1 and fix require for PHPUnit 6
This PR was merged into the 3.4 branch.
Discussion
----------
Feature/add missing space
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Adding a much needed space in the serviceLocator createNotFoundException error message.
from
`Service "foo" not found: even though it exists in the app's container, the container inside "foo" is a smaller service locator that is empty...Try using dependency injection instead.
`
to
`Service "foo" not found: even though it exists in the app's container, the container inside "foo" is a smaller service locator that is empty... Try using dependency injection instead.
`
#SymfonyConHackday2018
Commits
-------
ceb7a68efa merge conflicts
This PR was squashed before being merged into the 3.4 branch (closes#29513).
Discussion
----------
[Hackday][Serializer] Deserialization ignores argument type hint from phpdoc for array in constructor argument
| Q | A
| ------------- | ---
| Branch? | 3.4 and up to 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28825
| License | MIT
This is a fix of #28825 big thanks @dunglas and @xabbuh
Commits
-------
8741d00d6e [Hackday][Serializer] Deserialization ignores argument type hint from phpdoc for array in constructor argument
This PR was merged into the 4.2 branch.
Discussion
----------
[WebProfilerBundle][TwigBundle] CSS fixes
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
5e59d7fe54 [WebProfilerBundle][TwigBundle] CSS fixes
* 3.4:
[Validator] Added IBAN format for Vatican City State
filter out invalid Intl values
[Validator] Fixed grouped composite constraints
[Form] Filter arrays out of scalar form types
This PR was squashed before being merged into the 3.4 branch (closes#29531).
Discussion
----------
[Validator] Added IBAN format for Vatican City State
IBAN for Vatican City State was added to [IBAN registry](https://www.swift.com/sites/default/files/resources/iban_registry.pdf) recently. This PR adds support for this new format in the `Iban` validator.
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
Commits
-------
5f0261429a [Validator] Added IBAN format for Vatican City State
This PR was merged into the 4.2 branch.
Discussion
----------
[FrameworkBundle][Controller] Use interface from Contracts to remove deprecation arnings
| Q | A
| ------------- | ---
| Branch? | 4.2?
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | I don't think so <!-- see https://symfony.com/bc -->
| Deprecations? | no - removing some :) <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | n/a
When we installed 4.2, we hit issues in our qa tools with [vimeo/psalm](https://github.com/vimeo/psalm) reporting that all of our controllers were implementing a deprecated interface (by extending the AbstractController).
This pr simply updates the AbstractController to use the interface provided in `symfony/contracts`
I'm not sure if there was any other reason for not including this in the 4.2 release (bc?), so apologies if I've overstepped this.
Commits
-------
f10227df3d [FrameworkBundle][Controller] Use interface from Contracts to remove deprecation warnings
This PR was merged into the 4.1 branch.
Discussion
----------
[Form] filter out invalid language values
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #23679
| License | MIT
| Doc PR |
Commits
-------
ed97568b8a filter out invalid language values
This PR was merged into the 3.4 branch.
Discussion
----------
[Form] Filter arrays out of scalar form types
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/4102
| License | MIT
| Doc PR | -
Replaces fix https://github.com/symfony/symfony/pull/20935
Commits
-------
000e4aab5e [Form] Filter arrays out of scalar form types
This PR was merged into the 3.4 branch.
Discussion
----------
[Validator] Fixed grouped composite constraints
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17675, #25888, #23480
| License | MIT
| Doc PR | ~
From Lisbon :). Thanks @stof, @xabbuh for your help to finally fix this old issue.
Commits
-------
b53d9112ca [Validator] Fixed grouped composite constraints
* 4.2:
change timezone to fix tests on Windows
bumped Symfony version to 4.2.2
updated VERSION for 4.2.1
updated CHANGELOG for 4.2.1
bumped Symfony version to 4.1.10
updated VERSION for 4.1.9
updated CHANGELOG for 4.1.9
bumped Symfony version to 3.4.21
updated VERSION for 3.4.20
update CONTRIBUTORS for 3.4.20
updated CHANGELOG for 3.4.20
* 4.1:
change timezone to fix tests on Windows
bumped Symfony version to 4.1.10
updated VERSION for 4.1.9
updated CHANGELOG for 4.1.9
bumped Symfony version to 3.4.21
updated VERSION for 3.4.20
update CONTRIBUTORS for 3.4.20
updated CHANGELOG for 3.4.20
* 3.4:
change timezone to fix tests on Windows
bumped Symfony version to 3.4.21
updated VERSION for 3.4.20
update CONTRIBUTORS for 3.4.20
updated CHANGELOG for 3.4.20
As I understand the failing tests timezones have changed in Russia in
2016, but this is not reflected in the timezone database used on
AppVeyor. Since the tests do not depend on a particular timezone (it's
only important for it to be different from UTC) we should safely be able
to switch to another timezone.
* 4.2:
[Security\Http] detect bad redirect targets using backslashes
[Form] Filter file uploads out of regular form types
Fix CI
minor #28258 [travis] fix composer.lock invalidation for deps=low (nicolas-grekas)
[travis] fix composer.lock invalidation for PRs patching several components
[travis] fix composer.lock invalidation for deps=low
minor #28199 [travis][appveyor] use symfony/flex to accelerate builds (nicolas-grekas)
[travis] ignore ordering when validating composer.lock files for deps=low
minor #28146 [travis] cache composer.lock files for deps=low (nicolas-grekas)
fix ci
[travis] fix requiring mongodb/mongodb before composer up
minor #28114 [travis] merge "same Symfony version" jobs in one (nicolas-grekas)
[2.7] Make CI green
updated VERSION for 2.7.49
updated CHANGELOG for 2.7.49
[HttpKernel] fix trusted headers management in HttpCache and InlineFragmentRenderer
[HttpFoundation] Remove support for legacy and risky HTTP headers
updated VERSION for 2.7.48
update CONTRIBUTORS for 2.7.48
updated CHANGELOG for 2.7.48
* 4.1:
[Security\Http] detect bad redirect targets using backslashes
[Form] Filter file uploads out of regular form types
Fix CI
minor #28258 [travis] fix composer.lock invalidation for deps=low (nicolas-grekas)
[travis] fix composer.lock invalidation for PRs patching several components
[travis] fix composer.lock invalidation for deps=low
minor #28199 [travis][appveyor] use symfony/flex to accelerate builds (nicolas-grekas)
[travis] ignore ordering when validating composer.lock files for deps=low
minor #28146 [travis] cache composer.lock files for deps=low (nicolas-grekas)
fix ci
[travis] fix requiring mongodb/mongodb before composer up
minor #28114 [travis] merge "same Symfony version" jobs in one (nicolas-grekas)
[2.7] Make CI green
updated VERSION for 2.7.49
updated CHANGELOG for 2.7.49
[HttpKernel] fix trusted headers management in HttpCache and InlineFragmentRenderer
[HttpFoundation] Remove support for legacy and risky HTTP headers
updated VERSION for 2.7.48
update CONTRIBUTORS for 2.7.48
updated CHANGELOG for 2.7.48
* 3.4:
[Security\Http] detect bad redirect targets using backslashes
[Form] Filter file uploads out of regular form types
Fix CI
minor #28258 [travis] fix composer.lock invalidation for deps=low (nicolas-grekas)
[travis] fix composer.lock invalidation for PRs patching several components
[travis] fix composer.lock invalidation for deps=low
minor #28199 [travis][appveyor] use symfony/flex to accelerate builds (nicolas-grekas)
[travis] ignore ordering when validating composer.lock files for deps=low
minor #28146 [travis] cache composer.lock files for deps=low (nicolas-grekas)
fix ci
[travis] fix requiring mongodb/mongodb before composer up
minor #28114 [travis] merge "same Symfony version" jobs in one (nicolas-grekas)
[2.7] Make CI green
updated VERSION for 2.7.49
updated CHANGELOG for 2.7.49
[HttpKernel] fix trusted headers management in HttpCache and InlineFragmentRenderer
[HttpFoundation] Remove support for legacy and risky HTTP headers
updated VERSION for 2.7.48
update CONTRIBUTORS for 2.7.48
updated CHANGELOG for 2.7.48
* 2.8:
[Security\Http] detect bad redirect targets using backslashes
[Form] Filter file uploads out of regular form types
Fix CI
minor #28258 [travis] fix composer.lock invalidation for deps=low (nicolas-grekas)
[travis] fix composer.lock invalidation for PRs patching several components
[travis] fix composer.lock invalidation for deps=low
minor #28199 [travis][appveyor] use symfony/flex to accelerate builds (nicolas-grekas)
[travis] ignore ordering when validating composer.lock files for deps=low
minor #28146 [travis] cache composer.lock files for deps=low (nicolas-grekas)
fix ci
[travis] fix requiring mongodb/mongodb before composer up
minor #28114 [travis] merge "same Symfony version" jobs in one (nicolas-grekas)
[2.7] Make CI green
updated VERSION for 2.7.49
updated CHANGELOG for 2.7.49
[HttpKernel] fix trusted headers management in HttpCache and InlineFragmentRenderer
[HttpFoundation] Remove support for legacy and risky HTTP headers
updated VERSION for 2.7.48
update CONTRIBUTORS for 2.7.48
updated CHANGELOG for 2.7.48
* 2.7:
[Security\Http] detect bad redirect targets using backslashes
[Form] Filter file uploads out of regular form types
Fix CI
minor #28258 [travis] fix composer.lock invalidation for deps=low (nicolas-grekas)
[travis] fix composer.lock invalidation for PRs patching several components
[travis] fix composer.lock invalidation for deps=low
minor #28199 [travis][appveyor] use symfony/flex to accelerate builds (nicolas-grekas)
[travis] ignore ordering when validating composer.lock files for deps=low
minor #28146 [travis] cache composer.lock files for deps=low (nicolas-grekas)
fix ci
[travis] fix requiring mongodb/mongodb before composer up
minor #28114 [travis] merge "same Symfony version" jobs in one (nicolas-grekas)
[2.7] Make CI green
updated VERSION for 2.7.49
updated CHANGELOG for 2.7.49
[HttpKernel] fix trusted headers management in HttpCache and InlineFragmentRenderer
[HttpFoundation] Remove support for legacy and risky HTTP headers
updated VERSION for 2.7.48
update CONTRIBUTORS for 2.7.48
updated CHANGELOG for 2.7.48
* 4.2:
[TwigBridge] Deprecating legacy Twig paths in DebugCommand and simplifications
[Cache] Fixed Memcached adapter doClear()to call flush()
Fixes sprintf(): Too few arguments in Translator
fix TransChoiceTokenParser deprecation message
[DoctrineBridge] Conflict with Messenger <4.2
[Contracts] extract LocaleAwareInterface out of TranslatorInterface
This PR was merged into the 4.2 branch.
Discussion
----------
[DoctrineBridge] Conflict with Messenger <4.2
| Q | A
| ------------- | ---
| Branch? | 4.2 <!-- see below -->
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #29463 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Commits
-------
8624cde5b0 [DoctrineBridge] Conflict with Messenger <4.2
This PR was merged into the 4.2 branch.
Discussion
----------
Fix TransChoiceTokenParser deprecation message
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
While debugging a `cache:clear`, I found the following errors on stderr:
```
PHP Warning: sprintf(): Too few arguments in .../vendor/symfony/twig-bridge/TokenParser/TransChoiceTokenParser.php on line 43
```
This was caused by using unescaped `%` in the `sprintf` format string.
This fix the `sprintf` format string so the deprecation message will now works.
Commits
-------
3d3b3ced48 fix TransChoiceTokenParser deprecation message
* 4.2:
[VarExporter] fix dumping private properties from abstract classes
Fix empty output for debug:autowiring when reflection-docblock is not available
[Workflow] Fixed BC break for Workflow metadata
[Routing] ignore trailing slash for non-GET requests
When setting $first to false, the default value is wrapped into an array
meaning you need to pass a string as the default value instead of an
array of strings.
* 4.2:
[Serializer] fixed DateTimeNormalizer to maintain microseconds when a different timezone required
[Routing] fix taking verb into account when redirecting
[TwigBundle] Sync tab navigation css
[WebProfilerBundle] Fix log filter in dark mode
[WebProfilerBundle][4.2] Deny messenger <4.2
[DI] Fix dumping expressions accessing single-use private services
[VarExporter] fix dumping protected property from abstract classes
[WebProfilerBundle] Split form field heading
Minor tweak for c3ad8a5
* 4.1:
[Serializer] fixed DateTimeNormalizer to maintain microseconds when a different timezone required
[Routing] fix taking verb into account when redirecting
[DI] Fix dumping expressions accessing single-use private services
[WebProfilerBundle] Split form field heading
* 3.4:
[Serializer] fixed DateTimeNormalizer to maintain microseconds when a different timezone required
[Routing] fix taking verb into account when redirecting
[WebProfilerBundle] Split form field heading
This PR was squashed before being merged into the 3.4 branch (closes#29413).
Discussion
----------
[Serializer] fixed DateTimeNormalizer to maintain microseconds when a different timezone required
| Q | A
| ------------- | ---
| Branch? | 3.4 up to 4.2 for bug fixes
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #
| License | MIT
| Doc PR | none
fixed `DateTimeNormalizer::normalizer()` when `$object` is mutated internally to change timezone we lost microseconds of origina `$object`
Commits
-------
2bf8a1cae6 [Serializer] fixed DateTimeNormalizer to maintain microseconds when a different timezone required
This PR was squashed before being merged into the 4.3-dev branch (closes#29401).
Discussion
----------
[DI] Fix deps=low
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
cc @nicolas-grekas
Commits
-------
e0d95029c3 [DI] Fix deps=low
This PR was merged into the 4.3-dev branch.
Discussion
----------
[Debug] Mark ErrorHandler and ExceptionHandler classes as final
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | not yet
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
The goal of marking this method final is to be able to change the argument signature to `\Throwable` in Symfony 5.0
We will then be able to convert the incoming `\Throwable` to `\ErrorException` thanks to the `FatalThrowableError` class.
The use case is when you use the `ExceptionHandler::register()` method of the `Debug` component with a custom `set_error_handler()` that don't handle this conversion. This is for example the case of the `Drupal` one.
Commits
-------
2a4e2e614b [Debug] Mark the ErrorHandler and ExceptionHandler classes as final
This PR was merged into the 4.3-dev branch.
Discussion
----------
Add upgrade from 4.2 to 4.3
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Forgotten in #28858 i guess. cc @nicolas-grekas
Commits
-------
ce6ecaf862 Add upgrade from 4.2 to 4.3
This PR was merged into the 4.3-dev branch.
Discussion
----------
[Validator] Checking a BIC along with an IBAN
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28166
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10349
A BIC comes usually with an IBAN so it's better to check that they are associated. This PR provides an `iban` option to `Symfony\Component\Validator\Constraints\Bic` to check the BIC against an IBAN.
It also provides an `ibanPropertyPath` to retrieves the IBAN using the property accessor like with comparison constraints.
Commits
-------
bb6be1534a [Validator] Checking a BIC along with an IBAN Fix#28166
This PR was squashed before being merged into the 4.3-dev branch (closes#28858).
Discussion
----------
[DI] Deprecated using env vars with cannotBeEmpty()
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes-ish
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | yes
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #28827
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Continuation of #28838 for 4.2
Using environment variables for nodes marked `cannotBeEmpty()` is semantically not possible, we'll never know the value is empty yes/no during compile time. Neither we should assume one or another.
Commits
-------
397c19ee5f [DI] Deprecated using env vars with cannotBeEmpty()
This PR was squashed before being merged into the 4.3-dev branch (closes#28976).
Discussion
----------
[DI] Add a "default" EnvProcessor
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | TODO
This PR add a new fallback env processor in order to return a default value when the primary processor is not able to fetch a value (env variable, file or key does not exists)
```
#
default_host: localhost
host: '%env(default:default_host:OPTIONAL_ENV_VARIABLE)%"
default_secret: this secret is not secret
secret: '%env(default:default_secret:file:THIS_FILE_ONLY_EXIST_IN_PRODUCTION)%"
default_charset: utf8
charset: '%env(default:default_charset:key:charset:json:DATABASE_CONFIG)%"
```
Commits
-------
aee4e33cdb [DI] Add a \"default\" EnvProcessor
This PR was squashed before being merged into the 4.3-dev branch (closes#29127).
Discussion
----------
[DomCrawler] Added return of element name in `extract()` method
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| License | MIT
| Doc PR | symfony/symfony-docs#10646
Situation: you need to get an array of keys and values.
The current package code does not allow this to be done easily.
The changes made to the code will allow you to return the required data set.
```php
use Symfony\Component\DomCrawler\Crawler;
$crawler = new Crawler($content);
$crawler
->filter('ItemsList > Item')
->each(function (Crawler $element) {
$data = $element
->children()
->extract(['_name', '_text']);
var_dump($data);
});
// Result:
array:2 [
0 => array:2 [
0 => "id",
1 => "1"
],
1 => array:2 [
0 => "title",
1 => "Foo Bar"
]
]
```
Commits
-------
79162c1eb5 [DomCrawler] Added return of element name in `extract()` method
This PR was merged into the 4.3-dev branch.
Discussion
----------
[Workflow] Trigger `entered` event for subject entering in the Workflow for the first time
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28319
| License | MIT
| Doc PR |
Commits
-------
388840fd99 [Workflow] Trigger `entered` event for subject entering in the Workflow for the first time
* 4.2:
fix cs
[FrameworkBundle] define doctrine as default_pdo_provider only if the package is installed
[Validator] Allow `ConstraintViolation::__toString()` to expose codes that are not null or emtpy strings
Added upgrade to HandlersLocator
fix type for $value in DocBlock
[WebProfilerBundle] Fix title case
[Config] fix path exclusion during glob discovery
[FrameworkBundle][Messenger] Restore check for messenger serializer default id
Fix wrapped loop of event listener
[DI] fix edge case in InlineServiceDefinitionsPass
undeprecate the single-colon notation for controllers
Update HttpKernel.php
* 4.1:
fix cs
[Validator] Allow `ConstraintViolation::__toString()` to expose codes that are not null or emtpy strings
fix type for $value in DocBlock
[WebProfilerBundle] Fix title case
Fix wrapped loop of event listener
[DI] fix edge case in InlineServiceDefinitionsPass
undeprecate the single-colon notation for controllers
Update HttpKernel.php
* 3.4:
fix cs
[Validator] Allow `ConstraintViolation::__toString()` to expose codes that are not null or emtpy strings
fix type for $value in DocBlock
Fix wrapped loop of event listener
Update HttpKernel.php
This PR was merged into the 3.4 branch.
Discussion
----------
Update HttpKernel.php
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
This update adds a docblock to varToString method in HttpKernel Class
Commits
-------
3324e2a2a6 Update HttpKernel.php
This PR was squashed before being merged into the 3.4 branch (closes#29375).
Discussion
----------
[Validator] Allow `ConstraintViolation::__toString()` to expose codes that are not null or emtpy strings
|Q |A |
|--- |---|
|Branch |2.8|
|Bug fix? |yes|
|New feature? |no |
|BC breaks? |no |
|Deprecations?|no |
|Tests pass? |yes|
|Fixed tickets|n/a|
|License |MIT|
|Doc PR |n/a|
Allow to expose `0` or `"0"` validation codes.
Commits
-------
7bb0fb5cc3 [Validator] Allow `ConstraintViolation::__toString()` to expose codes that are not null or emtpy strings
This PR was merged into the 3.4 branch.
Discussion
----------
[EventDispatcher] Fix eventListener wrapper loop in TraceableEventDispatcher
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | none
| License | MIT
| Doc PR | na
The `TracableEventDispatcher` wrap decorate (in the method `preProcess`) each listeners in a `WrappedListener` before delegating the dispatch to the real dispatcher, then remove the wrapper (in the method `postProcess`.
But, if a listener triggers an exception, the `postProcess` method is not called, and the wrapper in not removed.
If the same event is triggered a second time, the listeners will be decorated twice, etc, etc..
This is an issue with php-pm where the same event is triggered hundred of times within the same process.
This PR moves the `postProcess` in a finally block in order to be called even if an exception in thrown.
Commits
-------
3830a9e376 Fix wrapped loop of event listener
This PR was merged into the 4.1 branch.
Discussion
----------
undeprecate the single-colon notation for controllers
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
This is the same as https://github.com/symfony/symfony/pull/29218 but for `Symfony\Bundle\FrameworkBundle\Routing\DelegatingLoader`.
Commits
-------
09371ad6f1 undeprecate the single-colon notation for controllers
This PR was merged into the 4.1 branch.
Discussion
----------
[DI] fix edge case in InlineServiceDefinitionsPass
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Looks like this can happen - dunno how
https://stackoverflow.com/questions/53558247/autowire-services-test-yaml-there-is-no-node-with-id-service-a
Commits
-------
8bd2bbfb1c [DI] fix edge case in InlineServiceDefinitionsPass
This PR was merged into the 4.2 branch.
Discussion
----------
[FrameworkBundle][Messenger] Restore check for messenger serializer default id
| Q | A
| ------------- | ---
| Branch? | 4.2 <!-- see below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | https://symfony-devs.slack.com/archives/C9PQ75TV3/p1543590611003500 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
From Slack:
> @adamquaile [4:10 PM]
> So, I just updated to 4.2 today, and got this message:
> > The default Messenger serializer cannot be enabled as the Serializer support is not available. Try enabling it or running "composer require symfony/serializer-pack"
>
> In the docs it's stated:
> > In order to use Symfony's built-in AMQP transport, you will need the Serializer Component. Ensure that it is installed with:
>
>But I haven't yet configured AMQP - I'm using my own transport. Should I be getting this exception?
---
This check was removed in https://github.com/symfony/symfony/pull/28405, but is actually still necessary to not fail as soon as you can install the Messenger component without the Serializer one installed.
Commits
-------
1cf17c08e9 [FrameworkBundle][Messenger] Restore check for messenger serializer default id
This PR was merged into the 3.4 branch.
Discussion
----------
[Form] Handle all case variants of "nan" when parsing a number
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29321
| License | MIT
| Doc PR | n/a
NumberToLocalizedStringTransformer::reverseTransform now special cases all case variants of "NaN", not just "NaN" specifically to insulate itself from changing behaviour in ICU.
Commits
-------
85af682834 add a test case
d903dcbac5 [Form] Handle all case variants of "nan" when parsing a number
This PR was merged into the 3.4 branch.
Discussion
----------
typo
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR |
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
977a007e3a typo
* 4.2:
[Routing] fix trailing slash redirection
calculate cache keys for property setters depending on the value
updated VERSION for 2.8.48
update CONTRIBUTORS for 2.8.48
updated CHANGELOG for 2.8.48
* 4.1:
[Routing] fix trailing slash redirection
calculate cache keys for property setters depending on the value
updated VERSION for 2.8.48
update CONTRIBUTORS for 2.8.48
updated CHANGELOG for 2.8.48
* 3.4:
calculate cache keys for property setters depending on the value
updated VERSION for 2.8.48
update CONTRIBUTORS for 2.8.48
updated CHANGELOG for 2.8.48
This PR was merged into the 3.4 branch.
Discussion
----------
[PropertyAccess] calculate cache keys for property setters depending on the value
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29340
| License | MIT
| Doc PR |
Commits
-------
fa234378ff calculate cache keys for property setters depending on the value
This PR was merged into the 3.4 branch.
Discussion
----------
[DI] fix combinatorial explosion when analyzing the service graph
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29336
| License | MIT
| Doc PR | -
and a few minor things found meanwhile.
Commits
-------
0d0be12e07 [DI] fix combinatorial explosion when analyzing the service graph
* 4.2:
Update PR template
Fixes sprintf(): Too few arguments in Translator
[Cache] fix deps
updated CHANGELOG for 4.2.0-RC1
bumped Symfony version to 4.1.9
updated VERSION for 4.1.8
updated CHANGELOG for 4.1.8
bumped Symfony version to 3.4.20
updated VERSION for 3.4.19
updated CHANGELOG for 3.4.19
[Console] Move back root exception to stack trace in verbose mode
* 4.1:
Update PR template
bumped Symfony version to 4.1.9
updated VERSION for 4.1.8
updated CHANGELOG for 4.1.8
bumped Symfony version to 3.4.20
updated VERSION for 3.4.19
updated CHANGELOG for 3.4.19
[Console] Move back root exception to stack trace in verbose mode
Fixes the log produced when the method is called :
Before : "sprintf(): Too few arguments"
After : "The "Symfony\Component\Translation\Translator::transChoice()" method is deprecated since Symfony 4.2, use the trans() one instead with a "%count%" parameter."
Reference : http://php.net/manual/function.sprintf.php
This PR was merged into the 3.4 branch.
Discussion
----------
[Console] Move back root exception to stack trace in verbose mode
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29232
| License | MIT
| Doc PR | n/a
Commits
-------
63cd219a5c [Console] Move back root exception to stack trace in verbose mode
* 4.1: (23 commits)
[Routing] fix trailing slash redirection when using RedirectableUrlMatcher
[PropertyAccessor] fix encoding of cache keys
[WebProfiler] Detect empty file paths in file viewer
fixed CS
Changes for upcoming Travis' infra migration
Doc fix: clarify isMethodCacheable() returns true only for GET & HEAD
[MonologBridge] Return empty list for unknonwn requests
[DomCrawler] exclude fields inside "template" tags
Use XLIFF source rather than resname when there's no target
[DoctrineBridge] catch errors while converting to db values in data collector
[DoctrineBridge] fix case sensitivity issue in RememberMe\DoctrineTokenProvider
[EventDispatcher] Unwrap wrapped listeners internally
[Routing] fix trailing slash redirection when using RedirectableUrlMatcher
Removed the return type phpdoc
fix authorization checker variable name
[Routing] Remove duplicate schemes and methods for invokable controllers
Indentation error
[HttpFoundation] Fix trailing space for mime-type with parameters
[HttpFoundation] Fixed absolute Request URI with default port
[Bridge/PhpUnit] fix the fix
...
* 3.4:
[Routing] fix trailing slash redirection when using RedirectableUrlMatcher
[PropertyAccessor] fix encoding of cache keys
[WebProfiler] Detect empty file paths in file viewer
fixed CS
Changes for upcoming Travis' infra migration
Doc fix: clarify isMethodCacheable() returns true only for GET & HEAD
[DomCrawler] exclude fields inside "template" tags
Use XLIFF source rather than resname when there's no target
[DoctrineBridge] catch errors while converting to db values in data collector
[DoctrineBridge] fix case sensitivity issue in RememberMe\DoctrineTokenProvider
[EventDispatcher] Unwrap wrapped listeners internally
Indentation error
[HttpFoundation] Fix trailing space for mime-type with parameters
[HttpFoundation] Fixed absolute Request URI with default port
properly parse backslashes in unquoted env vars
Use intersection type when referring to ParentNodeDefinitionInterface
[BrowserKit] fixed BC Break for HTTP_HOST header; implemented same behaviour for HTTPS server parameter
This PR was merged into the 4.1 branch.
Discussion
----------
[Routing] fix trailing slash redirection when using RedirectableUrlMatcher
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29297
| License | MIT
| Doc PR | -
This is #29297 for 4.1
Commits
-------
6968000a3c [Routing] fix trailing slash redirection when using RedirectableUrlMatcher
This PR was merged into the 3.4 branch.
Discussion
----------
[Routing] fix trailing slash redirection when using RedirectableUrlMatcher
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29287
| License | MIT
| Doc PR | -
This fixes#29287 by considering that the behavior of the dumped matcher is the correct one: lower priority routes never impact previous ones. I think it's what makes the most sense because that's what requires the most local knowledge to understand what's going on (ie that's the less surprising behavior).
Commits
-------
dc4c3f6927 [Routing] fix trailing slash redirection when using RedirectableUrlMatcher
* 2.8:
fixed CS
Changes for upcoming Travis' infra migration
Doc fix: clarify isMethodCacheable() returns true only for GET & HEAD
[DomCrawler] exclude fields inside "template" tags
Use XLIFF source rather than resname when there's no target
[DoctrineBridge] catch errors while converting to db values in data collector
[DoctrineBridge] fix case sensitivity issue in RememberMe\DoctrineTokenProvider
Indentation error
[HttpFoundation] Fix trailing space for mime-type with parameters
Use intersection type when referring to ParentNodeDefinitionInterface
[BrowserKit] fixed BC Break for HTTP_HOST header; implemented same behaviour for HTTPS server parameter
This PR was merged into the 4.2-dev branch.
Discussion
----------
[HttpKernel] handle anonymous classes when generating the dumped container class name
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29322
| License | MIT
| Doc PR | -
Commits
-------
ac84cb2fbe [HttpKernel] handle anonymous classes when generating the dumped container class name
This PR was merged into the 2.8 branch.
Discussion
----------
[Config] Use intersection type when referring to ParentNodeDefinitionInterface
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Allows PHPStan to understand it correctly (refs https://github.com/libero/content-api-bundle/pull/2#discussion_r226237763).
PHPStorm 2018.3 will add support for it too, but to help older versions I've reversed the order (so `NodeDefinition` is recognised).
Commits
-------
e9cdabe570 Use intersection type when referring to ParentNodeDefinitionInterface
This PR was merged into the 2.8 branch.
Discussion
----------
[DoctrineBridge] catch errors while converting to db values in data collector
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
When the profiler is enabled and collecting doctrine queries data, if a query fails because of `ConversionException` or another error thrown while resolving parameters, the data collector is also throwing the same error.
This should fix this case. The tests for this case cannot be executed in 5.4 because Doctrine 2.5 fails with a fatal error in `DateType`.
Commits
-------
61c4531292 [DoctrineBridge] catch errors while converting to db values in data collector
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Contracts][Cache] allow retrieving metadata of cached items
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
We added `ItemInterface::getMetadata()` because getting them in userland is useful to propagate to higher level caches (eg sending tags + remaining ttl to Varnish).
But we forgot to add a way to retrieve them when using the new `CacheInterface::get()`.
This PR fixes it by adding a 4th `&$metadata` to the method.
Commits
-------
302b8446a7 [Contracts][Cache] allow retrieving metadata of cached items
This PR was merged into the 4.2-dev branch.
Discussion
----------
[DI] fix copying expression providers when analyzing the service graph
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29304
| License | MIT
| Doc PR | -
Courtesy of @mishal, thanks for providing all the details.
Commits
-------
246164f748 [DI] fix copying expression providers when analyzing the service graph
This PR was merged into the 2.8 branch.
Discussion
----------
[Translation] Use XLIFF source rather than resname when there's no target
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Relates to https://github.com/symfony/symfony/issues/20076#issuecomment-251552328. If there's no `<target>` in an XLIFF but there is a `@resname` then that's used rather than the `<source>`.
If I'm using translation keys and my source locale is `en`, then it's a bit redundant to duplicate the `<source>` in the `<target>` in the `en` file (since there is no translation).
This isn't changing the behaviour when `<target>` is present but empty.
(Caveat: I'm definitely not an expert on XLIFF.)
Commits
-------
8633ebbca0 Use XLIFF source rather than resname when there's no target
This PR was merged into the 2.8 branch.
Discussion
----------
[BrowserKit] fixed BC Break for HTTP_HOST header
| Q | A
| ------------- | ---
| Branch? | 2.7, 2.8, 3.x, 4.x
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes/no
| Fixed tickets | #22933
| License | MIT
| Doc PR | n/a
The situation well described in the original issue. I will add only:
- #10549 - makes server parameters to take precedence over URI.
- #16265 - partially revererts #10549. Makes server parameters do not affect URI. But this is only true for `Client::request()`. It is still possible to set host for URI by `Client::setServerParameters()` when URI is realative (see examples below).
I propose a compromise solution: add to HTTP_HOST header power to override URI when it is relative.
Proposed solution:
- if the request URI is relative, then use the HTTP_HOST header passed to Client::request() to generate an absolute URI
- if the request URI is absolute, then ignore the HTTP_HOST header (as it now works)
- do the same with HTTPS server parameter
Profit:
- fix BC Break
- the documentation will be correct
- http://symfony.com/doc/2.8/routing/hostname_pattern.html#testing-your-controllers
- https://symfony.com/doc/2.8/testing.html#testing-configuration
Before:
```
$client->setServerParameters(['HTTP_HOST' => 'example.com']);
$client->request('GET', '/');
$this->assertEquals('http://example.com/', $client->getRequest()->getUri());
$client->request('GET', '/', [], [], ['HTTP_HOST' => 'example.com']);
$this->assertEquals('http://localhost/', $client->getRequest()->getUri());
```
Fixed (see last line):
```
$client->setServerParameters(['HTTP_HOST' => 'example.com']);
$client->request('GET', '/');
$this->assertEquals('http://example.com/', $client->getRequest()->getUri());
$client->request('GET', '/', [], [], ['HTTP_HOST' => 'example.com']);
$this->assertEquals('http://example.com/', $client->getRequest()->getUri());
```
Commits
-------
8c4a59467f [BrowserKit] fixed BC Break for HTTP_HOST header; implemented same behaviour for HTTPS server parameter
This PR was merged into the 2.8 branch.
Discussion
----------
[DomCrawler] exclude fields inside "template" tags
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27285
| License | MIT
| Doc PR |
Exclude fields values/files if fields are inside template tag. I think better to exclude values only instead of excluding fields at all (described in ticket #27285)
Commits
-------
19e3e154d7 [DomCrawler] exclude fields inside "template" tags
The current documentation points to https://tools.ietf.org/html/rfc7231#section-4.2.3.
The spec says: "this specification defines GET, HEAD, and POST as cacheable, although the overwhelming majority of cache implementations only support GET and HEAD.".
This fix to the documentation clarifies that Symfony follows majority (excluding POST) rather than the spec (including POST).
This PR was merged into the 3.4 branch.
Discussion
----------
[HttpFoundation] Fixed absolute Request URI with default port
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29234
| License | MIT
| Doc PR |
This PR fixes the #29234 issue, the request URI with default port was not properly generated.
Example :
```php
$request = Request::create('http://test.com:80/foo');
$request->server->set('REQUEST_URI', 'http://test.com:80/foo');
```
Before this fix, the `$request->getUri()` method returned `http://test.com/:80/foo` :
```diff
Failed asserting that two strings are equal.
--- Expected
+++ Actual
@@ @@
-'http://test.com/foo'
+'http://test.com/:80/foo'
```
Commits
-------
cddce2af61 [HttpFoundation] Fixed absolute Request URI with default port
This PR was merged into the 3.4 branch.
Discussion
----------
[Routing] Remove duplicate schemes and methods for invokable controllers
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29225
| License | MIT
This PR backport for 3.4 branch the same issue than the PR #29225.
I add a test to check the fix when annotation are on the class and rename another one when the route annotation is on the invoke method.
Commits
-------
640ccdf069 [Routing] Remove duplicate schemes and methods for invokable controllers
This PR was merged into the 2.8 branch.
Discussion
----------
[HttpFoundation] Fix trailing space for mime-type with parameters
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
This PR fixes a minor issue that we've discovered by exposing our API towards mobile applications which where sending the header as following `content-type: application/json ;charset=UTF-8`. Request is unable to determine the `getContentType -> getFormat` as **json** due to the whitespace at the end.
```php
$request = Request::createFromGlobals();
$request->headers->set('CONTENT_TYPE', 'application/json ;charset=UTF-8'); // Forcing header for test
if ($request->getContentType() !== 'json') {
// Return 415 (Unsupported Media Type) status code..
}
```
When checking https://tools.ietf.org/html/rfc7231#section-3.1.1.1 it seems that a space is part of the RFC spec. (Where OWS is abbreviated for Optional WhiteSpace)
```
media-type = type "/" subtype *( OWS ";" OWS parameter )
```
Current the following cases are supported:
* application/json; charset=UTF-8
* application/json;charset=UTF-8
The following are failing:
* application/json ; charset=UTF-8
* application/json ;charset=UTF-8
Commits
-------
f4866bc371 [HttpFoundation] Fix trailing space for mime-type with parameters
* 4.1:
fix cs
fix cs
fix cs
SCA: consolidate non empty array checks across codebase
[cs] correct invalid @param types
[Bridge/PhpUnit] Use composer to download phpunit
[DI] fix taking lazy services into account when dumping the container
[Form] Fixed empty data for compound date interval
[Cache] fix optimizing Psr6Cache for AdapterInterface pools
deal with explicitly enabled workflow nodes
* 3.4:
fix cs
SCA: consolidate non empty array checks across codebase
[cs] correct invalid @param types
[Bridge/PhpUnit] Use composer to download phpunit
[DI] fix taking lazy services into account when dumping the container
[Form] Fixed empty data for compound date interval
[Cache] fix optimizing Psr6Cache for AdapterInterface pools
deal with explicitly enabled workflow nodes
This PR was squashed before being merged into the 3.4 branch (closes#29231).
Discussion
----------
SCA: consolidate non empty array checks across codebase
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
This PR replaces `is_array(...) && count(...) > 0` with `... && is_array(...)` construct used in the codebase.
Commits
-------
2f1fd54dda SCA: consolidate non empty array checks across codebase
This PR was merged into the 3.4 branch.
Discussion
----------
[Cache] fix optimizing Psr6Cache for AdapterInterface pools
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -.
As described by @Tobion in https://github.com/symfony/symfony/pull/29236/files#r234324045:
> The problem I have experienced is that in dev mode the cache is decorated with a TraceableCache. This means it loses this optimization and introduces https://github.com/symfony/symfony/issues/28918#issuecomment-432399481 again
Commits
-------
b8100a9df0 [Cache] fix optimizing Psr6Cache for AdapterInterface pools
This PR was merged into the 3.4 branch.
Discussion
----------
[DI] fix taking lazy services into account when dumping the container
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29246
| License | MIT
| Doc PR | -
This PR fixes issues found while working on #29246.
It *does* fix the infinite loop, ~but replaces it by an exception (reopening #29078)~:
> ~It's a requirement to specify a Metadata Driver and pass it to Doctrine\ORM\Configuration::setMetadataDriverImpl()~
The full fix is not immediately accessible as it needs some core changes to the dumping logic. Requiring `symfony/proxy-manager-bridge` works around the issue properly.
See #29251 for 4.2
Commits
-------
67d7623e72 [DI] fix taking lazy services into account when dumping the container
This PR was merged into the 3.4 branch.
Discussion
----------
[Form] Fixed empty data for compound date interval
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #4715 (continuation)
| License | MIT
| Doc PR | ~
Following #29182, since this type has been introduced in Symfony 3 but with the same limitation explained in #4715.
So for consistency this needs to be fixed here as well.
Commits
-------
38a2abc790 [Form] Fixed empty data for compound date interval
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Improved message when handler class does not exist
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? |no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
**Problem:**
When defining a non existing messenger handler class in the `services.yml` config file, we encounter this confusing error message:
```
services:
App\Handler\NonExistentHandler:
tags: [messenger.message_handler]
```
```
PHP Fatal error: Uncaught Symfony\Component\Debug\Exception\FatalThrowableError: Argument 1 passed to Symfony\Component\Messenger\DependencyInjection\MessengerPass::guessHandledClasses() must be an instance of ReflectionClass, null given, called in /app/vendor/symfony/messenger/DependencyInjection/MessengerPass.php on line 93 in /app/vendor/symfony/messenger/DependencyInjection/MessengerPass.php:189
Stack trace:
#0 /app/vendor/symfony/messenger/DependencyInjection/MessengerPass.php(93): Symfony\Component\Messenger\DependencyInjection\MessengerPass->guessHandledClasses(NULL, 'App\\Application...')
#1 /app/vendor/symfony/messenger/DependencyInjection/MessengerPass.php(74): Symfony\Component\Messenger\DependencyInjection\MessengerPass->registerHandlers(Object(Symfony\Component\DependencyInjection\ContainerBuilder), Array)
#2 /app/vendor/symfony/dependency-injection/Compiler/Compiler.php(95): Symfony\Component\Messenger\DependencyInjection\MessengerPass->process(Object(Symfony\Component\DependencyInjection\ContainerBuilder))
#3 / in /app/vendor/symfony/messenger/DependencyInjection/MessengerPass.php on line 189
```
**Proposal:**
We can throw a more relevant exception (RuntimeException) in this case to help the developer to have a better understanding of the issue.
```Invalid service "App\Handler\NonExistentHandler": class "App\Handler\NonExistentHandler" does not exist.```
Commits
-------
6ab9274638 Improve error message when defining messenger handler class that does not exists
This PR was merged into the 2.8 branch.
Discussion
----------
[Validator] Added the missing constraints instance checks
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
This PR adds the constraints instance checks missing to limit the validators use.
This behavior is already implemented in all built-in validators, but it was missed in two validators.
Commits
-------
0ecaead015 [Validator] Added the missing constraints instance checks
* 4.1:
Undeprecate the single-colon notation for controllers
Command::addOption should allow int in $default
Update symfony links to https
[Form] Fixed keeping hash of equal \DateTimeInterface on submit
[PhpUnitBridge] Fix typo
[Routing] generate(null) should throw an exception
[Form] Minor fixes in docs and cs
[Workflow] Made code simpler
[Config] Unset key during normalization
[Form] Fixed empty data for compound date types
invalidate forms on transformation failures
[FrameworkBundle] fixed guard event names for transitions
method buildTransitionBlockerList returns TransitionBlockerList of expected transition
[FrameworkBundle] fixed guard event names for transitions
[PropertyAccessor] Fix unable to write to singular property using setter while plural adder/remover exist
* 3.4:
Command::addOption should allow int in $default
[Form] Fixed keeping hash of equal \DateTimeInterface on submit
[PhpUnitBridge] Fix typo
[Form] Minor fixes in docs and cs
[Config] Unset key during normalization
[Form] Fixed empty data for compound date types
invalidate forms on transformation failures
[PropertyAccessor] Fix unable to write to singular property using setter while plural adder/remover exist
This PR was merged into the 3.4 branch.
Discussion
----------
[PropertyAccessor] Fix unable to write to singular property using setter while plural adder/remover exist
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28961
| License | MIT
Please take a look at the tests I added - they describe the issue. It has to do with the priorities: `findAdderAndRemover('User', 'email')` is called earlier than `$this->isMethodAccessible('User', 'setEmail', 1)`
Commits
-------
8238f167ad [PropertyAccessor] Fix unable to write to singular property using setter while plural adder/remover exist
This PR was merged into the 2.8 branch.
Discussion
----------
[Form] Fixed empty data for compound date types
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #4715
| License | MIT
| Doc PR | ~
Commits
-------
9bab1e8aba [Form] Fixed empty data for compound date types
This PR was merged into the 4.2-dev branch.
Discussion
----------
[SecurityBundle] Fix remember-me cookie framework inheritance when session is disabled
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29217
| License | MIT
| Doc PR | N/A
When `framework.session` configuration key is not an array, we ignore it.
Commits
-------
af81008cb6 [SecurityBundle] Fix remember-me cookie framework inheritance when session is disabled
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Translation] make intl+icu format seamless by handling it in MessageCatalogue
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29136
| License | MIT
| Doc PR | -
Commits
-------
c71dfb9673 [Translation] make intl+icu format seamless by handling it in MessageCatalogue
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Add handled & sent stamps
| Q | A
| ------------- | ---
| Branch? | 4.2 <!-- see below -->
| Bug fix? | no
| New feature? | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs/issues/10661
Based on #29159
This new feature marks sent and handled messages, so middleware can act upon these and use the handler(s) result(s).
This is also the base of a next PR (#29167), introducing a query bus built on top of the message bus.
I'm not sure yet about the best way to determine the handlers and senders names/descriptions to store in the stamps:
- Handlers are callable. I've just reused the [console text descriptor](1c1818b876/src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/TextDescriptor.php (L457-L491)) format for now.
- ~~Sender are `SenderInterface` instances. `\get_class` is used for now, but a single message can be sent by multiple senders, including of the same class.~~ => Updated. Yielding the sender name if provided, the FQCN otherwise.
~~Instead, what about allowing to yield names from locators, and fallback on the above strategies otherwise? So we'll use transport names from the config for senders, and pre-computed compile-time handlers descriptions?~~
=> Done. For handlers, computing it at compile time might not be straightforward. Let's compute it lazily from `HandledStamp::fromCallable()`
---
### From previous conversations:
> What about not adding HandledStamp on `null` returned from handler
IMHO, `null` still is a result. The stamps allows to identify a message as being handled regardless of the returned value, so makes sense on its own and keeping would require one less check for those wanting to consume it.
> What about adding SentStamp?
Makes sense to me and I think it was requested by @Nyholm before on Slack.
So, included in this PR.
> Should it target 4.2 or 4.3?
Targeting 4.2, because of the removal of the handler result forwarding by middleware. A userland middleware could have used this result, typically a cache middleware. Which would now require extra boring code in userland. This will simplify it and allow users to create their query bus instance until 4.3.
Commits
-------
2f5acf790a [Messenger] Add handled & sent stamps
This notation is the only way to support controllers as services in the 3.4
LTS version.
This deprecation has only a very small benefit for the Symfony codebase (the
amount of code involved is very small), but has a huge cost for the community
which cannot avoid this deprecation without dropping support for the LTS or
making crazy logic to switch routing files (as they cannot switch things
inline in YAML or XML files).
This deprecation will be delayed until a future 5.x version, when the current
LTS will be 4.4 (which supports the new notation).
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Fix collecting messages
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no-ish
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
In 4.2 there's always one dispatched message because we provide the template with a generator. Calling `{{ gen|length }}` always returns `1`
Before
![image](https://user-images.githubusercontent.com/1047696/48368788-f0028980-e6b4-11e8-91b0-54f755b9fb93.png)
After
![image](https://user-images.githubusercontent.com/1047696/48368817-0ad4fe00-e6b5-11e8-8215-54bfdb307c47.png)
Commits
-------
bfc7d94169 [Messenger] Fix collecting messages
This PR was merged into the 4.2-dev branch.
Discussion
----------
[WebProfilerBundle] Remove unused data attr
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Actually spotted in #29192 when searching in master :)
The attribute is not used.
Commits
-------
7c593753ef [WebProfilerBundle] Remove unused data attr
This PR was merged into the 4.2-dev branch.
Discussion
----------
[FrameworkBundle][WebServerBundle] Revert deprecation of --env and --no-debug console options
This reverts commit 9f60ff8a4d.
This reverts commit 31b5615b51.
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28984
| License | MIT
| Doc PR | -
Working on recipes with @weaverryan, we figured out that this deprecation is just making our life more difficult. Let's revert it.
Same as #29126, reverts #28745 and #28653
Commits
-------
443f8ad374 [FrameworkBundle][WebServerBundle] Revert deprecation of --env and --no-debug console options
This PR was merged into the 2.8 branch.
Discussion
----------
Command::addOption should allow int in $default
| Q | A
| ------------- | ---
| Branch? | all
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | none
| License | MIT
| Doc PR |
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
In #28714 the documentation for `$default` on `Command::addOption` was changed to specify more specifically than `mixed`. However, there is an inconsistency as `InputOption::__construct` allows int in its `$default`, but not `Command::addOption`. This PR makes fixes that inconsistency.
Commits
-------
5f8bd89 Command::addOption should allow int in $default
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Fix typos
| Q | A
| ------------- | ---
| Branch? | 4.2 <!-- see below -->
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Just small typos extracted from #29166 in case it doesn't make it to 4.2.
Commits
-------
7e763f96c1 [Messenger] Fix typos
This PR was merged into the 2.8 branch.
Discussion
----------
[Form] Minor fixes in docs and cs
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Commits
-------
de40f5d07b [Form] Minor fixes in docs and cs
This PR was merged into the 4.1 branch.
Discussion
----------
[Routing] generate(null) should throw an exception
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28634
| License | MIT
| Doc PR | -
Commits
-------
710aafbc91 [Routing] generate(null) should throw an exception
This PR was merged into the 4.2-dev branch.
Discussion
----------
[FrameworkBundle] conflict with Dotenv <4.2 to simplify recipes
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
In the recipe for fwb 4.2, we already assume that if dotenv is installed, it will be at v4.2 or higher.
Let's enforce this.
Commits
-------
0e80cc175f [FrameworkBundle] conflict with Dotenv <4.2 to simplify recipes
This PR was merged into the 4.2-dev branch.
Discussion
----------
Revert "bug #29154 [FrameworkBundle] Define APP_ENV/APP_DEBUG from argv via Application::bootstrapEnv()
This reverts commit 9253199de1, reversing
changes made to 664a032940.
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Replaced by https://github.com/symfony/recipes/pull/491, see description there.
Commits
-------
f3c5fda379 Revert "bug #29154 [FrameworkBundle] Define APP_ENV/APP_DEBUG from argv via Application::bootstrapEnv() (chalasr)"
* 2.8:
[Form] Fixed keeping hash of equal \DateTimeInterface on submit
[PhpUnitBridge] Fix typo
[Config] Unset key during normalization
invalidate forms on transformation failures
This PR was squashed before being merged into the 4.2-dev branch (closes#29183).
Discussion
----------
[HttpKernel] Fix collecting uploaded files
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #29178
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Commits
-------
a439681bd4 [HttpKernel] Fix collecting uploaded files
This PR was merged into the 4.1 branch.
Discussion
----------
[Workflow] Fixed bug of buildTransitionBlockerList when many transition are enabled
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28429#28432#28493
| License | MIT
| Doc PR |
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
732f343572 [Workflow] Made code simpler
db69ccc185 method buildTransitionBlockerList returns TransitionBlockerList of expected transition
The constructor for InputOption allows int on the $default parameter, but not Command::addOption $default parameter
fixup: apply coding standards patch
This PR was merged into the 3.4 branch.
Discussion
----------
[Workflow][FrameworkBundle] fixed guard event names for transitions
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28018https://github.com/symfony/symfony/pull/28007#issuecomment-40652420
| License | MIT
| Doc PR |
There is a bug when many transitions are defined with the same name.
I finished destillat's work and rebase against 3.4 as it's a bug fix.
There another point of failure, but it could not be fixed on 3.4. I will
be a need feature. The issue is related to `Workflow::can($subject, $transitionName)`.
Since the transitionName could be not unique, we will need to support
passing an instance of Transition. A new PR is incomming
Commits
-------
83dc473dd6 [FrameworkBundle] fixed guard event names for transitions
fb88bfc79a [FrameworkBundle] fixed guard event names for transitions
This PR was squashed before being merged into the 4.2-dev branch (closes#29184).
Discussion
----------
[WebProfilerBundle] Fix theme settings
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #28932#28935
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Commits
-------
8fbe85c50f [WebProfilerBundle] Fix theme settings
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] collect all stamps added on Envelope as collections
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | yes
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29156
| License | MIT
| Doc PR | -
Late small BC break for Messenger:
* `Envelope::all()` takes a new optional `$stampFqcn` argument and returns the stamps for the specified FQCN, or all stamps by their class name
* `Envelope::get()` has been renamed `Envelope::last()`
This fixes the current behavior where we replace any previous stamp with the same type, which is unexpected to me as it silently loses data and more importantly blocks interesting use cases we're going to need in the near future.
Basically, that's the same as HTTP headers being allowed to exist several times: most of them make no sense as collections, but some are really useful as collections.
Commits
-------
2e9885922a [Messenger] collect all stamps added on Envelope as collections
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Dotenv] load .env.dist when it exists and .env is not found
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29170
| License | MIT
| Doc PR | -
As illustrated in #29170, it can be useful to opt out from the `.env` convention and fall back to defining env vars in `.env.dist` instead. This PR allows that by loading `.env.dist` when it exists and `.env` is not found.
Needs https://github.com/symfony/flex/pull/434 to work seamlessly when using Flex.
Commits
-------
841185bb9f [Dotenv] load .env.dist when it exists and .env is not found
This PR was merged into the 2.8 branch.
Discussion
----------
[Form] invalidate forms on transformation failures
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #20916, #21242, #28584
| License | MIT
| Doc PR |
Commits
-------
385d9df29c invalidate forms on transformation failures
This PR was squashed before being merged into the 2.8 branch (closes#29152).
Discussion
----------
[Config] Unset key during normalization
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes-ish
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #29142
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
2.8 vs. 4.x :) let me know.
Commits
-------
e1402d495e [Config] Unset key during normalization
* 4.1:
[Form] Hardened test suite for empty data
Bump phpunit XSD version to 5.2
[Fwb][EventDispatcher][HttpKernel] Fix getClosureScopeClass usage to describe callables
Add required key attribute
* 3.4:
[Form] Hardened test suite for empty data
Bump phpunit XSD version to 5.2
[Fwb][EventDispatcher][HttpKernel] Fix getClosureScopeClass usage to describe callables
Add required key attribute
This PR was merged into the 2.8 branch.
Discussion
----------
Bump phpunit XSD version to 5.2
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Some attributes being used in the phpunit configuration files, namely
`failOnRisky` and `failOnWarning` were introduced in phpunit 5.2.0. The
Composer configuration shows that tests should run with old versions of
phpunit, but phpunit only validates the configuration against the XSD
since phpunit 7.2.0
These changes can be tested as follows:
```
wget http://schema.phpunit.de/5.2/phpunit.xsd
xargs xmllint --schema phpunit.xsd 1>/dev/null
find src -name phpunit.xml.dist| xargs xmllint --schema phpunit.xsd 1>/dev/null
```
See 7e06a82806
See 46e3745a03/composer.json (L98)
Commits
-------
4dce4b7c30 Bump phpunit XSD version to 5.2
Some attributes being used in the phpunit configuration files, namely
failOnRisky and failOnWarning were introduced in phpunit 5.2.0. The
Composer configuration shows that tests should run with old versions of
phpunit, but phpunit only validates the configuration against the XSD
since phpunit 7.2.0.
These changes can be tested as follows:
wget http://schema.phpunit.de/5.2/phpunit.xsd
xargs xmllint --schema phpunit.xsd 1>/dev/null
find src -name phpunit.xml.dist| xargs xmllint --schema phpunit.xsd 1>/dev/null
See 7e06a82806
See 46e3745a03/composer.json (L98)
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Dotenv] add loadEnv(), a smoother alternative to loadForEnv()
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | yes (4.2-only)
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This PR replaces the `loadForEnv()` method introduced in #28533 by a new `loadEnv()` method.
- It accepts only one mandatory argument: `$path`, which is the path to the `.env` file.
- The 2nd argument is optional and defines the name of the environment variable that defines the Symfony env. This plays better with the current practice of defining the env in `.env` (`loadForEnv()` requires knowing the env before being called, leading to a chicken-n-egg situation that `loadEnv()` avoids.)
- the possibility to load several files at once is removed. We don't have a use case for it and those who do can call `loadEnv()` in a loop anyway.
In addition to $path (.env), the following files are loaded, the latter taking precedence in this order:
.env < env.local < .env.$env < .env.$env.local
Note that `loadForEnv()` used to give higher precedence to .env.local vs .env.$env.
The new behavior is aligned with [the order used by create-react-app](https://github.com/facebook/create-react-app/blob/master/docusaurus/docs/adding-custom-environment-variables.md#what-other-env-files-can-be-used). It also allows overriding the env in .env.local, which should be convenient for DX.
Last but not least, the "test" env has this special behaviors:
- `.env.local` file is skipped for the "test" env (same as before and as in create-react-app)
- ~vars defined in .env files **override** real env vars (similar to what Rails' dotenv does: you don't want your tests to randomly fail because of some real env vars)~.
Commits
-------
0cf9acb70f [Dotenv] add loadEnv(), a smoother alternative to loadForEnv()
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Routing] fix dumping conditions that use the request
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29106
| License | MIT
| Doc PR | -
Commits
-------
09d5be8dac [Routing] fix dumping conditions that use the request
* 4.1:
Change button_widget class to btn-primary
[Serializer] Allow null values when denormalizing with constructor missing data
[Dotenv] dont use getenv() to read SYMFONY_DOTENV_VARS
[HttpFoundation] Fixed PHP doc of ParameterBag::getBoolean
[HttpFoundation] replace any preexisting Content-Type headers
* 3.4:
Change button_widget class to btn-primary
[Dotenv] dont use getenv() to read SYMFONY_DOTENV_VARS
[HttpFoundation] Fixed PHP doc of ParameterBag::getBoolean
[HttpFoundation] replace any preexisting Content-Type headers
This PR was merged into the 3.4 branch.
Discussion
----------
[Dotenv] dont use getenv() to read SYMFONY_DOTENV_VARS
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Since using it is not thread safe, let's not rely on it (already done in other places.)
Commits
-------
21a909a189 [Dotenv] dont use getenv() to read SYMFONY_DOTENV_VARS
This PR was squashed before being merged into the 4.1 branch (closes#29076).
Discussion
----------
[Serializer] Allow null values when denormalizing with constructor missing data
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
When using `default_constructor_arguments` to denormalize objects, `null` values for a parameter weren't processed, so instantiating was failing.
Commits
-------
5fd0f3f453 [Serializer] Allow null values when denormalizing with constructor missing data
* 4.1:
[VarDumper] fix dump of closures created from callables
[DI] fix dumping inlined services
Add framework asset changes to upgrade 3.0 guide
[Travis] Bump ext-mongodb to 1.5.2 on Travis
[DI] dont track classes/interfaces used to compute autowiring error messages
[DI] fix GraphvizDumper ignoring inline definitions
bumped Symfony version to 4.1.8
updated VERSION for 4.1.7
updated CHANGELOG for 4.1.7
bumped Symfony version to 3.4.19
updated VERSION for 3.4.18
updated CHANGELOG for 3.4.18
bumped Symfony version to 2.8.48
updated VERSION for 2.8.47
update CONTRIBUTORS for 2.8.47
updated CHANGELOG for 2.8.47
Fix ini_get() for boolean values
* 3.4:
[VarDumper] fix dump of closures created from callables
[DI] fix dumping inlined services
Add framework asset changes to upgrade 3.0 guide
[Travis] Bump ext-mongodb to 1.5.2 on Travis
[DI] dont track classes/interfaces used to compute autowiring error messages
[DI] fix GraphvizDumper ignoring inline definitions
bumped Symfony version to 3.4.19
updated VERSION for 3.4.18
updated CHANGELOG for 3.4.18
bumped Symfony version to 2.8.48
updated VERSION for 2.8.47
update CONTRIBUTORS for 2.8.47
updated CHANGELOG for 2.8.47
Fix ini_get() for boolean values
This PR was merged into the 3.4 branch.
Discussion
----------
[DI] fix dumping inlined services
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28824#29078
| License | MIT
| Doc PR | -
Same as #29103 but for 3.4.
This PR dump inline services using the call-stack to sort the code for instantiating them.
This makes easier to follow and matches the behavior one would expect (and has when using `ContainerBuiler` directly to create services.)
Commits
-------
a97606d58a [DI] fix dumping inlined services
This PR was merged into the 3.4 branch.
Discussion
----------
[VarDumper] fix dump of closures created from callables
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
We are missing displaying full information about closures created using `ReflectionMethod::getClosure()` or `Closure::fromCallable()`.
This PR fixes it. For VarDumper but also other places where we have logic to display them.
Commits
-------
1c1818b876 [VarDumper] fix dump of closures created from callables
This PR was merged into the 3.4 branch.
Discussion
----------
[DI] fix GraphvizDumper ignoring inline definitions
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Since SF3, inline definitions are first class citizen. I noticed that the GraphvizDumper does not inspect them. Here is the fix.
Commits
-------
ebe6265504 [DI] fix GraphvizDumper ignoring inline definitions
This PR was merged into the 4.2-dev branch.
Discussion
----------
LoggingTranslator should implement Symfony\Contracts\Translation\TranslatorInterface
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #29089
| License | MIT
While autowiring Translator using `Symfony\Contracts\Translation\TranslatorInterface` symfony complains that wrong service was injected, because LoggingTranslator does not implement new interface.
Commits
-------
65f321f6c9 LoggingTranslator should implement Symfony\Contracts\Translation\TranslatorInterface
This PR was squashed before being merged into the 4.2-dev branch (closes#29100).
Discussion
----------
[Messenger] Cleaning after new changes
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
See topic per commit
Commits
-------
3d31772949 [Messenger] Cleaning after new changes
This PR was merged into the 4.2-dev branch.
Discussion
----------
[FrameworkBundle][4.2] fix deps
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
The bundle requires the `MetadataAwareNameConverter` added in 4.2
1fc577f2c7/src/Symfony/Bundle/FrameworkBundle/Resources/config/serializer.xml (L122-L124)
This PR fixes
```
Attempted to load interface "AdvancedNameConverterInterface" from namespace "Symfony\Component\Serializer\NameConverter".
Did you forget a "use" statement for another namespace?
```
Commits
-------
71fe97a7ab [FrameworkBundle][4.2] fix deps
This PR was squashed before being merged into the 4.2-dev branch (closes#29062).
Discussion
----------
Fix GlobResource serialization
| Q | A
| ------------- | ---
| Branch? | master <!-- see below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | no <!-- please add some, will be required by reviewers -->
| Fixed tickets | #28200 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | <!-- required for new features -->
Since @gonzalovilaseca improvement in PR #28200, I noticed that the container is being compiled systematically. This is caused by the two added properties (`forExclusion`, `excludedPrefixes`) not being serialized, and lead to wrong hash computing. I updated the `serialize` and `unserialize` methods in this PR.
ping @nicolas-grekas
Commits
-------
6ce7f07439 Fix GlobResource serialization
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] make senders/handlers locator accept envelopes
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
As suggested by @Tobion in https://github.com/symfony/symfony/pull/29045#issuecomment-434906250 - works for me also.
Commits
-------
9cd88b0dc5 [Messenger] make senders/handlers locator accept envelopes
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] extract stamp header prefix into private const
| Q | A
| ------------- | ---
| Branch? | master f
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR |
Commits
-------
564cf3d156 [Messenger] extract stamp header prefix into private const
This PR was merged into the 4.2-dev branch.
Discussion
----------
Revert "[HttpFoundation] Adds getAcceptableFormats() method for Request"
This reverts commit 8a127ea34a.
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26486
| License | MIT
| Doc PR |
As I said in https://github.com/symfony/symfony/pull/26486#discussion_r228697658 and people wonder in https://symfony.com/blog/new-in-symfony-4-2-acceptable-request-formats#comment-22747, I don't think this method clear and generic enough to be added to the core.
I can't see where I would possibly use this method. What would be useful is a similar method that accepts formats as argument and would return the ones that are acceptable according to the accept header. This would then allow to make use of `*/*` and this is what people usually need in REST APIs etc.
But for now, we should revert it before it gets released like this.
Commits
-------
397ed83c3c Revert "[HttpFoundation] Adds getAcceptableFormats() method for Request"
This PR was merged into the 3.4 branch.
Discussion
----------
[DependencyInjection] Fix tags on multiple decorated service
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28682
| License | MIT
| Doc PR |
After the first run in the loop with the same decorated service it goes only in the hasAlias condition. The tags will be not set here, so the `ResolveTaggedIteratorArgumentPass` will handle only the first decoration.
Commits
-------
90f8df2830 [DependencyInjection] Fix tags on multiple decorated service
This PR was merged into the 4.1 branch.
Discussion
----------
SCA: simplify some ifs in favour of null coalescing operator
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Some of ifs were replaced with null coalescing operator in order to simplify control flow.
Commits
-------
636a872389 SCA: reverted code style changes
c926b1abd3 SCA: reverted code style changes
300b31fa75 SCA: applied requested code style changes
0180cb936f SCA: simplify some ifs in favour of null coalescing operator
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Cache] allow to skip saving the computed value when using CacheInterface::get()
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
While trying to play with using Messenger and Cache together, I spotted a few issues related to the new `CacheInterface::get()` method:
- there must be a way to skip saving the computed value in the pool. This is needed in my (still local WIP) use case - and is also needed for `LockRegistry`: processes that wait for the lock to be released should not write the value back when the lock is over. This is addressed by adding a 2nd `bool &$save` argument to the computing callback. When the callback sets this reference to true, the returned value should not be written to the pool.
- in order to better document the signature of this callback, a new `CallbackInterface` is added in the `Contracts\Cache` namespace. This will help autocompletion and implementations.
- `ContractsTrait` was writing twice the value to the pool - now fixed
- `LockRegistry` did not retry locking when a waiting process wasn't able to fetch the fresh value - now fixed.
Commits
-------
321d7f4be0 [Cache] allow to skip saving the computed value when using CacheInterface::get()
This PR was merged into the 2.8 branch.
Discussion
----------
Fix ini_get() for boolean values
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Currently setting `false` or `off`, ... value to configure some PHP ini directives will make this evaluated to `true` as this is equal to a non empty string.
Commits
-------
a1538696c3 Fix ini_get() for boolean values
* 4.1:
SCA: removed unused variables
Remove duplicate condition
fix useless space in docblock
remove unneeded tearDown method
[Intl] Update the ICU data to 63.1
[FrameworkBundle] Fix broken exception message
[Messenger] send using the routing_key for AMQP transport
also clean away the NO_AUTO_CACHE_CONTROL_HEADER if we have no session
[TwigBundle] Fix usage of TwigBundle without FrameworkBundle
Revert "fixed CS"
[Serializer] Reduce class discriminator overhead
Skip empty proxy code
[Security] Fix "exclude-from-classmap"
[Security] Removed unsed trait import
[Config] Fix @method annotation
add missing double-quotes to extra_fields output message
[DI] Default undefined env to empty string during compile
Convert InsufficientAuthenticationException to HttpException
This PR was merged into the 2.8 branch.
Discussion
----------
Revert "fixed CS"
This reverts commit d48a3776fe.
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | n/a
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
This PR reverts #28814 , that was caused as a bug of PHP CS Fixer fixed in https://github.com/FriendsOfPHP/PHP-CS-Fixer/pull/4027
After fix on PHP CS Fixer side, the rule is passing now at Symfony's codebase.
This PR only reverts wrong chances done by PHP CS Fixer,
it does not apply new rule requested in #28817 ( https://github.com/FriendsOfPHP/PHP-CS-Fixer/issues/4045 )
Commits
-------
6f83d9f9a3 Revert "fixed CS"
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] make TraceableMiddleware decorate a StackInterface instead of each middleware to free the callstack from noisy frames
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Right now, `TraceableMiddleware` works as a middleware decorator for the "handle" method. It means that *each middleware* frame in the call stack is wrapped between two noisy extra frames.
This is something we can remove by decorating the StackInterface instead: let's just stop/start events when the next middleware is fetched.
Thanks to this, only one frame *per bus* is added to measure middleware timings.
Commits
-------
73c8c23c79 [Messenger] make TraceableMiddleware decorate a StackInterface instead of each middleware to free the callstack from noisy frames
This PR was merged into the 2.8 branch.
Discussion
----------
[HTTP Foundtation] Fix useless space in docblock
I Just removed a useless space in PHP Doc, I don't know if target the 2.8 branch is enough to others SF versions
Commits
-------
6ba75734d6 fix useless space in docblock
This PR was merged into the 4.2-dev branch.
Discussion
----------
[VarExporter] Cleanup unused var
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
d254004c26 [VarExporter] Cleanup unused var
This PR was merged into the 4.2-dev branch.
Discussion
----------
[FrameworkBundle] make debug:autowiring list useful services and their description
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27207
| License | MIT
| Doc PR | -
This PR closes#27207: we don't need "semantics" anymore. 4.2 has everything already to allow us to separate useful services from the other ones: any autowireable *alias* **is** a useful service!
Add autowiring by type + parameter name (#28234) and the story is done: we can easily hint people about which features their bundles provide, without being polluted by for-wiring-only services.
Here is a screenshot running this command(before I excluded the aliases for $cacheApp and $cacheSystem):
![image 3](https://user-images.githubusercontent.com/243674/47437006-f41f4380-d7a7-11e8-9f76-7f23e9193ce8.png)
ping @weaverryan as we drafted that together.
Fixes a few issues found meanwhile.
That should definitely go in 4.2.
Commits
-------
56aab09b01 [FrameworkBundle] make debug:autowiring list useful services and their description
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Translation] allow using the ICU message format using domains with the "+intl-icu" suffix
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | yes
| BC breaks? | no (unless merged after 4.2)
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This PR replaces the `FallbackFormatter` logic by explicit opt-in.
This allows triggering accurate exceptions when one wants to use the ICU message format but the extension (or the polyfill) is missing.
The way to opt-in is to put messages in a domain with the `+intl-icu` suffix *at loading/declaration time*.
E.g. translations in `messages+intl-icu.en.yaml` will be read as part of the `messages` domain , but will be parsed by intl's `MessageFormatter` instead of the default Symfony one.
To make it seamless to adopt the ICU format, `%`s are trimmed from parameter keys (idea borrowed from https://github.com/webfactory/WebfactoryIcuTranslationBundle)
This is for 4.2 as it changes a feature that is not released yet.
ping @Nyholm - we drafted this together.
Commits
-------
d95cc4d4c6 [Translation] allow using the ICU message format using domains with the "+intl-icu" suffix
This PR was merged into the 4.2-dev branch.
Discussion
----------
[BrowserKit] Remove undefined variable $str
| Q | A
| ------------- | ---
| Branch? | master <!-- see below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | no <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | no <!-- required for new features -->
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
4b3fdd60d1 [BrowserKit] Remove undefined variable
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Move MiddlewareTestCase in Test ns
| Q | A
| ------------- | ---
| Branch? | master <!-- see below -->
| Bug fix? | no
| New feature? | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes (AppVeyor failure unrelated) <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Just a quick suggestion after #28943 being merged. Wouldn't it make sense to move this in `Test` namespace to be used by anyone wanting to unit test their middleware?
Commits
-------
215c895a55 [Messenger] Move MiddlewareTestCase in Test ns
This PR was merged into the 4.2-dev branch.
Discussion
----------
[FrameworkBundle] Deprecate support for legacy directories in Translation comands
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | todo
Commits
-------
a7a8aad46f [FrameworkBundle] Deprecate support for legacy translations and views directories
This PR was merged into the 4.2-dev branch.
Discussion
----------
[VarDumper] Scroll into view when searching
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
This jumps to the found element when using the javascript widget for searching HTML dumps. Inspired by Ctrl+F in Chrome :)
It's super convenient with long dumps, however i wasnt able to position the search input on the right in a fixed manner... because CSS 😓 i was hoping @ogizanagi could add a patch for it.
Also see https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollIntoView
Commits
-------
647a937abc [VarDumper] Scroll into view when searching
This PR was merged into the 4.2-dev branch.
Discussion
----------
Remove reference to http digest authentication
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | <!-- required for new features -->
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Seeing as HTTP Digest has been deprecated / removed, the README shouldn't be advertising it as a feature.
This is especially important seeing as sites such as packagist display the README to advertise the features/usage of a package. See https://packagist.org/packages/symfony/security
Commits
-------
9702a212e2 Remove reference to http digest authentication
This PR was merged into the 4.2-dev branch.
Discussion
----------
[DotEnv] Add a new loadForEnv() method mimicking Ruby's dotenv behavior
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? |no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | helps for symfony/recipes#465, symfony/recipes#408
| License | MIT
| Doc PR | todo
This PR adds a new `loadForEnv()` method that mimics the behavior of [Create React App](https://github.com/facebook/create-react-app/blob/master/packages/react-scripts/template/README.md#what-other-env-files-can-be-used), [Rails' DotEnv](https://github.com/bkeepers/dotenv#what-other-env-files-can-i-use) and probably some other libs:
`DotEnv::loadForEnv()` will load the following files, starting from the bottom. The first value set (or those already defined in the environment) take precedence:
- `.env` - The Original®
- `.env.dev`, `.env.test`, `.env.prod`... - Environment-specific settings.
- `.env.local` - Local overrides. This file is loaded for all environments _except_ `test`.
- `.env.dev.local`, `.env.test.local`, `.env.prod.local`... - Local overrides of environment-specific settings.
The plan is to use this method in the default SF installation (symfony/recipes#466).
Commits
-------
774a78c8de [DotEnv] Add a new loadForEnv() method mimicking Ruby's dotenv behavior
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Add `StackInterface`, allowing to unstack the call stack
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
At the moment, debugging an exception coming from a middleware is not as friendly as it could: each middleware is preceded by a noisy frame added by the `$next` callable indirection.
This PR allows removing this frame by using `$next()->handle($envelope, $next);` instead of `$next($envelope);` in a middleware. Note that this is optional so that the later continues to work. But if one wants to opt-in for the former, then the stack trace of exceptions will be freed from `$next`.
All core middleware should do this, so here they are, updated.
Commits
-------
2bc7d11ad3 [Messenger] Add `StackInterface`, allowing to unstack the call stack
This PR was merged into the 4.2-dev branch.
Discussion
----------
[TwigBridge] Remove $rootDir argument in CodeExtension
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | https://github.com/symfony/symfony-docs/pull/10547#issuecomment-432608538
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Forgotten in #28890
cc @javiereguiluz
Commits
-------
f8947242a9 [TwigBridge] Remove $rootDir argument in CodeExtension
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] If `framework.messenger.buses.X.middleware` is empty, it will be `null`
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28945
| License | MIT
| Doc PR | ø
Otherwise, it would fail with the following configuration:
```yaml
framework:
messenger:
buses:
events_bus:
middleware:
# - 'some_commented_middleware'
```
Commits
-------
91a70fcd6f If `framework.messenger.buses.X.middleware` is empty, it will be `null`
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Form] Deprecate TimezoneType regions option
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | yes
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #28848
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
I know i've added this option myself in 4.1, but given my recent development for #28624 i realized it's an opinionated feaure, which can/should be solved on user-side (`choice_filter/choice_loader` and/or `group_by`).
- blocks translations as we dont have them (see #28831)
- blocks possibility of switching to Intl zones which doesnt really have this filter feature (see #28836)
~While at it, i solved a few issues with `OptionsResolver` that is able to deprecate options as of 4.2 also.~ Fixed in #28878
- when resolved trigger the deprecation
- allow to opt-out from triggering the deprecation
- dont trigger deprecation for default values (only given ones)
Commits
-------
5cb532d2de [Form] Deprecate TimezoneType regions option
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] remove classifying sub-namespaces in favor of semantic ones
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
While working on the component, I found it hard to discover the meaning of the `Asynchronous` and `Enhancers` sub-namespaces. Now that I know the component better, I understand they're only classifying namespaces with no specific technical semantics.
I'd like to remove them to make the component easier to discover.
This PR introduces a few new semantic sub-namespaces instead.
From the changelog:
* Classes in the `Middleware\Enhancers` sub-namespace have been moved to the `Middleware` one
* Classes in the `Asynchronous\Routing` sub-namespace have been moved to the `Transport\Sender\Locator` sub-namespace
* The `Asynchronous/Middleware/SendMessageMiddleware` class has been moved to the `Middleware` namespace
* `SenderInterface` and `ChainSender` classes have been moved to the `Transport\Sender` sub-namespace
* `ReceiverInterface` and its implementations have been moved to the `Transport\Receiver` sub-namespace
Commits
-------
16afb5e2b4 [Messenger] remove classifying sub-namespaces in favor of semantic ones
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Process] pass all output to the wait-until callback
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? |
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Introduced yesterday, my bad.
Should make appveyor green hopefully.
Commits
-------
a320133b1d [Process] pass all output to the wait-until callback
This PR was squashed before being merged into the 4.2-dev branch (closes#28875).
Discussion
----------
[FWBundle] Add a new method AbstractController::addLink()
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? |no
| New feature? | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | todo
This provides a convenient method to add `Link` headers to the current `Response` directly from the `Request` object.
It improves the developer experience and the discoverability of [the WebLink component](https://github.com/symfony/symfony-docs/pull/10309).
Usage:
```php
namespace App\Controller;
use Fig\Link\Link;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
class MyAction extends AbstractController
{
public function __invoke(Request $request): Response
{
$this->addLink($request, new Link('mercure', 'https://demo.mercure.rocks'));
return $this->json(['foo' => 'bar']);
}
}
```
Commits
-------
4d20c39f70 [FWBundle] Add a new method AbstractController::addLink()
This PR was merged into the 4.2-dev branch.
Discussion
----------
[OptionsResolver] Trigger deprecation only if the option is used
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28848
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10496
It's true that showing a deprecation message when the option is not used is a bit annoying and it would be heavy to get rid of it.
Now, a deprecated option is triggered only when it's provided by the user or each time is being called from a lazy evaluation (except for deprecations based on the value, they're triggered only when provided by the user).
Commits
-------
1af23c9a74 [OptionsResolver] Trigger deprecation only if the option is used
This PR was squashed before being merged into the 4.2-dev branch (closes#28940).
Discussion
----------
[Process] Adds usleep(1000) to ease CPU usage.
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR | symfony/symfony-docs
Commits
-------
9d1416ad82 [Process] Adds usleep(1000) to ease CPU usage.
This PR was squashed before being merged into the 4.2-dev branch (closes#28737).
Discussion
----------
[DependencyInjection] Optimize exporting variables
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28292
| License | MIT
Store previously resolved variables so that the relatively expensive function [resolveEnvPlaceholders](3e7b029524/src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php (L1776)) is not called unnecessarily.
The effect on running ```bin/console``` with an empty cache in a big application (200+ env variables) in seconds:
| Before | After |
|------------|------------|
| 24.1 | 15.8 |
| 24.5 | 16.0 |
| 24.7 | 16.3 |
| 24.2 | 16.0 |
| Avg: 24.4 | Avg:16.0 |
Commits
-------
768de2f7d9 [DependencyInjection] Optimize exporting variables
This PR was squashed before being merged into the 4.2-dev branch (closes#28200).
Discussion
----------
[Config] Fix slow service discovery for large excluded directories
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | #26736
| License | MIT
| Doc PR |
Not sure if this is a bug fix or not, is more an improvement.
Please for all detail follow the conversation here:
https://github.com/symfony/symfony/issues/26736
Commits
-------
fa731e53e9 [Config] Fix slow service discovery for large excluded directories
This PR was squashed before being merged into the 4.2-dev branch (closes#28709).
Discussion
----------
[Serializer] Refactor and uniformize the config by introducing a default context
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | yes <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | todo <!-- required for new features -->
This PR uniformizes how the Serializer's configuration is handled:
* As currently, configuration options can be set using the context (options that weren't configurable using the context have been refactored to leverage it)
* Normalizers and encoders' constructors now accept a "default context"
* All existing global configuration flags (constructor parameters) have been deprecated in favor of this new default context
* the stateless context is always tried first, then is the default context
Some examples:
```php
// Configuring groups globally
// Before: not possible
// After
$normalizer = new ObjectNormalizer(/* deps */, ['groups' => 'the_default_group']);
// Escaping Excel-like formulas in CSV files
// Before
$encoder = new CsvEncoder(',', '"', '\\', '.', true);
// After
$encoder = new CsvEncoder(['csv_escape_formulas' => true]);
$encoder->normalize($data, 'csv', ['csv_escape_formulas' => false]); // Override for this call only
```
Benefits:
* The DX is dramatically improved, configuration is always handled in similar way
* The serializer can be used in fully stateless way
* Every options can be configured globally
* Classes that had constructors with a lot of parameters (like `CsvEncoder`) are now much easier to use
* We'll be able to improve the documentation by adding a dictionary of all available context options for the whole component
* Everything can be configured the same way
TODO in subsequent PRs:
* Add a new option in framework bundle to configure the context globally
* Uniformize the constants name (sometimes the name if `FOO`, sometimes `FOO_KEY`)
* Fix the "bug" regarding the format configuration in `DateTimeNormalizer::denormalize()` (see comments)
* Maybe: move `$defaultContext` as the first parameter (before required services?)
* Make `XmlEncoder` stateless
Commits
-------
52b186a210 [Serializer] Refactor and uniformize the config by introducing a default context
This PR was merged into the 4.2-dev branch.
Discussion
----------
[HttpFoundation] Merging arrays in a loop is slow and causes high CPU usage
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
As described here, https://github.com/kalessil/phpinspectionsea/blob/master/docs/performance.md#slow-array-function-used-in-loop, merging arrays in a loop is slow and causes high CPU usage (benchmarks are also on the link), this pull request solves this problem
Commits
-------
3db84789f2 Merging arrays in a loop is slow and causes high CPU usage
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] internal cleanups
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
From the updated changelog:
* `MessengerDataCollector::getMessages()` returns an iterable, not just an array anymore
* `AbstractHandlerLocator` is now internal
* `HandlerLocatorInterface::resolve()` has been replaced by `getHandler(Envelope $envelope)`
* `SenderLocatorInterface::getSenderForMessage()` has been replaced by `getSender(Envelope $envelope)`
* `SenderInterface::send()` returns `void`
+ some internal simplifications
Commits
-------
4a3edd0b37 [Messenger] internal cleanups
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] made dispatch() and handle() return void
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Middlewares and dispatchers should not return any value. Forwarding back the results from handlers breaks the scope of the component. The canonical example of some bad design this can lead to is `ChainHandler`: how can the caller know that there is one in the chain and that it should expect an array as a return value? More generally, how can a caller know what to expect back from a call to dispatch()? I think we should not allow such broken designs.
Instead, we should favor east-oriented design: if one needs a command bus, one would have to dispatch a proper command object - and if a result is expected back, it should be done via a setter on the dispatched command - or better, a callback set on the command object. This way we play *by the rules* of the type-system, not against.
Commits
-------
f942ffcb1b [Messenger] made dispatch() and handle() return void
This PR was merged into the 4.2-dev branch.
Discussion
----------
Fix debug:container which crash when the service class has no doc comment
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
The console command container:debug have now the ability to display service description, based on phpdoc comments of the service class. But the command currently crash when selecting a service with a class without phpdoc description.
This PR fixes this issue.
Commits
-------
aed0a5a38a [FrameworkBundle] Fix debug:container which crash when the service class has no doc comment
This PR was merged into the 4.2-dev branch.
Discussion
----------
[TwigBundle] Deprecating support for legacy templates directories
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10500
go ahead with https://github.com/symfony/symfony/pull/28810#issuecomment-430245394
- [x] Fix tests
Commits
-------
8b390f346f Deprecating support for legacy templates directories
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Serializer] fix MetadataAwareNameConverter break denormalization
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
During denormalization of an object, the `normalize` function of the `MetadataAwareNormalizer` is called to find the serialized name of constructor arguments. This do not work if the constructor argument is not in the serialized representation of the object (for example given with a `default_constructor_arguments` option ).
**Checklist**
- [x] Add test to cover the bug
Commits
-------
faf8b009dc [Serializer] fix MetadataAwareNameConverter break denormalization
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] rename "envelope items" and move them in the "Stamp" namespace
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Right now, envelope items are scattered in different sub namespaces and use the "Configuration" suffix.
This makes them hard to discover.
This PR creates a new `Stamp` namespace and moves all "envelope items" there, renaming them to use the "stamp" terminology.
From the changelog:
* `Envelope`'s constructor and `with` method now accept `StampInterface` objects as variadic parameters
* Renamed `EnvelopeItemInterface` to `StampInterface`
* Renamed and moved `ReceivedMessage`, `ValidationConfiguration` and `SerializerConfiguration` in the `Stamp` namespace
* Removed the `WrapIntoReceivedMessage` (it's untested and unused)
Commits
-------
0ad2cb906d [Messenger] rename "envelope items" and move them in the "Stamp" namespace
The "/Tests/" directory doesn't exist in the Security Component, tests are located within the Security components folders and none of the tests were being excluded in an --classmap-authoritative dump of the autoload.
This PR was squashed before being merged into the 4.2-dev branch (closes#28916).
Discussion
----------
[Form] Fix @method annotation
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Same as #28915 for 4.2 (these are the only occurrences for interfaces)
Actually provides a use case for https://github.com/symfony/symfony/pull/28902#issuecomment-430904459🎉
Commits
-------
13f0db718e [Form] Fix @method annotation
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Cache] Fix outdated CHANGELOG line
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Unless it was kept on purpose, for `Symfony\Contracts\Cache\CacheInterface` discoverability? In which case I'd add the FQCN.
Commits
-------
4e89a4bc03 [Cache] Fix outdated CHANGELOG line
This PR was merged into the 2.8 branch.
Discussion
----------
Convert InsufficientAuthenticationException to HttpException with 401 status code
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed ticket | #8467
| License | MIT
I was trying to implement the `json_login` authentication and test it with an API Platform project. When I call a secured endpoint without authentication, an InsufficientAuthenticationException is thrown with a 500 status code instead of a 401.
After some researches with @dunglas, there is no default `entrypoint` on the security firewall. As one already exists for `form_login` in the FormLoginFactory, this component might need a default one to convert this 500 exception to a correct 401 HTTP error.
This fixes https://github.com/symfony/symfony/issues/25806#issuecomment-368461952.
Commits
-------
4503ac8e9f Convert InsufficientAuthenticationException to HttpException
This PR was squashed before being merged into the 2.8 branch (closes#28840).
Discussion
----------
add missing double-quotes to extra_fields output message
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
When using the extra_fields_message option on FormTypes to include the extra_fields items in the message, the output included some superfluous (or, perhaps, missing?) quotes. This resulted in some strange output: `This form should not contain extra fields: notes1\", \"notes2\", \"notes3`.
This PR removes the quotes and instead implodes the extra_fields array using merely ', ' as the glue, resulting in the output: `This form should not contain extra fields: notes1, notes2, notes3`.
Commits
-------
9e7414159c add missing double-quotes to extra_fields output message
This PR was merged into the 4.2-dev branch.
Discussion
----------
[HttpKernel] Introduce KernelInterface::getProjectDir()
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | not yet
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | https://github.com/symfony/symfony/pull/28897#issuecomment-430523336
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Removes the last call to getParameter('kernel.project_dir') during runtime in core. Yay :)
cc @fabpot @nicolas-grekas
Commits
-------
b046f414e7 [HttpKernel] Introduce KernelInterface::getProjectDir()
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Form][TwigBridge] Add help_attr
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Add help_attr to the form_help method.
Commits
-------
42d54b73c3 Add help_attr
This PR was squashed before being merged into the 4.1 branch (closes#28838).
Discussion
----------
[DI] Default undefined env to empty string during compile
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #28827
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Instead of using `null` for undefined envs, use `""` instead. We already default the type to string, so actually providing a string value makes sense. During runtime it will always be string also.
Commits
-------
38a8ab92fa [DI] Default undefined env to empty string during compile
* 4.1:
[FWBundle] Uniformize errors when a component is missing
Fixes 28816 Translation commands should not talk about the old app/ directory since 3.4
* 3.4:
[FWBundle] Uniformize errors when a component is missing
Fixes 28816 Translation commands should not talk about the old app/ directory since 3.4
This PR was merged into the 3.4 branch.
Discussion
----------
Translation commands should not tell about the old app/ directory
Fixes#28816 Translation commands should not talk about the old "app/" directory since 3.4
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28816
| License | MIT
| Doc PR | n/a
Commits
-------
5fcc0b4d8d Fixes 28816 Translation commands should not talk about the old app/ directory since 3.4
This PR was merged into the 4.2-dev branch.
Discussion
----------
[HttpKernel] Deprecate the Kernel name
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | yes <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26904
| License | MIT
| Doc PR | n/a
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
98ff750ee1 [HttpKernel] deprecated the Kernel name
This PR was merged into the 4.2-dev branch.
Discussion
----------
[HttpFoundation] Make ResponseHeaderBag::makeDisposition static
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes-ish
| BC breaks? | no
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes
| Fixed tickets | #27851
| License | MIT
| Doc PR | n/a
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
d29b410262 [HttpFoundation] made ResponseHeaderBag::makeDisposition static
This PR was merged into the 3.4 branch.
Discussion
----------
[FWBundle] Uniformize errors when a component is missing
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commits
-------
fa3da4e72c [FWBundle] Uniformize errors when a component is missing
* 4.1:
Remove Process::escapeArgument argument type hint
[Console] fix test using deprecated code
[travis] build libsodium only if it's not already enabled
Add a test case for stringifying of Process arguments
Add a missing English translation
[Console] Fixes multiselect choice question in interactive mode with default values
[Validator] Add a missing Polish translation
Allow integers as default console option value
Setting missing default paths under BC layer
Changed "epost-adress" to "e-postadress"
Fix for race condition in console output stream write
reverse transform RFC 3339 formatted dates
* 3.4:
[Console] fix test using deprecated code
[travis] build libsodium only if it's not already enabled
Add a test case for stringifying of Process arguments
Add a missing English translation
[Console] Fixes multiselect choice question in interactive mode with default values
[Validator] Add a missing Polish translation
Allow integers as default console option value
Setting missing default paths under BC layer
Changed "epost-adress" to "e-postadress"
Fix for race condition in console output stream write
reverse transform RFC 3339 formatted dates
This PR was merged into the 3.4 branch.
Discussion
----------
[Process] A test case for stringifying of Process arguments
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | for https://github.com/symfony/symfony/pull/28863
| License | MIT
| Doc PR |
Checks that non-string arguments passed to Process constructor are typecasted to string
Commits
-------
0d543428ad Add a test case for stringifying of Process arguments
* 2.8:
Add a missing English translation
[Console] Fixes multiselect choice question in interactive mode with default values
[Validator] Add a missing Polish translation
Allow integers as default console option value
Changed "epost-adress" to "e-postadress"
Fix for race condition in console output stream write
reverse transform RFC 3339 formatted dates
This PR was merged into the 2.8 branch.
Discussion
----------
[Form] reverse transform RFC 3339 formatted dates
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28699
| License | MIT
| Doc PR |
Technically, dates formatted according to the HTML specifications do not
contain any timezone information. But since our DateTimeType used to
contain this information in the passed, users had configure their JS
libraries to accept (and create) dates in that format.
To not break BC we should accept these dates and silently ignore the
additional timezone information.
Commits
-------
503239f75e reverse transform RFC 3339 formatted dates
This PR was merged into the 2.8 branch.
Discussion
----------
Fix for race condition in console output stream write
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
In high throughput environments writing `message` and `PHP_EOL` separately causes race condition issues, where messages might be written in order
- message
- message
- EOL
- EOL
instead of
- message
- EOL
- message
- EOL
An example below is a laravel application log tail of queue workers (multiple app instances writing to the same log file) handled by supervisor.
Before:
![ezgif-1-77388f9210cf](https://user-images.githubusercontent.com/2752769/46792349-bec13180-cd75-11e8-8f91-92f05762f964.gif)
After:
![ezgif-1-0b839d642644](https://user-images.githubusercontent.com/2752769/46792420-e617fe80-cd75-11e8-9414-4bfc85d9c569.gif)
Commits
-------
428dea6fb1 Fix for race condition in console output stream write
This PR was merged into the 4.2-dev branch.
Discussion
----------
Revert "feature #27801 [MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors"
This reverts commit f27c3a8584, reversing
changes made to 9da045469e.
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
A bridge shouldn't provide interfaces to me so I submitted https://github.com/Seldaek/monolog/pull/1204 instead.
This PR reverts the possibility to autoconfigure processors for now, so that it could be moved to the MonologBundle instead.
To have TokenProcessor and WebProcessor classes implement the new ProcessorInterface, we could bump the minimum version of monolog. This cannot be done until a new version of it is tagged, so we need to resolve this before tagging 4.2 ourselves.
Commits
-------
cfc3f254e7 Revert "feature #27801 [MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors (nicolas-grekas)"
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Validator] Deprecate checkMX and checkHost on Email validator
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | yes
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | fixes#27559fixes#28665
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
c6009a0144 [Validator] deprecate checkMX and checkHost on Email validator
This PR was merged into the 4.2-dev branch.
Discussion
----------
[SecurityBundle] Improve error when argon2i is not available
| Q | A
| ------------- | ---
| Branch? | master?
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass? | ?
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Commits
-------
eb6436ac82 [SecurityBundle] Improve error when argon2i is not available
This PR was merged into the 4.2-dev branch.
Discussion
----------
[HttpKernel] Add a note about env name restrictions
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26884
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
b0f863d77e [HttpKernel] added a note about env name restrictions
This PR was merged into the 2.8 branch.
Discussion
----------
Sync English translations
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? |no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | https://github.com/symfony/symfony/pull/28828#issuecomment-429362737
| License | MIT
| Doc PR | -
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
bb573524cb Add a missing English translation
This PR was merged into the 4.2-dev branch.
Discussion
----------
[LDAP] Revamp LDAP options with nested options definition
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Next move after https://github.com/symfony/symfony/pull/27291 :)
This will work exactly that before, nothing change regarding behavior, BUT now we've *less code* and *intuitive definition of nested options*.
Commits
-------
a26c284d2d Revamp LDAP options with nested definition
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Intl] Blacklist invalid languages
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes?
| New feature? | yes?
| BC breaks? | no?
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
see https://en.wikipedia.org/wiki/ISO_639-3#Special_codes
Commits
-------
4f5404bdcb [Intl] Blacklist invalid languages
This PR was merged into the 4.2-dev branch.
Discussion
----------
'yml' is not a format and shouldn't be visible as constant from 'YamlEncoder'
A little fix of my [previous PR](https://github.com/symfony/symfony/pull/28815)
This PR changes the constant visibility of the `yml` format as private.
Because as @stof [mentionned](https://github.com/symfony/symfony/pull/28815#issuecomment-428941972) `yml` isn't a format, so the constant shoudn't be public.
Otherwise, this will be confusing while using autocomplete, you see two formats. The user can ask himself if there is a difference between `yaml` / `yml`.
No need of that :)
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Fixed tickets | -
| License | MIT
| Doc PR |
Commits
-------
674b359610 'yml' is not a format and shouldn't be visible as constant from 'YamlEncoder' class
This PR was merged into the 4.2-dev branch.
Discussion
----------
YamlEncoder handle yml format
| Q | A
| ------------- | ---
| Branch? | ?
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28768
| License | MIT
`Symfony\Component\Serializer\Encoder\YamlEncoder` now handle the `yml` format too
```
use Symfony\Component\Serializer\Serializer;
use Symfony\Component\Serializer\Encoder\YamlEncoder;
$serializer = new Serializer([], [new YamlEncoder()]);
$content = file_get_contents(__DIR__ . '/test.yml');
$data = $serializer->decode($content, YamlEncoder::ALTERNATIVE_FORMAT);
```
Let me know if something is wrong for you
Commits
-------
d8640f965b YamlEncoder handle yml extension
This PR was squashed before being merged into the 4.2-dev branch (closes#27742).
Discussion
----------
[Process] Add feature "wait until callback" to process class
I often see code like the following:
```php
$process->start();
// wait for the process to be ready
sleep(3);
```
Many times in tests, sometimes in other places. There is a problem with this kind of code because if for any reason the process starts slower than the usual... Your code may fail after that. Also if it's faster, you're losing time for waiting.
So here is my proposal:
```php
$process->start();
$process->waitUntil(function($type, $output) {
// check the output and return true to stop waiting when you got what you wait
});
```
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | none
| License | MIT
| Doc PR | Waiting for feedbacks
Commits
-------
27eaf83b63 [Process] Add feature \"wait until callback\" to process class
This PR was merged into the 4.2-dev branch.
Discussion
----------
Remove usage of sf2 when possible
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
I've not removed all `sf2` occurrences as I've kept the ones that would introduce a BC break.
Commits
-------
8406ee86a9 removed usage of sf2 when possible
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Cache] added support for connecting to Redis clusters via DSN
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Replaces #28300 and #28175
This PR allows configuring a cluster of Redis servers using all available options of either the phpredis extension or the Predis package:
- the `redis_cluster=0/1` boolean option configures whether the client should use the Redis cluster protocol;
- several hosts can be provided using a syntax very similar to #28598, enabling consistent hashing distribution of keys;
- `failover=error/distribute/slaves` can be set to direct reads at slave servers;
- extra options are passed as is to the driver (e.g. `profile=2.8`)
- Predis per-server settings are also possible, using e.g. `host[localhost][alias]=foo` in the query string, or `host[localhost]=alias%3Dfoo` (ie PHP query arrays or urlencoded key/value pairs)
Commits
-------
a42e8774d6 [Cache] added support for connecting to Redis clusters via DSN
* 4.1: (27 commits)
Added the Code of Conduct file
do not override custom access decision configs
[Security] Do not deauthenticate user when the first refreshed user has changed
fix a return type hint
invalidate stale commits for PRs too
add missing cache prefix seed attribute to XSD
fix command description
Fix class documentation
[Validator] Add a missing translation
[FrameworkBundle] Fix 3.4 tests
[DI] fix dumping inline services again
Rename consumer to receiver
Register messenger before the profiler
Fix phpdocs
[EventDispatcher] Remove template method in test case
Added LB translation for #27993 (UUID validator message translation)
Replace deprecated validateValue with validate
[FWBundle] Automatically enable PropertyInfo when using Flex
[Process] fix locking of pipe files on Windows
Correct PHPDoc type for float ttl
...
* 3.4: (21 commits)
Added the Code of Conduct file
do not override custom access decision configs
[Security] Do not deauthenticate user when the first refreshed user has changed
invalidate stale commits for PRs too
add missing cache prefix seed attribute to XSD
fix command description
Fix class documentation
[Validator] Add a missing translation
[FrameworkBundle] Fix 3.4 tests
[DI] fix dumping inline services again
Fix phpdocs
[EventDispatcher] Remove template method in test case
Added LB translation for #27993 (UUID validator message translation)
Replace deprecated validateValue with validate
[FWBundle] Automatically enable PropertyInfo when using Flex
[Process] fix locking of pipe files on Windows
Correct PHPDoc type for float ttl
bumped Symfony version to 3.4.18
updated VERSION for 3.4.17
updated CHANGELOG for 3.4.17
...
This PR was merged into the 3.4 branch.
Discussion
----------
[DI] fix dumping inline services again
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28720#28710
| License | MIT
| Doc PR | -
The main fix is in `PhpDumper::addInlineService()`
Fixes a few other glitches found meanwhile.
Commits
-------
a854b0a01c [DI] fix dumping inline services again
This PR was merged into the 4.2-dev branch.
Discussion
----------
Revert "feature #27549 [Cache] Unconditionally use PhpFilesAdapter for system pools"
This reverts commit d4f5d46b13, reversing
changes made to 7e3b7b0b50.
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Reading #28800, I've just realized that #27549 breaks using system caches with read-only filesystem.
Using ApcuAdapter makes system caches compatible with read-only filesystems.
Note that this affects only non-warmed up pools, as the warmed-up ones use a faster `PhpArrayAdapter` in front.
Commits
-------
dbc1230735 Revert "feature #27549 [Cache] Unconditionally use PhpFilesAdapter for system pools (nicolas-grekas)"
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Routing] simplify PhpMatcherDumper by splitting code logic from route data
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This PR splits all logic that is currently dumped into the matcher in a dedicated trait.
This makes the code easier to maintain and prepares for the next step (making the dumper compile routes as a set of PHP arrays instead of code.)
This diff is huge because affected fixtures are also huge, but it's negative, removing 1200 lines!
Commits
-------
22186c7045 [Routing] simplify PhpMatcherDumper by splitting code logic from route data
This PR was squashed before being merged into the 4.2-dev branch (closes#26261).
Discussion
----------
[Validator] Improvement: provide file basename for constr. violation messages in FileValidator.
| Q | A
| ------------- | ---
| Branch? | 3.4 <!-- see below -->
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | no
| License | MIT
| Doc PR | N/A
`\Symfony\Component\Validator\Constraints\FileValidator` provides absolute path to file on server when user, per example, uploads empty file, too large file, of wrong mime type, etc...
Absolute path to file on server does not have value to the end user, on top of that, exposing it can be a security issue - end user should not be aware of server filesystem.
Basename of file, however, has value (per example: MyAwesomeSheet.xlsx, MyCV.doc, etc..) - if something is wrong with file upload (size, mime, etc...).
If basename is exposed, we can construct messages like: "Your file 'MyCV.doc' is not allowed for upload due to....whatever"...
This PR provides basename of file so end user of `\Symfony\Component\Validator\Constraints\FileValidator` can construct error messages of higher value for end user.
Commits
-------
a77abadf06 [Validator] Improvement: provide file basename for constr. violation messages in FileValidator.
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Form] allow additional http methods in form configuration
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #26287
| License | MIT
| Doc PR | TBD
In order to allow HTTP methods other than GET, PUT, POST, DELETE and PATCH, the `allowed_methods` option under `framework.form` configuration has been added.
This configuration option adds the specified methods to the `FormConfigBuilder` whitelist, allowing that methods be used in form configuration via `setMethod` or the `method` option.
The use-case, that has been discussed in #26287, required the usage of custom HTTP method for describing a resource in an API application.
Commits
-------
27d228c3ee [Form] remove restriction on allowed http methods
This PR was merged into the 4.2-dev branch.
Discussion
----------
[OptionsResolver] Added support for nesting options definition
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #4833
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/9995
I'd like to propose an alternative to #27251 and #18134 with a different approach.
It would allow you to create a nested options system with required options, validation (type, value),
normalization and more.
<details>
<summary><strong>Short documentation</strong></summary>
**To define a nested option, you can pass a closure as the default value of the option with an `OptionsResolver` argument:**
```php
$resolver
->defaults([
'connection' => 'default',
'database' => function (OptionsResolver $resolver) {
$resolver
->setRequired(['dbname', 'host', ...])
->setDefaults([
'driver' => 'pdo_sqlite',
'port' => function (Options $options) {
return 'pdo_mysql' === $options['driver'] ? 3306 : null,
},
'logging' => true,
])
->setAllowedValues('driver', ['pdo_sqlite', 'pdo_mysql'])
->setAllowedTypes('port', 'int')
->setAllowedTypes('logging', 'bool')
// ...
},
]);
$resolver->resolve(array(
'database' => array(
'dbname' => 'demo',
'host' => 'localhost',
'driver' => 'pdo_mysql',
),
));
// returns: array(
// 'connection' => 'default',
// 'database' => array(
// 'dbname' => 'demo',
// 'host' => 'localhost',
// 'driver' => 'pdo_mysql',
// 'port' => 3306,
// 'logging' => true,
// ),
//)
```
Based on this instance, you can define the options under ``database`` and its desired default
value.
**If the default value of a child option depend on another option defined in parent level,
adds a second ``Options`` argument to the closure:**
```php
$resolver
->defaults([
'profiling' => false,
'database' => function (OptionsResolver $resolver, Options $parent) {
$resolver
->setDefault('logging', $parent['profiling'])
->setAllowedTypes('logging', 'bool');
},
])
;
```
**Access to nested options from lazy or normalize functions in parent level:**
```php
$resolver
->defaults([
'version' => function (Options $options) {
return $options['database']['server_version'];
},
'database' => function (OptionsResolver $resolver) {
$resolver
->setDefault('server_version', 3.15)
->setAllowedTypes('server_version', 'numeric')
// ...
},
])
;
```
As condition, for nested options you must to pass an array of values to resolve it on runtime, otherwise an exception will be thrown:
```php
$resolver->resolve(); // OK
$resolver->resolve(['database' => []]); // OK
$resolver->resolve(['database' => null); // KO (Exception!)
```
</details>
---
Demo app https://github.com/yceruto/nested-optionsresolver-demo
Commits
-------
d04e40be5a Added support for nested options definition
This PR was merged into the 4.2-dev branch.
Discussion
----------
[VarDumper] Allow to use a light theme out of the box
| Q | A
| ------------- | ---
| Branch? | master <!-- see below -->
| Bug fix? | no
| New feature? | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Wouldn't it be nice to provide this light theme out of the box? (the one we use in the profiler)
![capture d ecran 2018-05-14 a 16 50 55](https://user-images.githubusercontent.com/2211145/40004942-23b4138c-5797-11e8-8c57-0b38744ffdc2.png)
Commits
-------
c705b82563 [VarDumper] Allow to use a light theme out of the box
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Finder] Added a way to inverse a previous sorting
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
---
Sometimes, it's useful to inverse the previous sorting.
For exemple when you want to display the most recent uploaded files
Commits
-------
3cd0dcaaee [Finder] Added a way to inverse a previous sorting
This PR was squashed before being merged into the 4.2-dev branch (closes#28061).
Discussion
----------
[Security] add port in access_control
| Q | A
| ------------- | ---
| Branch? | master for features
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #26071
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10359
Add port in access_control
__Please Squash this P.R.__
Commits
-------
6413dcbe75 [Security] add port in access_control
This PR was merged into the 4.2-dev branch.
Discussion
----------
Added different protocols to be allowed as asset base_url
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | fixes#28238
| License | MIT
| Doc PR | symfony/symfony-docs#10347
In some cases you want to use the `file://` as base_url when you are for example generating pdf and want to avoid network requests to improve the pdf generation performance:
```yaml
framework:
assets:
packages:
pdf:
base_url: "file://%kernel.project_dir%/public"
```
usage:
```twig
{{ asset('image.jpg', 'pdf' }}
```
Commits
-------
2e21834b71 added different protocols to be allowed as asset base_urls
This PR was merged into the 2.8 branch.
Discussion
----------
[Process] fix locking of pipe files on Windows
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28655
| License | MIT
| Doc PR | -
Commits
-------
d64bd3b181 [Process] fix locking of pipe files on Windows
This PR was merged into the 4.2-dev branch.
Discussion
----------
[FrameworkBundle] Moving Cache-related CompilerPass to Cache component
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Hi, first PR here 🎉
This is related to #27479 and a first work to move Cache-related CompilerPass out of `FrameworkBundle`, it allows to decouple part of the FrameworkBundle configuration classes.
Since we didn't choosed a fixed directory organization to manage theses, I actually did same as in Bundles and used DependencyInjection folder. If we do choose to follow my [last comment directory organization proposal](https://github.com/symfony/symfony/issues/27479#issuecomment-401307685), I'll move theses CompilerPass to `Framework/DependencyInjection/Compiler` directory (nothing hard here).
Thanks to @DanieleGBX that helped me checking this PR and gave me some good advices !
Here is a list of all CompilerPass I moved, with related component (I also moved related tests when they were present):
- **Cache** - CacheCollectorPass
- **Cache** - CachePoolClearerPass
- **Cache** - CachePoolPass
- **Cache** - CachePoolPrunerPass
Commits
-------
53e7040829 moving Cache-related compiler pass from FrameworkBundle to Cache component
* 2.8:
Fix class documentation
[Validator] Add a missing translation
Fix phpdocs
[EventDispatcher] Remove template method in test case
Added LB translation for #27993 (UUID validator message translation)
Replace deprecated validateValue with validate
This PR was squashed before being merged into the 4.2-dev branch (closes#28738).
Discussion
----------
[OptionsResolver] Passing Options argument to deprecation closure
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/28721#discussion_r222686221
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10439
As spotted here https://github.com/symfony/symfony/pull/28721, we sometimes need more advanced cases, where the deprecation of the value depends on another option:
```php
$resolver->setDeprecated('date_format', function (Options $options, $dateFormat) {
if (null !== $options['date_format'] && 'single_text' === $options['widget']) {
return sprintf('Using the "date_format" option of the %s when the "widget" option is set to "single_text" is deprecated since Symfony 4.2.', self::class);
}
return '';
});
```
There is still a decision to make:
> We're in time to change the arguments position (Options $options, $value) to be consistent with other closure signatures.
WDYT?
Commits
-------
29360510db [OptionsResolver] Passing Options argument to deprecation closure
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Cache] add CacheInterface::delete() + improve CacheTrait
| Q | A
| ------------- | ---
| Branch? | 4.2
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
I've been hesitating a lot on this topic, but I think we should add a `delete()` method to `CacheInterface`.
Deleting is a very common invalidation strategy and invalidating by passing `$beta=INF` to `get()` has the drawback of requiring a fetch+unserialize+save-with-past-expiration. That's complexity that a delete removes.
This PR fixes an issue found meanwhile on `get()`: passing an `ItemInterface` to its callback makes it harder than required to implement on top of PSR-6. Let's pass a `CacheItemInterface`.
Lastly, the early expiration logic can be moved from the component to the trait shipped on contracts.
Here we are for all these steps.
Commits
-------
c6cf690b2f [Cache] add CacheInterface::delete() + improve CacheTrait
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Form] simplify the form type extension registration
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22833, #27906
| License | MIT
| Doc PR |
Commits
-------
6a1d4c5db4 simplify the form type extension registration
This PR was merged into the 2.8 branch.
Discussion
----------
[EventDispatcher] Remove template method in test case
| Q | A
| ------------- | ---
| Branch? | 2.8 <!-- see below -->
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | no <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | no <!-- required for new features -->
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
545a8eef05 [EventDispatcher] Remove template method in test case
This PR was merged into the 4.2-dev branch.
Discussion
----------
[WebServerBundle] Added ability to display the current hostname address if available when binding to 0.0.0.0
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | ? (no tests for server commands)
| Fixed tickets | #28585
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Tries to get the local hostname into an ip (if available) using the PHP gethostname* methods.
Commits
-------
dfd2e8b4e6 [WebServerBundle] Added ability to display the current hostname address if available when binding to 0.0.0.0
This PR was merged into the 4.2-dev branch.
Discussion
----------
[DI] minor optim for dumped container
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Spotted while reviewing a real-world dumped container.
Commits
-------
c1863e3a7a [DI] minor optim for dumped container
This PR was squashed before being merged into the 3.4 branch (closes#28072).
Discussion
----------
[Security] Do not deauthenticate user when the first refreshed user has changed
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Currently the token is deauthenticated when the first refreshed user has changed. In theory, a second user provider could find a user that is the same than the user stored in the token.
Also, the deauthentication is currently affected by the order of the user providers in the security.yaml and IMHO it does not make sense.
Commits
-------
95dce67 [Security] Do not deauthenticate user when the first refreshed user has changed
This PR was merged into the 2.8 branch.
Discussion
----------
Fix class documentation
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
The phpdoc references the PHP flush function, neither a method of this class nor its parent.
Commits
-------
5a51bb24dc Fix class documentation
This PR was merged into the 3.4 branch.
Discussion
----------
[FWBundle] Automatically enable PropertyInfo when using Flex
| Q | A
| ------------- | ---
| Branch? | 3.4
Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Automatically enabling PropertyInfo when using Flex and when the component is installed has been forgotten when releasing 3.4.
It makes it very hard to debug why some features of the serializer are sometimes not working properly.
Commits
-------
0683f0ac82 [FWBundle] Automatically enable PropertyInfo when using Flex
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Fix middleware docblocks
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
f06c0c464a [Messenger] Fix middleware docblocks
This PR was merged into the 4.2-dev branch.
Discussion
----------
clarify the cache.pools.provider option
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | -
| Fixed tickets | -
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10390
improve the documentation in Configuration.php with things we found out in https://github.com/symfony/symfony-docs/pull/10390
Commits
-------
ad4aaf151a clarify the cache.pools.provider option
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Translator] Deprecated transChoice and moved it away from contracts
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | Issue: https://github.com/symfony/symfony-docs/issues/10264
This will address comment made here: https://github.com/symfony/symfony/pull/27399#pullrequestreview-151929117
This PR moves the `transChoice()` method away from Contracts and back to the component. I also reverted changes in the `IdentityTranslator`. I will still use the deprecated `MessageSelector` but this is not fine since `transChoice()` is also deprecated.
Commits
-------
dc5f3bfff7 Make trans + %count% parameter resolve plurals
d870a850bd [Translator] Deprecated transChoice and moved it away from contracts
This PR was merged into the 2.8 branch.
Discussion
----------
[Validator][minor] Fixed method in phpDoc
| Q | A
| ------------- | ---
| Branch? | >= 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
`ValidatorInterface` doesn't have a `validateValue` method, `validate` should be used.
Commits
-------
b0253e58ea Replace deprecated validateValue with validate
This PR was merged into the 4.2-dev branch.
Discussion
----------
[WebServerBundle] Deprecate relying on --env in server:start and server:run
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commits
-------
31b5615b51 [WebServerBundle] Deprecate relying on --env in server:start and server:run
Technically, dates formatted according to the HTML specifications do not
contain any timezone information. But since our DateTimeType used to
contain this information in the passed, users had configure their JS
libraries to accept (and create) dates in that format.
To not break BC we should accept these dates and silently ignore the
additional timezone information.
This PR was squashed before being merged into the 4.2-dev branch (closes#28669).
Discussion
----------
[Serializer] Object class resolver
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
When normalizing an object, it could be useful to use a custom method to resolve the class name of it instead of using `get_class`.
For instance, Doctrine is using proxy classes for lazy-loading and we usually want the real class and not the proxied one.
That's why we are using this trait in API Platform: https://github.com/api-platform/core/blob/master/src/Util/ClassInfoTrait.php
With this feature, we could solve an issue in API Platform with the JSON-LD normalizer when the eager fetching is disabled.
Commits
-------
18d21439e0 [Serializer] Object class resolver
This PR was squashed before being merged into the 3.4 branch (closes#28604).
Discussion
----------
[Finder] fixed root directory access for ftp/sftp wrapper
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27423
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
This fixes a flaw introduced in 3.4.7 by #26763
In order to access the root folder with ftp wrapper, there MUST BE a slash present.
- Currently: from 3.4.7 on it just ```rtrim``` all seperators (```/```, ```\```) from directories
- Now: IF the directory is a (s)ftp:// wrapper (```#^s?ftp://#```) this fix just adds a slash (```/```) again
Commits
-------
9630a38d67 [Finder] fixed root directory access for ftp/sftp wrapper
This PR was merged into the 3.4 branch.
Discussion
----------
[FWBundle] Throw if PropertyInfo is enabled, but the component isn't installed
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? |no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
41fd0a881e [FWBundle] Throw if PropertyInfo is enabled, but the component isn't installed
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Security] Deprecate simple_preauth and simple_form in favor of Guard
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commits
-------
5093b9fb47 [Security] Deprecate simple_preauth and simple_form in favor of Guard
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] drop "handler." prefix from ContainerHandlerLocator
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28621
| License | MIT
| Doc PR | -
I fail to understand what this prefix is for. Looks like boilerplate to me, let's drop it, isn't it?
An alternative to #28621
Commits
-------
6c56e82080 [Messenger] drop "handler." prefix from ContainerHandlerLocator
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Translation] marked getFallbackLocales() as internal
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | #28579
| License | MIT
| Doc PR |
Added the deprication trigger error function to getFallbackLocales in the Translation component.
(Its my first PR, please tell me if i need to change something)
Commits
-------
9d67a68816 [Translation] marked getFallbackLocales() as internal
This PR was merged into the 2.8 branch.
Discussion
----------
Remove redundant path check
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | maybe?
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commit 0ec852d79f introduced this new method. As you can see, the code I'm removing always evaluates to `true` thanks to the first `if` statement in this method:
![image](https://user-images.githubusercontent.com/202034/46349212-70968a80-c61f-11e8-8360-7d6abc4d7414.png)
(I'm not sure if redundant code technically counts as a "bug", so I've assumed "yes it does" and targeted 2.8.)
Commits
-------
10795cf096 Remove redundant path check
This PR was squashed before being merged into the 4.2-dev branch (closes#28571).
Discussion
----------
[DependencyInjection] Improve ServiceLocatorTagPass service matching
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #26892
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10397
Allows omitting of keys for service locator arguments (it will automatically take over the original definition alias).
Commits
-------
1c1210a3e8 [DependencyInjection] Improve ServiceLocatorTagPass service matching
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Validator] Pre-check constraint validator dependencies
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | yes
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #25865
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
0544985934 [Validator] Pre-check constraint validator dependencies
This PR was squashed before being merged into the 4.2-dev branch (closes#28661).
Discussion
----------
[Serializer] Add an option to skip null values
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? |no
| New feature? | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | todo
Adds a new option to not serialize `null` values:
```php
$dummy = new class {
public $foo;
public $bar = 'notNull';
};
$normalizer = new ObjectNormalizer();
$result = $normalizer->normalize($dummy, 'json', ['skip_null_values' => true]);
// ['bar' => 'notNull']
```
This feature is the only missing part to add [JSON Merge Patch](https://tools.ietf.org/html/rfc7386) support in [API Platform](https://api-platform.com).
It will also help supporting this RFC in all other projects using the Symfony Serializer.
Commits
-------
d3c5055f7b [Serializer] Add an option to skip null values
* 4.1: (21 commits)
[php_cs] disable fopen_flags
[DI] fix error in dumped container
[CS] Remove unused variables passed to closures
[DI] fix dumping setters before their inlined instances
[CS] Remove empty comment
[CS] Enforces null type hint on last position in phpDocs
[CS] Use combined assignment operators when possible
Fix a typo in error messages
Don't return early as this bypasses the auto exit feature
[Console] Add missing null to input values allowed types
[PHPUnitBridge] Fix microtime() format
bumped Symfony version to 4.1.6
updated VERSION for 4.1.5
updated CHANGELOG for 4.1.5
bumped Symfony version to 3.4.17
updated VERSION for 3.4.16
updated CHANGELOG for 3.4.16
bumped Symfony version to 2.8.47
update CONTRIBUTORS for 2.8.46
updated VERSION for 2.8.46
...
* 3.4:
[php_cs] disable fopen_flags
[DI] fix error in dumped container
[CS] Remove unused variables passed to closures
[DI] fix dumping setters before their inlined instances
[CS] Remove empty comment
[CS] Enforces null type hint on last position in phpDocs
[CS] Use combined assignment operators when possible
Fix a typo in error messages
Don't return early as this bypasses the auto exit feature
[Console] Add missing null to input values allowed types
[PHPUnitBridge] Fix microtime() format
bumped Symfony version to 3.4.17
updated VERSION for 3.4.16
updated CHANGELOG for 3.4.16
bumped Symfony version to 2.8.47
update CONTRIBUTORS for 2.8.46
updated VERSION for 2.8.46
updated CHANGELOG for 2.8.46
* 2.8:
[php_cs] disable fopen_flags
[CS] Remove unused variables passed to closures
[CS] Remove empty comment
[CS] Enforces null type hint on last position in phpDocs
[CS] Use combined assignment operators when possible
Fix a typo in error messages
[Console] Add missing null to input values allowed types
[PHPUnitBridge] Fix microtime() format
bumped Symfony version to 2.8.47
update CONTRIBUTORS for 2.8.46
updated VERSION for 2.8.46
updated CHANGELOG for 2.8.46
This PR was merged into the 2.8 branch.
Discussion
----------
[PHPUnitBridge] Fix ClockMock microtime() format
| Q | A
| ------------- | ---
| Branch? | 2.8 <!-- see below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | yes/no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | no <!-- please add some, will be required by reviewers -->
| Fixed tickets | <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | <!-- required for new features -->
This is a follow-up PR to #27890 to fix the `microtime` precision, it should be 8 decimals instead of the current 6 (see https://3v4l.org/GYacF)
The problem now is that due to the new tests the whole testsuite will fail if run from the main directory, as hhvm and 5.4 targets are doing, due to phpunit using the wrong `ClockMock` class. Tests for 7.1 and 7.2 pass because they `cd` into the component directory.
Commits
-------
e3732b63c6 [PHPUnitBridge] Fix microtime() format
This PR was merged into the 2.8 branch.
Discussion
----------
[CS] Enforces null type hint on last position in phpDocs
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | - <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | - <!-- required for new features -->
As a majority in our codebase, the `null` typehint usually comes in the last position in phpDocs.
Commits
-------
efbba25577 [CS] Enforces null type hint on last position in phpDocs
This PR was merged into the 2.8 branch.
Discussion
----------
[CS] Use combined assignment operators when possible
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | - <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | - <!-- required for new features -->
Less opcodes for us 😄
Commits
-------
c561e99394 [CS] Use combined assignment operators when possible
This PR was merged into the 2.8 branch.
Discussion
----------
[CS] Remove empty comment
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | - <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | - <!-- required for new features -->
Commits
-------
3bfd877e16 [CS] Remove empty comment
This PR was merged into the 3.4 branch.
Discussion
----------
[DI] fix error in dumped container
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28658
| License | MIT
| Doc PR | -
(test case on its way)
Commits
-------
2d0aba6ff8 [DI] fix error in dumped container
This PR was squashed before being merged into the 4.1 branch (closes#28636).
Discussion
----------
[HttpFoundation] X-Accel-Mapping does not use HTTP key=value syntax
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? |no
| Tests pass? | yes
| Fixed tickets | #28627
| License | MIT
| Doc PR |
The `X-Accel-Mapping` header does not use the standard HTTP key=value syntax, so using `HeaderUtils::combine()` breaks paths with upper-case letters.
There is no good reason to use `HeaderUtils::combine()` in this case, so simply skip it.
Commits
-------
09343c27d7 [HttpFoundation] X-Accel-Mapping does not use HTTP key=value syntax
* 4.1:
[Console] simplified code
removed useless phpdoc
improve docblocks around group sequences
[Cache] prevent getting older entries when the version key is evicted
[WebProfilerBundle] added a note in the README
[Yaml] Skip parser test with root user
[Filesystem] Skip tests on readable file when run with root user
[FWBundle] Fix an error in WebTestCase::createClient's PHPDoc
[HttpFoundation][Security] forward locale and format to subrequests
[Console] Send the right exit code to console.terminate listeners
[HttpFoundation] fix hidding warnings from session handlers
Caching missed templates on cache warmup
* 3.4:
[Console] simplified code
removed useless phpdoc
improve docblocks around group sequences
[Cache] prevent getting older entries when the version key is evicted
[WebProfilerBundle] added a note in the README
[Yaml] Skip parser test with root user
[Filesystem] Skip tests on readable file when run with root user
[FWBundle] Fix an error in WebTestCase::createClient's PHPDoc
[HttpFoundation][Security] forward locale and format to subrequests
[Console] Send the right exit code to console.terminate listeners
[HttpFoundation] fix hidding warnings from session handlers
Caching missed templates on cache warmup
* 2.8:
improve docblocks around group sequences
[WebProfilerBundle] added a note in the README
[Filesystem] Skip tests on readable file when run with root user
[FWBundle] Fix an error in WebTestCase::createClient's PHPDoc
[HttpFoundation][Security] forward locale and format to subrequests
[Console] Send the right exit code to console.terminate listeners
Caching missed templates on cache warmup
This PR was merged into the 2.8 branch.
Discussion
----------
[Validator] improve docblocks around group sequences
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? |no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #26889
| License | MIT
| Doc PR |
Commits
-------
179a081ee3 improve docblocks around group sequences
This PR was merged into the 4.2-dev branch.
Discussion
----------
[BrowserKit] throw exception when request() wasn't called
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | https://github.com/symfony/symfony/pull/27807#issuecomment-420985940
Commits
-------
41cfde19f6 throw exception when request() wasn't called
This PR was merged into the 2.8 branch.
Discussion
----------
[TwigBundle] Fixed caching of templates in src/Resources/<BundleName>/views on cache warmup
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Same as https://github.com/symfony/symfony/pull/27764, but in this case the convention is wrong.
Corrected according to:
992a174470/src/Symfony/Bundle/TwigBundle/DependencyInjection/TwigExtension.php (L165)
Commits
-------
83a75f4313 Caching missed templates on cache warmup
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Cache] add "setCallbackWrapper()" on adapters implementing CacheInterface for more flexibility
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27730
| License | MIT
| Doc PR | -
Preparing my talk at SymfonyLive London, see you all there :)
This allows wrapping the callback passed to `->get($item, $callback, $beta)` in a callable that should at least return `$callback($item)`, but can do something around the call.
The default wrapper is locking the key to provide lock-based stampede protection.
That was already the case before this PR, but in a much dirtier way at the design level.
Fixes a few issues found meanwhile.
Commits
-------
8cf3625b11 [Cache] add "setCallbackWrapper()" on adapters implementing CacheInterface for more flexibility
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Cache] support configuring multiple Memcached servers in one DSN
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27855
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/issues/10402
Useful to reconfigure dynamically an array of memcached servers (eg removing a dead one or adding a new one).
DSN format is e.g. `memcached://localhost?host[foo.bar]=3`.
To ease generating the DSN programmatically, it works also with `memcached:?host[localhost]&host[localhost:12345]&host[/some/memcached.sock:]=3`.
The key of the "host" parameter is a "host:port" pair, the value is the weight of the "host:port" pair.
Sockets need to be specified with the trailing `:` (as shown in the last example).
Commits
-------
8e0605ac18 [Cache] support configuring multiple Memcached servers in one DSN
This PR was merged into the 2.8 branch.
Discussion
----------
[HttpFoundation][Security] forward locale and format to subrequests
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28368, #21546
| License | MIT
| Doc PR | -
See discussion in linked issue.
Commits
-------
41eb1914f6 [HttpFoundation][Security] forward locale and format to subrequests
This PR was merged into the 4.2-dev branch.
Discussion
----------
[HttpFoundation] make cookies auto-secure when passing them $secure=null + plan to make it and samesite=lax the defaults in 5.0
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | #26731
| License | MIT
| Doc PR | -
By creating Cookie instances using `null` for the `$secure` argument, this PR allows making cookies inherit their "secure" attribute from the request.
This PR also adds a forward to make $secure=null and samesite=lax the defaults in Symfony 5.0:
- either define all constructor's arguments explicitly
- or use the new `Cookie::create()` factory
Commits
-------
9493cfd5f2 [HttpFoundation] make cookies auto-secure when passing them $secure=null + plan to make it and samesite=lax the defaults in 5.0
This PR was merged into the 4.2-dev branch.
Discussion
----------
[SecurityBundle] make remember-me cookies auto-secure + inherit their default config from framework.session.cookie_*
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28338
| License | MIT
| Doc PR | -
Let's make it easier to have a good default security level, now for the remember-me cookie.
Commits
-------
6ec223bf6f [SecurityBundle] make remember-me cookies auto-secure + inherit their default config from framework.session.cookie_*
This PR was merged into the 4.2-dev branch.
Discussion
----------
[VarExporter] add Instantiator::instantiate() to create+populate objects without calling their constructor nor any other methods
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
A blend of features also provided by https://github.com/doctrine/instantiator and https://github.com/Ocramius/GeneratedHydrator in one simple method. Because it's just a few more lines on top of the existing code infrastructure in the component :)
For example, from the docblock:
```php
// creates an empty instance of Foo
Instantiator::instantiate(Foo::class);
// creates a Foo instance and sets one of its public, protected or private properties
Instantiator::instantiate(Foo::class, ['propertyName' => $propertyValue]);
// creates a Foo instance and sets a private property defined on its parent Bar class
Instantiator::instantiate(Foo::class, [], [
Bar::class => ['privateBarProperty' => $propertyValue],
]);
```
Instances of ArrayObject, ArrayIterator and SplObjectHash can be created
by using the special `"\0"` property name to define their internal value:
```php
// creates an SplObjectHash where $info1 is attached to $obj1, etc.
Instantiator::instantiate(SplObjectStorage::class, ["\0" => [$obj1, $info1, $obj2, $info2...]]);
// creates an ArrayObject populated with $inputArray
Instantiator::instantiate(ArrayObject::class, ["\0" => [$inputArray, $optionalFlag]]);
```
Misses some tests for now, but reuses the existing code infrastructure used to "unserialize" objects.
Commits
-------
d9bade0385 [VarExporter] add Instantiator::instantiate() to create+populate objects without calling their constructor nor any other methods
This PR was merged into the 3.4 branch.
Discussion
----------
[Cache] prevent getting older entries when the version key is evicted
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28445
| License | MIT
| Doc PR | -
As described in linked issue, using a strategy described in
https://github.com/memcached/memcached/wiki/ProgrammingTricks#deleting-by-namespace
Commits
-------
00855895a8 [Cache] prevent getting older entries when the version key is evicted
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Serializer] deprecated normalizers and encoders who dont implement the base interfaces
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | None
| License | MIT
| Doc PR | None
Currently the `Serializer` can be constructed with any object regardless of whether or not it implements `NormalizerInterface` or `DenormalizerInterface`. This object will then be ignored when getting a normalizer/denormalizer, so in effect silently ignored for serializer operations.
This change throws an exception on construct if a given normalizer object does not implement one of these interfaces - are there use cases where this would not be true?
Commits
-------
cbc2be8ba8 [Serializer] deprecated normalizers and encoders who dont implement the base interfaces
This PR was merged into the 2.8 branch.
Discussion
----------
[WebProfilerBundle] added a note in the README
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets |
| License | MIT
| Doc PR |
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
310870a497 [WebProfilerBundle] added a note in the README
This PR was merged into the 4.2-dev branch.
Discussion
----------
Make it clear that the profiler is for dev only
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | kinda yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes (permanent one)
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | symfony/symfony-docs#10386
Commits
-------
54fda55fd9 made it clear that the profiler is for dev only
This PR was squashed before being merged into the 3.4 branch (closes#28529).
Discussion
----------
[Yaml] Skip parser test with root user
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28478
| License | MIT
| Doc PR | -
This PR fix a test failure in YAML Component when running from a php docker container.
By defaut, root user is used to run phpunit. It means permission checking will fail (Root user is always allowed to read files)
Commits
-------
34429797b3 [Yaml] Skip parser test with root user
This PR was merged into the 2.8 branch.
Discussion
----------
[Filesystem] Skip tests on readable file when run with root user
| Q | A
| ------------- | ---
| Branch? | 2.8 <!-- see below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #28478 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | - <!-- required for new features -->
This PR fix tests failures in Filesystem Component when running from a php docker container.
By defaut, root user is used to run phpunit. It means permission checking will fail (Root user is always allowed to read files)
Linked to #28529
Commits
-------
ad500e74ec [Filesystem] Skip tests on readable file when run with root user
This PR was merged into the 4.2-dev branch.
Discussion
----------
[DependencyInjection] improved message when alias service is not found
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28413
| License | MIT
| Doc PR |
When using the YAML config format, it can be confusing that you need to
prefix the aliased service id with an `@` character when passing it as
a string, but that you have to omit it when using the `alias` attribute:
```yaml
foo: '@App\Foo'
foo:
alias: 'App\Foo'
```
This commit will enhance the generated error message in cases where the
aliased service id is prefixed with the `@` character in the `alias`
option like this:
```yaml
foo:
alias: '@App\Foo'
```
Commits
-------
280ecbc2be improved message when alias service is not found
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Console] Add support for error ouput in the CommandTester
Move initialization of the streams to the trait so the `capture_stderr_separately` also works in the CommandTester.
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27422
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Make it possible to test seperate stderr output.
```$tester = new CommandTester($command);
$tester->execute(
array('foo' => 'bar'),
array('capture_stderr_separately' => true)
);
$this->assertEquals('foo', $tester->getErrorOutput());
````
Commits
-------
cec5317 [Console] Add support for error ouput in the CommandTester
This PR was squashed before being merged into the 2.8 branch (closes#28545).
Discussion
----------
[Console] Send the right exit code to console.terminate listeners
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
When a Console command throws an exception without a status code, `Application::run()` takes care of setting the exit code to `1` when the exception does not provide a code itself.
This happens slightly too late, as `console.terminate` event listeners that are called from within `Application::doRunCommand()` are given the plain exeception code, before this conversion.
The result is that `console.*` event listeners that you might be using to log exit code e. g. for cron jobs will see a `0` code instead of the real value used to terminate the script.
***Todo:***
- [x] Make sure we've got tests covering this, i. e. do not mock out `doRunCommand()`.
Commits
-------
b90a3f1 [Console] Send the right exit code to console.terminate listeners
When using the YAML config format, it can be confusing that you need to
prefix the aliased service id with an `@` character when passing it as
a string, but that you have to omit it when using the `alias` attribute:
```yaml
foo: '@App\Foo'
foo:
alias: 'App\Foo'
```
This commit will enhance the generated error message in cases where the
aliased service id is prefixed with the `@` character in the `alias`
option like this:
```yaml
foo:
alias: '@App\Foo'
```
This PR was merged into the 3.4 branch.
Discussion
----------
[Debug] Fix false-positive "MicroKernelTrait::loadRoutes()" method is considered internal"
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes (fixing and unreleased issue)
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28549
| License | MIT
| Doc PR | -
Introduced in #28411
Just a failing test for now.
Commits
-------
46c4f71bf0 [Debug] Fix false-positive "MicroKernelTrait::loadRoutes()" method is considered internal"
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Debug] Trigger a deprecation for new parameters not defined in sub classes
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/28316
| License | MIT
| Doc PR | -
I'm not sure the way https://github.com/symfony/symfony/pull/28316 is implemented is the best so here is an alternative.
Instead of counting on a call from the child method, it uses the `DebugClassLoader` and `@param` annotations. If a `@param` annotation is used on a parent but is then not actually implemented in the child class, a deprecation will be thrown.
Example:
```php
class ClassWithAnnotatedParameters
{
/**
* @param string $foo This is a foo parameter.
*/
public function fooMethod(string $foo)
{
}
/**
* @param string $bar parameter not implemented yet
*/
public function barMethod(/** string $bar = null */)
{
}
/**
* @param Quz $quz parameter not implemented yet
*/
public function quzMethod(/** Quz $quz = null */)
{
}
}
```
```php
class SubClassWithAnnotatedParameters extends ClassWithAnnotatedParameters {
public function fooMethod(string $foo) { }
public function barMethod($bar = null) { }
public function quzMethod() { }
}
```
A deprecation will be triggered because ``SubClassWithAnnotatedParameters::quzMethod()`` which doesn't definee `$quz`.
Commits
-------
1f5d8b62f7 [Debug] Trigger a deprecation for new parameters not defined in sub classes
* 4.1:
Fix CS
Allow reuse of Session between requests
[MonologBridge] Re-add option option to ignore empty context and extra data
[Lock] remove useless code
[PhpUnitBridge] fix disabling DeprecationErrorHandler using phpunit.xml file
Provide debug_backtrace with proper args
[DI] fix infinite loop involving self-references in decorated services
forward false label option to nested types
[DI] fix dumping lazy services
forward the invalid_message option in date types
* 3.4:
Fix CS
Allow reuse of Session between requests
[MonologBridge] Re-add option option to ignore empty context and extra data
[Lock] remove useless code
[PhpUnitBridge] fix disabling DeprecationErrorHandler using phpunit.xml file
Provide debug_backtrace with proper args
[DI] fix infinite loop involving self-references in decorated services
forward false label option to nested types
forward the invalid_message option in date types
* 2.8:
Fix CS
Allow reuse of Session between requests
Provide debug_backtrace with proper args
forward false label option to nested types
forward the invalid_message option in date types
This PR was merged into the 4.2-dev branch.
Discussion
----------
Add Zookeeper data store for Lock Component
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | Not applicable
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10043
This change adds a new feature to the Lock Component to give the capability to store locks in Zookeeper Data Store. The corresponding documentation PR should describe how this works.
The change here also adds a functional test to make sure all the basic functionality of the lock using this data store works.
Requirements for this to work are having a PHP-Zookeeper extension available to use this.
Commits
-------
c72c297dc3 Add new Zookeeper Data Store. Add functional test for Zookeeper Data Store. Modify Store Factory to support initialization of Zookeeper Data Store.
This PR was merged into the 2.8 branch.
Discussion
----------
[HttpFoundation] Allow reuse of Session between requests if ID did not change
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #13450
| License | MIT
| Doc PR | -
I stumbled upon the issue from https://github.com/symfony/symfony/issues/13450 in a more simple case than what was exposed in the issue. From my understanding, the problem arises when the session is used between an access to the session and a functional test request: because the session was accessed (usually using the container directly), the session has started and the following request fails.
This PR checks whether the ID was actually regenerated before throwing (if a setId is called with the same ID, it is the same request context, it shouldn't throw IMO).
Not sure I understood everything correctly though, feel free to fix it for me if needed.
Commits
-------
fd30f4a21d Allow reuse of Session between requests
This PR was merged into the 4.2-dev branch.
Discussion
----------
[VarDumper] Allow dd() to be called without arguments
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
**Description**
A while back the `dd()` helper was [added to the VarDumper component](https://github.com/symfony/symfony/pull/26970) which was (i think) inspired by Laravel's `dd()` helper. Laravel has [removed their version of the helper](https://github.com/laravel/framework/pull/25087) in favor of the helper in Symfony.
However, as opposed to the Laravel helper, the Symfony helper requires at least one argument. Calling the Laravel helper with no arguments simply killed the program (and usually showed a white screen), calling the Symfony helper with no arguments throws a `TypeError: Too few arguments to function dd()` exception (which gets rendered by the error handler and fills the whole screen with useless information).
Being able to call the `dd()` helper with no arguments is useful because it is a quick way to tell you if your code reaches a certain point. If it does, you can fill in the `dd()` with variables to keep debugging.
This PR allows the dd helper to be called without arguments.
This PR also makes the helper call `die` instead of `exit` to better reflect the function name 😄
Commits
-------
a73dfadc18 [VarDumper] Allow dd() to be called without arguments
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Ldap] Add verbose ext-ldap error if present for easier debugging
| Q | A
| ------------- | ---
| Branch? | master (be careful when merging)
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? |
| Fixed tickets | #28149
| License | MIT
| Doc PR |
Added an optional message suffix if ldap_errno is not equals to 0
Commits
-------
761415fc1b Add verbose ext-ldap error if present for easier debugging
This PR was squashed before being merged into the 4.2-dev branch (closes#28521).
Discussion
----------
[Yaml] Added support for multiple files or directories in LintCommand
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28498
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10367
Commits
-------
d0f7950860 [Yaml] Added support for multiple files or directories in LintCommand
This PR was squashed before being merged into the 4.2-dev branch (closes#28522).
Discussion
----------
[Translation] Added support for multiple files or directories in XliffLintCommand
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/10368
Same approach of https://github.com/symfony/symfony/pull/28521
Commits
-------
88ec37bed7 [Translation] Added support for multiple files or directories in XliffLintCommand
This PR was merged into the 4.2-dev branch.
Discussion
----------
[FrameworkBundle] Register an identity translator as fallback
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27589
| License | MIT
| Doc PR | -
The same approach as https://github.com/symfony/symfony/pull/24358, suggested by @xabbuh here https://github.com/symfony/symfony/issues/27589#issuecomment-421542776
**Templating Engine Context**
The Form component can be used without the Translation component.
However, to be able to use the default form themes provided by the
`FrameworkBundle` you need to have the `translator` helper to be available.
This change ensure that there will always be a `translator` helper which
as a fallback will just return the message key if no translator is present.
Commits
-------
5330f2d017 [FrameworkBundle] Register an identity translator as fallback
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Contracts] fine tune composer.json declarations for suggest/provide
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
8a11e76c14 [Contracts] fine tune composer.json declarations for suggest/provide
This PR was merged into the 2.8 branch.
Discussion
----------
[Form] forward false label option to nested types
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/28469#discussion_r217880630
| License | MIT
| Doc PR |
This change does not fix any built-in Symfony form themes, but takes
into account the changes made in #28469 to allow third-party form themes
work properly.
Commits
-------
3247cdeea9 forward false label option to nested types
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Validator] Check the BIC country with symfony/intl
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28167
| License | MIT
| Doc PR | N/A
Check the BIC country code against the list from Intl component instead of a simple check alphabetical test.
This PR uses the Intl component which is not part of the required dependencies of the Validator component (https://github.com/symfony/validator/blob/master/composer.json): `symfony/intl` is only required for dev. So I'm making a PR against master because it may break existing code.
But `CountryValidator` does the same so it may not be an issue after all.
Commits
-------
27bd3a8192 [Validator] Check the BIC country with symfony/intl Fix#28167
This PR was squashed before being merged into the 3.4 branch (closes#28471).
Discussion
----------
[MonologBridge] Re-add option option to ignore empty context and extra data
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
In #11496, an option was added to `ConsoleFormatter` to ignore empty context and extra data. This setting was even turned on by default.
The `ConsoleHandler` was then overhauled in #21705. During this change, the option got lost.
Commits
-------
d1e7438605 [MonologBridge] Re-add option option to ignore empty context and extra data
This PR was merged into the 2.8 branch.
Discussion
----------
[Form] forward the invalid_message option in date types
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #5880
| License | MIT
| Doc PR |
Commits
-------
5318e2eb15 forward the invalid_message option in date types
The Form component can be used without the Translation component.
However, to be able to use the default form themes provided by the
FrameworkBundle you need to have the `translator` helper to be
available.
This change ensure that there will always be a `translator` helper which
as a fallback will just return the message key if no translator is
present.
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Validator] Allow Validator without the translator component
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28210
| License | MIT
| Doc PR | ø
Validator should be available without the Translator service. #28210 introduced a regression, it was not the case anymore:
```
You have requested a non-existent service "translator".
```
This fixes it.
Commits
-------
2dc92d7a4b Allow validator without the translator
This would fail if we were using strict mode with php 7, because true is
only a valid argument for php < 5.3.6.
This was changed from PHP_VERSION_ID >= 50400 ?
DEBUG_BACKTRACE_IGNORE_ARGS | DEBUG_BACKTRACE_PROVIDE_OBJECT : true in
#18272, but I do not understand why it was simplified, nor why
DEBUG_BACKTRACE_IGNORE_ARGS was there at that time.
This PR was merged into the 4.2-dev branch.
Discussion
----------
[FrameworkBundle] Ignore backslashes in service ids when using debug:container and debug:autowiring
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28143
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
Commits
-------
0aba355d8e [FrameworkBundle] Ignore backslashes in service ids when using `debug:container` and `debug:autowiring`
This change does not fix any built-in Symfony form themes, but takes
into account the changes made in #28469 to allow third-party form themes
work properly.
This PR was merged into the 4.2-dev branch.
Discussion
----------
[PhpUnitBridge] enable DebugClassLoader by default
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/issues/10360
With this PR, the phpunit-bridge will enable `DebugClassLoader` by default, making it do its job: throw deprecation notices at autoloading time. On top of #28329, this made me spot some glitches in the code base, fixed here also.
This can be disabled by configuring the listener in `phpunit.xml.dist` files, adding `<element key="debug-class-loader"><integer>0</integer></element>` next to `<element key="time-sensitive">...`.
Commits
-------
2fb11fce28 [PhpUnitBridge] enable DebugClassLoader by default
This PR was merged into the 4.2-dev branch.
Discussion
----------
[FrameworkBundle] bind "ContainerInterface $parameterBag" arguments to the "parameter_bag" service
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
2c428d130d [FrameworkBundle] bind "ContainerInterface $parameterBag" arguments to the "parameter_bag" service
This PR was squashed before being merged into the 4.2-dev branch (closes#28441).
Discussion
----------
[Messenger] simple refactoring to have a more readable code
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
<!--
A simple refactoring to have a more readable code
-->
Commits
-------
5f61a27db5 [Messenger] simple refactoring to have a more readable code
* 4.1:
[TwigBridge] fix lowest version of symfony/form
Think positive
KernelInterface can return null container
[DI] Detect circular references with ChildDefinition parent
[VarDumper] Fix global dump function return value for PHP7
[Ldap] Use shut up operator on connection errors at ldap_start_tls
Implement startTest rather than startTestSuite
[OptionsResolver] remove dead code and useless else
[HttpFoundation] don't override StreamedResponse::setNotModified()
Added relevent links for parsing to the phpdoc
Add stricter checking for valid date time string
Fix symfony/console (optional) dependency for MonologBridge
fix not displaying labels when value is false
[Form] Fix DateTimeType html5 input format
This PR was merged into the 4.1 branch.
Discussion
----------
[Form][TwigBridge] fix not displaying labels when value is false
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28198
| License | MIT
| Doc PR |
Commits
-------
c4a6c9fa00 fix not displaying labels when value is false
* 3.4:
Think positive
KernelInterface can return null container
[DI] Detect circular references with ChildDefinition parent
[VarDumper] Fix global dump function return value for PHP7
[Ldap] Use shut up operator on connection errors at ldap_start_tls
Implement startTest rather than startTestSuite
[OptionsResolver] remove dead code and useless else
[HttpFoundation] don't override StreamedResponse::setNotModified()
Added relevent links for parsing to the phpdoc
Add stricter checking for valid date time string
Fix symfony/console (optional) dependency for MonologBridge
[Form] Fix DateTimeType html5 input format
* 2.8:
KernelInterface can return null container
[Ldap] Use shut up operator on connection errors at ldap_start_tls
[HttpFoundation] don't override StreamedResponse::setNotModified()
Added relevent links for parsing to the phpdoc
Add stricter checking for valid date time string
[Form] Fix DateTimeType html5 input format
This PR was merged into the 3.4 branch.
Discussion
----------
Fix symfony/console (optional) dependency for MonologBridge
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Since 278c26f589, `ConsoleHandler` tries to pass a verbosity level into `Output::write()`.
In order to make this work, the change 749fba54f9 is required which was first released in 2.8.0.
When using MonologBridge ^3.3 with a lower version of symfony/console than 2.8, an `InvalidArgumentException` with the message `Unknown output type given` will be thrown.
Not sure how to add a test for this... 🤷♂️
Commits
-------
d6f5d6bccd Fix symfony/console (optional) dependency for MonologBridge
This PR was merged into the 3.4 branch.
Discussion
----------
[PhpUnitBridge] Implement startTest rather than startTestSuite
Passing a TestSuite instance to CoverageListenerTrait::testStart() will
have no effect.
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Closes#28481
Commits
-------
63671d1633 Implement startTest rather than startTestSuite
This PR was squashed before being merged into the 3.4 branch (closes#28497).
Discussion
----------
[VarDumper] Fix global dump function return value for PHP7
Retarget of PR #28491. Reposting description below, with relevant updates.
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
In 3.4, the global `dump()` helper function in the VarDumper component was updated to return the arguments passed in to it. However, due to reusing the argument variable in the function, this introduces a bug in PHP7 in the return value of the function.
The variable used in the `foreach` loop overwrites the value passed in by the first argument. In PHP5, this is okay. In PHP7, even though the argument is passed by value, the value returned by `func_get_args()` is affected by changes to the arguments inside the function. This is a change from PHP5.
From the documentation for [`func_get_args()`](http://php.net/manual/en/function.func-get-args.php):
> If the arguments are passed by reference, any changes to the arguments will be reflected in the values returned by this function. As of PHP 7 the current values will also be returned if the arguments are passed by value.
This PR simply changes the name of the variable used in the `foreach` loop. It also adds a test file to test the return value of the global `dump()` function.
This is my first contribution to Symfony, so please let me know if the issue should be resolved in a different manner, or if the test should be modified in any way.
Thanks,
Patrick
Commits
-------
0def211b9b [VarDumper] Fix global dump function return value for PHP7
This PR was merged into the 2.8 branch.
Discussion
----------
[HttpFoundation] don't override StreamedResponse::setNotModified()
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Alternative implementation to #27937, because `Response::setNotModified()` has been made final in 4.0 so we shouldn't override it.
Commits
-------
9ef7f7038d [HttpFoundation] don't override StreamedResponse::setNotModified()
This PR was merged into the 4.2-dev branch.
Discussion
----------
Trigger deprecation notices when inherited class calls parent method but misses adding new arguments
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
This Pull Request concern severals components, the purpose here is to notify in dev mode that in a case of inherit class, a function will have a new or severals arguments in Symfony 5.0, therefore not implement it is deprecated since Symfony 4.2
The function is made by these conditions :
1- ```(func_num_args() < $x)``` where [x] is the number of arguments we will have in Symfony 5.0
this check allow to verify that the arguments are missing
2- ```(__CLASS__ !== \get_class($this))```
this check allow to verify that the name of the class is different than the base class, therefore that we are in the child class
3- ```(__CLASS__ !== (new \ReflectionMethod($this, __FUNCTION__))->getDeclaringClass()->getName())```
this check allow to verify that the class of the current function is different than the base class, therefore the function has been rewrote into the child class
Code exemple :
```
public function method(/* void $myNewArgument = null */)
{
if ((func_num_args() < 1) && (__CLASS__ !== \get_class($this)) && (__CLASS__ !== (new \ReflectionMethod($this, __FUNCTION__))->getDeclaringClass()->getName())){
@trigger_error(sprintf('The "%s()" method will have one `void $myNewArgument = null` argument in version 5.0 and higher.Not defining it is deprecated since Symfony 4.2.', __METHOD__ ), E_USER_DEPRECATED);
}
// do something
}
```
The unit test are made by creating a child Class using for the tested function ```return parent::function()``` and by calling this child class and catching the expected depreciation message
Commits
-------
f75fffa997 Trigger deprecation notices when inherited class calls parent method but misses adding new arguments
This PR was merged into the 2.8 branch.
Discussion
----------
[Form] Fix DateTimeType html5 input format
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27233, #27254
| License | MIT
| Doc PR | N/A
Fix DateTimeType' HTML input format according to HTML specs. Currently `DateTimeType` produces html with format `yyyy-MM-dd'T'HH:mm:ssZ` but the HTML5 spec expects `yyyy-MM-dd'T'HH:mm:ss` (i.e. no `Z`). Chrome presents an empty date picker meaning edits or having a default date are broken.
Also the reverseTransform was expect to have a timezone attached, which it does not - and incorrectly marks it as being a UTC time in this case, instead of using the Transformers output TZ.
This is same as @franzwilding https://github.com/symfony/symfony/pull/27254 but with change to just straight use of `DateTime::format` and handling TZ in reverseTransform
Commits
-------
e21a1a4df1 Added relevent links for parsing to the phpdoc
4f06f1524d Add stricter checking for valid date time string
253d0a683b [Form] Fix DateTimeType html5 input format
This PR was squashed before being merged into the 4.2-dev branch (closes#28456).
Discussion
----------
[Cache][Contracts] We must save the item or the trait does not have any effect
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR |
Using the trait must result in that items gets saved.
We could use `saveDeferred` instead, it might be a performance improvement but you also may have side-effects. Say you are using two cache pool objects for the same storage.
Example use of the trait:
```php
use Psr\Cache\CacheItemInterface;
use Psr\Cache\CacheItemPoolInterface;
use Symfony\Contracts\Cache\CacheInterface;
use Symfony\Contracts\Cache\GetForCacheItemPoolTrait;
class AcmeCache implements CacheInterface
{
use GetForCacheItemPoolTrait;
private $cache;
public function __construct(CacheItemPoolInterface $cache)
{
$this->cache = $cache;
}
public function getItem(string $key): CacheItemInterface
{
return $this->cache->getItem($key);
}
public function save(CacheItemInterface $item): bool
{
return $this->cache->save($item);
}
}
```
Commits
-------
06cd8dca8f [Cache][Contracts] We must save the item or the trait does not have any effect
* 4.1:
[Console] Fix typo in tests
[Console] Correct Command::initialize() and InputInterface::bind() phpdoc regarding thrown exceptions
[Console] fixed corrupt error output for unknown multibyte short option
[Console] fixed PHPDoc for setArgument/setOption in InputInterface
Register the messenger data collector only when the profiler is enabled
[Intl] Blacklist Eurozone and United Nations in Region Data Generator
* 3.4:
[Console] Fix typo in tests
[Console] Correct Command::initialize() and InputInterface::bind() phpdoc regarding thrown exceptions
[Console] fixed corrupt error output for unknown multibyte short option
[Console] fixed PHPDoc for setArgument/setOption in InputInterface
[Intl] Blacklist Eurozone and United Nations in Region Data Generator
* 2.8:
[Console] Correct Command::initialize() and InputInterface::bind() phpdoc regarding thrown exceptions
[Console] fixed corrupt error output for unknown multibyte short option
[Console] fixed PHPDoc for setArgument/setOption in InputInterface
[Intl] Blacklist Eurozone and United Nations in Region Data Generator
Since 278c26f589, `ConsoleHandler` tries to pass a verbosity level into `Output::write()`.
In order to make this work, the change 749fba54f9 is required which was first released in 2.8.0.
When using MonologBridge ^3.3 with a lower version of symfony/console than 2.8, an `InvalidArgumentException` with the message `Unknown output type given` will be thrown.
Not sure how to add a test for this... 🤷♂️ :
This PR was squashed before being merged into the 4.2-dev branch (closes#28373).
Discussion
----------
[Console] Support max column width in Table
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #22156, #27832
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/issues/10300
Continuation of #22225 to better preserve spaces (which preserves background colors), using `wordwrap` it caused some issues.
Also the wrapping was plain wrong by not taking the current line length into account.
While at it, it comes with `Table` integration :)
Given
```php
$table = new Table($output);
$table->setColumnMaxWidth(0, 2);
$table->setRow(0, ['pre <error>foo bar baz</error> post']);
$table->render();
$table = new Table($output);
$table->setColumnMaxWidth(0, 3);
$table->setRow(0, ['pre <error>foo bar baz</error> post']);
$table->render();
$table = new Table($output);
$table->setColumnMaxWidth(0, 4);
$table->setRow(0, ['pre <error>foo bar baz</error> post']);
$table->render();
```
![image](https://user-images.githubusercontent.com/1047696/45101516-f19b5880-b12b-11e8-825f-6a1d84f68f47.png)
Commits
-------
175f68f [Console] Support max column width in Table
This PR was merged into the 4.2-dev branch.
Discussion
----------
Remove all usages of call_user_func_array()
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Because it's cleaner :) (and it saves creating one extra dummy array)
Commits
-------
b2718d7666 Remove all usages of call_user_func_array()
This PR was merged into the 2.8 branch.
Discussion
----------
[Console] Document what is validated before and after Command::initialize()
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #26611
| License | MIT
| Doc PR | n/a
Commits
-------
b1aff99 [Console] Correct Command::initialize() and InputInterface::bind() phpdoc regarding thrown exceptions
This PR was merged into the 2.8 branch.
Discussion
----------
[Intl] Blacklist Eurozone and United Nations in Region Data Generator
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28260
| License | MIT
| Doc PR | -
Commits
-------
e2e4049721 [Intl] Blacklist Eurozone and United Nations in Region Data Generator
This PR was merged into the 4.2-dev branch.
Discussion
----------
[VarExporter] throw component-specific exceptions
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This makes "serializing/unserializing" with the component diverge a bit from native serialize/unserialize (wich can throw plain "Exception" instances), but I think we should still do it.
Commits
-------
2c444927bc [VarExporter] throw component-specific exceptions
This PR was squashed before being merged into the 2.8 branch (closes#28393).
Discussion
----------
[Console] fixed corrupt error output for unknown multibyte short option
| Q | A
| ------------- | ---
| Branch? | 2.8 <!-- see below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #28320 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | - <!-- required for new features -->
[Console] Fixed#28320 by using mb_substr instead of index access
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
0f86156 [Console] fixed corrupt error output for unknown multibyte short option
This PR was squashed before being merged into the 2.8 branch (closes#28374).
Discussion
----------
[Console] fixed PHPDoc for setArgument/setOption in InputInterface
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28354
| License | MIT
| Doc PR |
Methods now accept a value of any type except objects not implementing __toString().
**Example use case:** when using array arguments/options I can't set them programmatically without getting errors about type mismatch (from the IDE). With this patch it now works as expected.
Commits
-------
61529f3cd7 [Console] fixed PHPDoc for setArgument/setOption in InputInterface
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Change AmqpExt classes constructor signature
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | yes
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
This pull requests does 2 things:
* It makes `Connection` a first argument of AmqpExt classes. I think it makes sense as this is the most important argument for those classes.
* As the `Serializer` is now a second argument, I propose to make it optional and use the default serializer that we've added recently if `null` (`Serializer::create()`)
It makes the component even more user friendly when not using Symfony full stack (and provide good defaults).
Commits
-------
2d55ae5212 [Messenger] changed AmqpExt classes constructor signature
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Uses a messenger serializer, not an individual encoder/decoder
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ø
| License | MIT
| Doc PR | Will come
Makes the component-based even simpler.
**Before**
```php
$encoderDecoder = Serializer::create();
$middleware = [new SendMessageMiddleware(new SenderLocator([
Message::class => new AmqpTransport($encoderDecoder, $encoderDecoder, $connection),
]))];
```
**After**
```php
$middleware = [new SendMessageMiddleware(new SenderLocator([
Message::class => new AmqpTransport(Serializer::create(), $connection),
]))];
```
Commits
-------
5b93f5f45e Uses a messenger serializer, not an individual encoder/decoder
This PR was merged into the 4.2-dev branch.
Discussion
----------
[WebServerBundle] Add support for Xdebug's Profiler
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | /
| License | MIT
| Doc PR | /
> Xdebug's Profiler is a powerful tool that gives you the ability to analyze your PHP code and determine bottlenecks or generally see which parts of your code are slow and could use a speed boost.
https://xdebug.org/docs/profiler
When we run/start the web server, it would be useful to enable the trigger for the Xdebug's Profiler. That means we could easily trigger the creation of a Xdebug profile and analysing it [thanks to PhpStorm](https://www.jetbrains.com/help/phpstorm/analyzing-xdebug-profiling-data.html) which provides an **Execution Statistics** panel (examine the summary information about execution metrics of every called function) and a **Call Tree** panel (explore the execution paths of all called functions). You can see these two panels in action [here](https://youtu.be/_ua_O01IICg?t=1m22s) for a better understanding.
Commits
-------
0f4c0a6eaf Add support for Xdebug Profiler
This PR was merged into the 3.4 branch.
Discussion
----------
[Controller][ServiceValueResolver] Making method access case insensitive
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #28254
| License | MIT
| Doc PR | -
Fix#28254 by making the method access insensitive in `ServiceValueResolver`.
Commits
-------
cc6f82769b [Controller][ServiceValueResolver] Making method access case insensitive
This PR was merged into the 2.8 branch.
Discussion
----------
[Console] Fix SymfonyQuestionHelper::askQuestion() with choice value as default
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/26885
| License | MIT
| Doc PR | n/a
There is an inconsistency between `SymfonyStyle::askQuestion(new ChoiceQuestion(...))` and `SymfonyStyle::choice(...)`, the former does not support to have a choice value as default instead of a choice key while the latter handles both.
This is causing an `undefined index` notice breaking interactive command testing, fixed here.
Commits
-------
c51dda0 [Console] Fix SymfonyQuestionHelper::askQuestion() with choice value as default
* 4.1:
[DI] configure inlined services before injecting them when dumping the container
Consistently throw exceptions on a single line
fix fopen calls
Update .editorconfig
* 3.4:
[DI] configure inlined services before injecting them when dumping the container
Consistently throw exceptions on a single line
fix fopen calls
Update .editorconfig
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Add a SenderLocator decoupled from ContainerInterface
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | upcoming
For handler locators, we have a generic `HandlerLocator` class that takes a simple mapping instead of a service locator. The same did not exist for sender locators. So, this PR adds this possibility as well. That allows for something like this:
```php
new MessageBus([
new SendMessageMiddleware(new SenderLocator([
Message::class => new AmqpTransport($encoderDecoder, $encoderDecoder, $connection),
])),
new HandleMessageMiddleware(new HandlerLocator([
Message::class => new MessageHandler(),
])),
]);
```
Commits
-------
e658e155aa [Messenger] added a SenderLocator decoupled from ContainerInterface
This PR was merged into the 4.2-dev branch.
Discussion
----------
[TwigBundle] Using Twig template name syntax in form_theme example
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Minor tweak to remove the `symfony/templating` syntax.
Commits
-------
ce653f274b Using Twig template name syntax in form_theme example
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger][Profiler] Trace middleware execution
| Q | A
| ------------- | ---
| Branch? | master <!-- see below -->
| Bug fix? | no
| New feature? | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | part of #27262 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
This is a start for #27262 with:
- traceable Messenger middlewares
- ~~a dedicated category for http kernel controller args resolvers~~ => See #28387
<img width="1071" alt="screenshot 2018-05-20 a 12 23 55" src="https://user-images.githubusercontent.com/2211145/40278071-98c04924-5c2a-11e8-9770-d78ac62d2c16.PNG">
Messenger middleware are traced, with bus info (if not shared accros buses):
<img width="1069" alt="screenshot 2018-05-20 a 12 28 15" src="https://user-images.githubusercontent.com/2211145/40278073-9e6979f4-5c2a-11e8-9657-ee3aa057a5be.PNG">
Another possibility is to use the middleware id instead of the class (with or without extra bus info?):
<img width="1074" alt="screenshot 2018-05-20 a 12 32 24" src="https://user-images.githubusercontent.com/2211145/40278074-9e85f43a-5c2a-11e8-9f13-ad41de342079.PNG">
(_of course, collected times are faked here using `usleep` in the traceable middleware_)
Commits
-------
e974f67b1f [Messenger][Profiler] Trace middleware execution
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Messenger] Change exceptions to use component's one
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
-->
Commits
-------
4e0e5e5fdb [Messenger] changed exceptions to use component's one
This PR was merged into the 4.2-dev branch.
Discussion
----------
[HttpKernel][Profiler] Add arg value resolver category in performances panel
| Q | A
| ------------- | ---
| Branch? | master <!-- see below -->
| Bug fix? | no
| New feature? | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | part of #27262 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Extracted from https://github.com/symfony/symfony/pull/27321
<img width="1071" alt="screenshot 2018-05-20 a 12 23 55" src="https://user-images.githubusercontent.com/2211145/40278071-98c04924-5c2a-11e8-9770-d78ac62d2c16.PNG">
Commits
-------
b24e0543e0 [HttpKernel][Profiler] Add arg value resolver category in performances panel
* 4.1:
[appveyor] fix
[DI] Fix dumping some complex service graphs
Revert "minor #28321 [Routing] Fixed the interface description of the url generator interface (Toflar)"
Fixed caching of templates in default path on cache warmup
added missing LICENSE file
remove cache warmers when Twig cache is disabled
[Workflow] Make sure we do not run the next transition on an updated state
change baseUrl to basePath to fix wrong profiler url
[HttpKernel][FrameworkBundle] Fix escaping of serialized payloads passed to test clients
chore: rename Appveyor filename
Fixed the interface description of the url generator interface
Format file size in validation message according to binaryFormat option
* 3.4:
[appveyor] fix
Revert "minor #28321 [Routing] Fixed the interface description of the url generator interface (Toflar)"
Fixed caching of templates in default path on cache warmup
remove cache warmers when Twig cache is disabled
[HttpKernel][FrameworkBundle] Fix escaping of serialized payloads passed to test clients
chore: rename Appveyor filename
Fixed the interface description of the url generator interface
Format file size in validation message according to binaryFormat option
* 2.8:
[appveyor] fix
Revert "minor #28321 [Routing] Fixed the interface description of the url generator interface (Toflar)"
remove cache warmers when Twig cache is disabled
[HttpKernel][FrameworkBundle] Fix escaping of serialized payloads passed to test clients
chore: rename Appveyor filename
Fixed the interface description of the url generator interface
Format file size in validation message according to binaryFormat option