This PR was merged into the 2.7 branch.
Discussion
----------
[HttpFoundation] Add `use_strict_mode` in validOptions for session
| Q | A
| ------------- | ---
| Branch? | 3.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #9258
| License | MIT
| Doc PR |
PHP ini `session.use_strict_mode` was added in PHP 5.5.2 so I didn't target 2.8 as this still uses PHP 5.3. https://secure.php.net/manual/en/session.configuration.php#ini.session.use-strict-mode
Commits
-------
130ee327d4 Add `use_strict_mode` in validOptions for session
This PR was merged into the 2.7 branch.
Discussion
----------
[HttpFoundation] Fix and test status codes according to IANA's data
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
This PR updates HTTP status code according to values [standardized by the IANA](https://www.iana.org/assignments/http-status-codes/http-status-codes.xml). It also add a test to check the conformance (we'll also be notified when a code is added, ~~removed~~ or modified).
All credits go to @fcabralpacheco for is work in Zend Diactoros: https://github.com/zendframework/zend-diactoros/pull/234
Commits
-------
72d25ccca7 [HttpFoundation] Fix and test status codes according to IANA's data
This PR was merged into the 3.3-dev branch.
Discussion
----------
[Bridge] [Twig] Get and flush only flash sessions you need in getFlashes method
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no ?!
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | #22355
| License | MIT
| Doc PR | symfony/symfony-docs
PR to get only flash sessions you need without flush everything
Commits
-------
ff82cb29bb [Bridge] [Twig] AppVariable: get and flush only flash sessions you need in getFlashes method
* 3.2:
don't keep internal state between parser runs
Add \Traversable typehint to phpdoc
[ExpressionLanguage] Avoid dependency on ctype
Moved ->setDate() before the deprecation handling.
[Debug] Fix php notice
[VarDumper] Relax tests to adapt for php 7.1rc4
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle] Add autowiring alias for Stopwatch
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Following in the footsteps of #22098 to add aliases for various services, this adds an alias for `Symfony\Component\Stopwatch\Stopwatch`.
Commits
-------
707f74b50f [FrameworkBundle] Add autowiring alias for Stopwatch
This PR was submitted for the master branch but it was merged into the 2.7 branch instead (closes#22303).
Discussion
----------
Add \Traversable typehint to phpdoc
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
Most of the times you use a DataMapperInterface, the first thing you do on the `$forms` parameter is `iterator_to_array`. However, as that variable is only hinted as `FormInterface[]`, and most IDE's and static analysers don't rely on code, but on the phpdoc...
Commits
-------
5310f11418 Add \Traversable typehint to phpdoc
This PR was merged into the 3.3-dev branch.
Discussion
----------
Add Kernel::getProjectDir()
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes/no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | not yet
`Kernel::getRootDir()` is misleading. It returns the path where `AppKernel.php` is stored, which is `app/` in Symfony 2/3, but `src/` in Symfony 4. But most of the time, we are using `getRootDir()` to get the project root dir, so `%kernel.root_dir%/../` is a common idiom.
Changing the value of `getRootDir()` would be a hard BC break, so I propose to create a new method, `getProjectDir()` to "replace" `getRootDir()` gradually.
Commits
-------
1f680ccb2d added Kernel::getProjectDir()
This PR was merged into the 3.3-dev branch.
Discussion
----------
[DI] Enhance wording of autowiring exceptions
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
> Cannot autowire service "j": argument "$i" of method "Symfony\Component\DependencyInjection\Tests\Compiler\J::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\I" but no such service exists. You should maybe alias this class to the existing "i" service; or type-hint against interface "Symfony\Component\DependencyInjection\Tests\Compiler\IInterface" instead.
Commits
-------
da792b2ff7 [DI] Enhance wording of autowiring exceptions
This PR was submitted for the 3.2 branch but it was merged into the 2.7 branch instead (closes#22325).
Discussion
----------
[ExpressionLanguage] Avoid ExpressionLanguage dependency on ctype
| Q | A
| ------------- | ---
| Branch? | 3.2
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | none
| License | MIT
| Doc PR | none
There is undocumented dependency on ctype extension in ExpressionLanguage. I've chosen to remove it rather than document as we're using ExpressionLanguage in phpMyAdmin and this is only dependency which needs ctype.
I'm submitting this against 3.2 to get this fix to released version sooner, but it can be without problems applied to master as well.
Commits
-------
81de5fef4b [ExpressionLanguage] Avoid dependency on ctype
This PR was merged into the 3.3-dev branch.
Discussion
----------
[HttpKernel] Skip ContainerAwareInterface::setContainer from service_arguments actions registration
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
As it would never be used
Commits
-------
ad59e1804f Skip ContainerAwareInterface::setContainer from service_arguments actions registration
This PR was merged into the 3.3-dev branch.
Discussion
----------
[HttpKernel] Resolve invokable controllers short notations using ServiceValueResolver
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22202
| License | MIT
| Doc PR | n/a
Register the service id as an alias of `id:__invoke` so that using the invokable short notation (id only) triggers the ServiceArgumentResolver.
Commits
-------
717fa85b91 Resolve invokable controllers short notations using ServiceValueResolver
This PR was merged into the 2.8 branch.
Discussion
----------
[VarDumper] Relax tests to adapt for php 7.1rc4
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22266
| License | MIT
| Doc PR | -
Commits
-------
3672c01e3c [VarDumper] Relax tests to adapt for php 7.1rc4
This PR was squashed before being merged into the 3.2 branch (closes#22304).
Discussion
----------
Moved $this->setDate() before the deprecation handling.
| Q | A
| ------------- | ---
| Branch? | 3.2 <!-- see comment below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no?
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!--highly recommended for new features-->
<!--
- 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.
- Please fill in this template according to the PR you're about to submit.
- Replace this comment by a description of what your PR is solving.
-->
https://github.com/symfony/symfony/pull/22036 merged the patch into the wrong place; the `$this->setDate()` happens after the deprecation handling, so it does not always get called.
See also https://www.drupal.org/node/2712647?page=1#comment-12025349
Commits
-------
b6df4e7 Moved ->setDate() before the deprecation handling.
This PR was submitted for the 2.8 branch but it was merged into the 2.7 branch instead (closes#22307).
Discussion
----------
[Debug] Fix php notice
| 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 |
Of course autoloading of an empty string should not actually happen (fixed that in https://github.com/twigphp/Twig/pull/2438) but if it does happen it should not throw a php notice.
```
Notice: Uninitialized string offset 0
```
Commits
-------
e333a1a [Debug] Fix php notice
This PR was merged into the 3.3-dev branch.
Discussion
----------
[HttpKernel][FrameworkBundle] Dump container logs in Kernel, to have them also on errors
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Inspecting container failures without the logs is hard, let's have them at hand. This should not be the responsibility of a compiler pass.
Commits
-------
a8b83340bb [HttpKernel][FrameworkBundle] Dump container logs in Kernel, to have them also on errors
This PR was merged into the 3.3-dev branch.
Discussion
----------
[WebServerBundle] added a way to dump current status host/port/address when getting the status
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Now that the web server can run on an automatically chosen port, it's more complex to integrate it into tests (I want to run some functional tests locally).
The `server:status` command gives this information, but not in a machine-readable way.
I propose to add a `--filter` flag to fix that:
`./bin/console server:status --filter=address`
Commits
-------
b417b62a92 [WebServerBundle] added a way to dump current status host/port/address when getting the status
This PR was merged into the 3.3-dev branch.
Discussion
----------
[DI] Report cascades of autowiring error messages
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Enhance DX by reporting the cascade of errors that lead to an autowiring error, eg:
![capture du 2017-04-07 00-03-28](https://cloud.githubusercontent.com/assets/243674/24777441/ac1fb118-1b25-11e7-9459-ecdf13e79798.png)
Also contains a cleanup found along the way: processing of nested definitions should happen before the current one so that TypedReference are processed only once.
Commits
-------
6c0f5e3a6f [DI] Reporte cascades of autowiring error messages
This PR was merged into the 2.8 branch.
Discussion
----------
[HttpFoundation] Fix transient tests
| 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 | -
We need to call `time()` when creating `DateTime` objects so that the clock-mock system can work.
This fixes some newly introduced transient tests.
ping @mpdude FYI
Commits
-------
9f7a6bb5e5 [HttpFoundation] Fix transient tests
This PR was merged into the 3.3-dev branch.
Discussion
----------
[HttpKernel] Fix missing use statement in RegisterControllerArgumentLocatorPass
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes (master only)
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Maybe meaning that this one misses a test case ensuring parent definitions are indeed took into account
Commits
-------
dc2fe60 [HttpKernel] Fix missing use statement in RegisterControllerArgumentLocatorsPass
This PR was merged into the 2.8 branch.
Discussion
----------
[DI] Fix second auto-registration
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22309
| License | MIT
| Doc PR | -
My bad
Commits
-------
c02de845e7 [DI] Fix second auto-registration