This PR was squashed before being merged into the 3.2-dev branch (closes#18533).
Discussion
----------
[FrameworkBundle] Wire PhpArrayAdapter with a new cache warmer for annotations
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | WIP
| Fixed tickets | -
| License | MIT
| Doc PR | -
Depends on https://github.com/symfony/symfony/pull/18825 and https://github.com/symfony/symfony/pull/18823
This PR implements the usage of the new OpCacheAdapter in the annotations caching system. The idea to use this adapter as much as possible in Symfony (validator, serializer, ...). These other implementations will be the object of different PRs.
Commits
-------
f950a2b [FrameworkBundle] Wire PhpArrayAdapter with a new cache warmer for annotations
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Filesystem] Add a cross-platform readlink method
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
`readlink()` and `realpath()` have a completely different behavior under Windows and Unix:
- `realpath()` resolves recursively the children links of a link until a final target is found on Unix and resolves only the next link on Windows ;
- `readlink()` resolves recursively the children links of a link until a final target is found on Windows and resolves only the next link on Unix ;
I propose to solve this by implementing a helper method in the Filesystem component that would behave always the same way under all platforms.
Commits
-------
c36507e [Filesystem] Add a cross-platform readlink/realpath methods for nested links
This PR was squashed before being merged into the 2.7 branch (closes#19446).
Discussion
----------
[Console] Overcomplete argument exception message tweak.
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
Updates the exception message when to many arguments are passed.
From;
```php
'Too many arguments.'
```
To:
```php
'No argument expected, got "foo".'
// or
'Too many arguments, expected arguments "foo".'
// or
'Too many arguments, expected arguments "foo, bar".'
// ... turtles all the way down
```
Commits
-------
7af59cd [Console] Overcomplete argument exception message tweak.
* 3.1:
[TwigBundle] Removed redundant return statement.
enable property info
[Cache] Fix default lifetime being ignored
[DependencyInjection] Fixed deprecated default message template with XML
Reference the actual location of the documentation
[TwigBridge] Removed extra arguments in 2 places.
[Cache] Fix incorrect timestamps generated by FilesystemAdapter
[Process] Fix write access check for pipes on Windows
[HttpKernel] Use flock() for HttpCache's lock files
Conflicts:
src/Symfony/Component/Cache/Adapter/FilesystemAdapter.php
* 3.0:
[TwigBundle] Removed redundant return statement.
[DependencyInjection] Fixed deprecated default message template with XML
[TwigBridge] Removed extra arguments in 2 places.
[Process] Fix write access check for pipes on Windows
[HttpKernel] Use flock() for HttpCache's lock files
* 2.8:
[TwigBundle] Removed redundant return statement.
[DependencyInjection] Fixed deprecated default message template with XML
[TwigBridge] Removed extra arguments in 2 places.
[Process] Fix write access check for pipes on Windows
[HttpKernel] Use flock() for HttpCache's lock files
* 2.7:
[TwigBundle] Removed redundant return statement.
[TwigBridge] Removed extra arguments in 2 places.
[Process] Fix write access check for pipes on Windows
[HttpKernel] Use flock() for HttpCache's lock files
This PR was merged into the 3.2-dev branch.
Discussion
----------
[VarDumper] Dumping exceptions is now more compact
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | -
| License | MIT
| Doc PR | -
Before:
![before](https://cloud.githubusercontent.com/assets/243674/16578686/2c7285b0-429c-11e6-9139-293e0c899d43.png)
Commits
-------
19e9cbe [VarDumper] Dumping exceptions is now more compact
This PR was merged into the 2.7 branch.
Discussion
----------
[HttpKernel] Use flock() for HttpCache's lock files
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | #16777, #15813 and #16312 are also related
| License | MIT
| Doc PR |
When a PHP process crashes or terminates (maybe the OOM killer kicks in or other bad things ™️ happen) while the `HttpCache` holds a `.lck` file, that lock file may not get `unlink()`ed.
The result is that other requests trying to access this cache entry will see a few seconds delay while waiting for the lock; they will eventually continue but send 503 status codes along with the response. The sudden buildup of PHP processes caused by the additional delay may cause further problems (sudden load increase).
As `LockHandler` is using `flock()`-based locking, locks should be released by the OS when the PHP process terminates.
I wrote this as bugfix against 2.7 because every once in a while I encounter situations (not always reproducible) where `.lock` files are left over and keep the cache locked.
Commits
-------
2668edd [HttpKernel] Use flock() for HttpCache's lock files
This PR was merged into the 2.7 branch.
Discussion
----------
[Process] Fix write access check for pipes on Windows
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19336, #19416
| License | MIT
| Doc PR | -
Commits
-------
66e694e [Process] Fix write access check for pipes on Windows
* 3.1:
[Console] Application update PHPDoc of add and register methods
[Config] Extra tests for Config component
Fixed bugs in names of classes and methods.
[DoctrineBridge] Fixed php doc
[FrameworkBundle] Fixed parameters number mismatch declaration
[BrowserKit] Added test for followRedirect method (POST method)
Fix the money form type render with Bootstrap3
[BrowserKit] Uppercase the "GET" method in redirects
[DomCrawler] Inherit the namespace cache in subcrawlers
[WebProfilerBundle] Fixed JSDoc parameter definition
[HttpFoundation] HttpCache refresh stale responses containing an ETag
Conflicts:
src/Symfony/Component/Console/Application.php
* 3.0:
[Console] Application update PHPDoc of add and register methods
[Config] Extra tests for Config component
Fixed bugs in names of classes and methods.
[DoctrineBridge] Fixed php doc
[FrameworkBundle] Fixed parameters number mismatch declaration
[BrowserKit] Added test for followRedirect method (POST method)
Fix the money form type render with Bootstrap3
[BrowserKit] Uppercase the "GET" method in redirects
[DomCrawler] Inherit the namespace cache in subcrawlers
[WebProfilerBundle] Fixed JSDoc parameter definition
[HttpFoundation] HttpCache refresh stale responses containing an ETag
* 2.8:
[Console] Application update PHPDoc of add and register methods
[Config] Extra tests for Config component
Fixed bugs in names of classes and methods.
[DoctrineBridge] Fixed php doc
[FrameworkBundle] Fixed parameters number mismatch declaration
[BrowserKit] Added test for followRedirect method (POST method)
Fix the money form type render with Bootstrap3
[BrowserKit] Uppercase the "GET" method in redirects
[DomCrawler] Inherit the namespace cache in subcrawlers
[WebProfilerBundle] Fixed JSDoc parameter definition
[HttpFoundation] HttpCache refresh stale responses containing an ETag
Conflicts:
src/Symfony/Component/Finder/Tests/Shell/CommandTest.php
* 2.7:
[Console] Application update PHPDoc of add and register methods
[Config] Extra tests for Config component
Fixed bugs in names of classes and methods.
[DoctrineBridge] Fixed php doc
[FrameworkBundle] Fixed parameters number mismatch declaration
[BrowserKit] Added test for followRedirect method (POST method)
Fix the money form type render with Bootstrap3
[BrowserKit] Uppercase the "GET" method in redirects
[WebProfilerBundle] Fixed JSDoc parameter definition
[HttpFoundation] HttpCache refresh stale responses containing an ETag
Conflicts:
src/Symfony/Component/BrowserKit/Tests/ClientTest.php
src/Symfony/Component/Security/Acl/Resources/bin/generateSql.php
This PR was squashed before being merged into the 2.7 branch (closes#19389).
Discussion
----------
[Console] Application update PHPDoc of add and register methods
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
The [PHPDoc](https://github.com/symfony/symfony/blob/2.7/src/Symfony/Component/Console/Application.php#L354) states the method will always return a command, but it doesn't. Since [Application::register](https://github.com/symfony/symfony/blob/2.7/src/Symfony/Component/Console/Application.php#L328) returns the result of `add` directly is also doesn't always return the command (as its PHPDoc states).
Commits
-------
6f0474f [Console] Application update PHPDoc of add and register methods
This PR was squashed before being merged into the 2.7 branch (closes#19399).
Discussion
----------
[Config] Extra tests for Config component
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Commits
-------
d0f4434 [Config] Extra tests for Config component
This PR was squashed before being merged into the 2.7 branch (closes#19392).
Discussion
----------
[BrowserKit] Added test for followRedirect method (POST method)
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Test covers 'else' branches in these conditions:
```php
if (in_array($this->internalResponse->getStatus(), array(302, 303))) {
$method = 'get';
$files = array();
$content = null;
} else {
$method = $request->getMethod();
$files = $request->getFiles();
$content = $request->getContent();
}
if ('get' === strtolower($method)) {
// Don't forward parameters for GET request as it should reach the redirection URI
$parameters = array();
} else {
$parameters = $request->getParameters();
}
```
Commits
-------
2ace5d8 [BrowserKit] Added test for followRedirect method (POST method)
This PR was merged into the 2.7 branch.
Discussion
----------
[2.7] [HttpFoundation] HttpCache refresh stale responses containing an ETag
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? |no
| BC breaks? |no
| Deprecations? |no
| Tests pass? | yes
| Fixed tickets | #19390, #6746
| License | MIT
| Doc PR |
This PR is the replacement of #19391, which points at the wrong branch.
Commits
-------
96df6b9 [HttpFoundation] HttpCache refresh stale responses containing an ETag
This PR was merged into the 2.8 branch.
Discussion
----------
[DomCrawler] Inherit the namespace cache in subcrawlers
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #12298
| License | MIT
| Doc PR | n/a
This inherits any already discovered/registered namespace with subcrawlers, improving performance when using namespaces.
I submitted to 2.8 rather than 2.7, because the namespace mapping feature was actually buggy in 2.x, because of the fact that nodes could belong to different documents in the same Crawler while the namespace map was shared. The fact that the map was not inherited in subcrawler mitigated this issue (by reducing changes to have multiple documents in the same subcrawler). 2.8 deprecated this possibility to have multiple documents, so I'm fine with applying this here.
Note that the subcrawler inherits the namespace cache at the time it is created, but the cache is not shared between instance (so if a subcrawler discovers an additional namespace of the document, it will not be available for the parent crawler of other subcrawlers of the parent). Sharing the cache would be totally possible (as they share the same document anyway) and would make the experience even better (removing the need to ensure that the root crawler discovers namespace before filtering). But it would require moving from an array to an object. I'm not sure we want to do this in a patch release. What do you think @symfony/deciders ?
Commits
-------
e89c758 [DomCrawler] Inherit the namespace cache in subcrawlers
* 3.1:
fixed bad merge
Fix PHP 7.1 related failures
[VarDumper] Fix for 7.1
fixed CS
Added class existence check if is_subclass_of() fails in compiler passes
Fix the DBAL session handler version check for Postgresql
* 3.0:
Fix PHP 7.1 related failures
[VarDumper] Fix for 7.1
fixed CS
Added class existence check if is_subclass_of() fails in compiler passes
Fix the DBAL session handler version check for Postgresql
* 2.8:
Fix PHP 7.1 related failures
[VarDumper] Fix for 7.1
fixed CS
Added class existence check if is_subclass_of() fails in compiler passes
Fix the DBAL session handler version check for Postgresql
This PR was squashed before being merged into the 3.2-dev branch (closes#19276).
Discussion
----------
[ClassLoader] Add ClassCollectionLoader::inline() to generate inlined-classes files
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Unfortunately, can't be tested because the method relies too much on side effects.
Coupled with https://github.com/sensiolabs/SensioDistributionBundle/pull/272, allows inlining `ClassCollectionLoader` itself into the `bootstrap.php.cache` file.
Commits
-------
88fdcea [ClassLoader] Add ClassCollectionLoader::inline() to generate inlined-classes files
This PR was merged into the 2.8 branch.
Discussion
----------
Added class existence check if is_subclass_of() fails in compiler passes
| Q | A
| ------------- | ---
| Branch? | 2.8-3.1
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
If you create an event subscriber and make typo in file name it will cause next error:
```
[InvalidArgumentException]
Service "event.notification_subscriber" must implement interface "Symfony\Component\EventDispatcher\EventSubscriberInterface".
```
That's because of `is_subclass_of()` fails on class absentee. I made error message more clear.
Commits
-------
72db6e7 Added class existence check if is_subclass_of() fails in compiler passes
* 3.1:
[VarDumper] Fix dumping jsons casted as arrays
PassConfig::getMergePass is not an array
Revert "bug #19114 [HttpKernel] Dont close the reponse stream in debug (nicolas-grekas)"
[Serializer] Include the format in the cache key
Fix the retrieval of the last username when using forwarding
[Yaml] Fix PHPDoc of the Yaml class
[HttpFoundation] Add OPTIONS and TRACE to the list of safe methods
Update getAbsoluteUri() for query string uris
Conflicts:
src/Symfony/Component/DependencyInjection/Compiler/PassConfig.php
src/Symfony/Component/HttpFoundation/Tests/RequestTest.php
* 3.0:
[VarDumper] Fix dumping jsons casted as arrays
PassConfig::getMergePass is not an array
Revert "bug #19114 [HttpKernel] Dont close the reponse stream in debug (nicolas-grekas)"
Fix the retrieval of the last username when using forwarding
[Yaml] Fix PHPDoc of the Yaml class
[HttpFoundation] Add OPTIONS and TRACE to the list of safe methods
Update getAbsoluteUri() for query string uris
Conflicts:
src/Symfony/Component/Yaml/Yaml.php
* 2.8:
[VarDumper] Fix dumping jsons casted as arrays
PassConfig::getMergePass is not an array
Revert "bug #19114 [HttpKernel] Dont close the reponse stream in debug (nicolas-grekas)"
Fix the retrieval of the last username when using forwarding
[Yaml] Fix PHPDoc of the Yaml class
[HttpFoundation] Add OPTIONS and TRACE to the list of safe methods
Update getAbsoluteUri() for query string uris
* 2.7:
[VarDumper] Fix dumping jsons casted as arrays
PassConfig::getMergePass is not an array
Revert "bug #19114 [HttpKernel] Dont close the reponse stream in debug (nicolas-grekas)"
Fix the retrieval of the last username when using forwarding
[Yaml] Fix PHPDoc of the Yaml class
[HttpFoundation] Add OPTIONS and TRACE to the list of safe methods
Update getAbsoluteUri() for query string uris
This PR was squashed before being merged into the 2.7 branch (closes#19343).
Discussion
----------
PassConfig::getMergePass is not an array
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Just a minor glitch my IDE noticed :-)
Commits
-------
edbefac PassConfig::getMergePass is not an array
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Serializer] Argument objects
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | TODO
| Fixed tickets | none
| License | MIT
| Doc PR | TODO
Assuming with have the two following entities:
```php
namespace AppBundle\Entity;
class Dummy
{
public function __construct(int $id, string $name, string $email, AnotherDummy $anotherDummy)
{
$this->id = $id;
$this->name = $name;
$this->email = $email;
$this->anotherDummy = $anotherDummy;
}
}
class AnotherDummy
{
public function __construct(int $id, string $uuid, bool $isEnabled)
{
$this->id = $id;
$this->uuid = $uuid;
$this->isEnabled = $isEnabled;
}
}
```
Doing the following will fail:
```php
$serializer->denormalize(
[
'id' => $i,
'name' => 'dummy',
'email' => 'du@ex.com',
'another_dummy' => [
'id' => 1000 + $i,
'uuid' => 'azerty',
'is_enabled' => true,
],
],
\AppBundle\Entity\Dummy::class
);
```
with a type error, because the 4th argument passed to `Dummy::__construct()` will be an array. The following patch checks if the type of the argument is an object, and if it is tries to denormalize that object as well.
I'm not sure if it's me missing something or this is a use case that has been omitted (willingly or not), but if it's a valuable patch I would be happy to work on finishing it.
Commits
-------
988eba1 fix tests
98bcb91 Merge pull request #1 from dunglas/theofidry-feature/param-object
7b5d55d Prevent BC in instantiateObject
e437e04 fix reflection type
3fe9802 revert CS
5556fa5 fix
d4cdb00 fix CS
93608dc Add deprecation message
f46a176 Apply patch
f361e52 fix tests
4884a2e f1
e64e999 Address comments
e99a90b Add tests
7bd4ac5 Test
This PR was squashed before being merged into the 2.7 branch (closes#19321).
Discussion
----------
[HttpFoundation] Add OPTIONS and TRACE to the list of safe methods
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
According to [RFC 7231](https://tools.ietf.org/html/rfc7231#section-8.1.3) `OPTIONS` and `TRACE` are safe methods.
Commits
-------
1404607 [HttpFoundation] Add OPTIONS and TRACE to the list of safe methods
This PR was merged into the 2.7 branch.
Discussion
----------
[BrowserKit] Update Client::getAbsoluteUri() for query string only URIs
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19303
| License | MIT
| Doc PR | -
This PR allows BrowserKit to treat a value containing only query string parameters the same way anchor/hash values are treated when passed as a URI argument to the getAbsoluteUri() method. Helps when encountering sites that force a redirect with a location header value containing only a query string.
Commits
-------
965408f Update getAbsoluteUri() for query string uris
This PR was squashed before being merged into the 3.2-dev branch (closes#19322).
Discussion
----------
[HttpFoundation] Add Request::isMethodIdempotent method
| 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
Addd a new method in the spirit of `isMethodSafe` to know if the current method is idempotent according to RFCs.
Commits
-------
44df6a4 [HttpFoundation] Add Request::isMethodIdempotent method
* 3.1:
[HttpKernel] fixed internal subrequests having an if-modified-since-header
[Security] Fix deprecated usage of DigestAuthenticationEntryPoint::getKey() in DigestAuthenticationListener
[Validator] Added additional MasterCard range to the CardSchemeValidator
Make the exception message more clear.
[Form] fixed bug - name in ButtonBuilder
[DoctrineBridge] added missing error code for constraint.
[ClassLoader] Fix declared classes being computed when not needed
[varDumper] Fix missing usage of ExceptionCaster::$traceArgs
* 3.0:
[HttpKernel] fixed internal subrequests having an if-modified-since-header
[Security] Fix deprecated usage of DigestAuthenticationEntryPoint::getKey() in DigestAuthenticationListener
[Validator] Added additional MasterCard range to the CardSchemeValidator
Make the exception message more clear.
[Form] fixed bug - name in ButtonBuilder
[DoctrineBridge] added missing error code for constraint.
[ClassLoader] Fix declared classes being computed when not needed
[varDumper] Fix missing usage of ExceptionCaster::$traceArgs
* 2.8:
[HttpKernel] fixed internal subrequests having an if-modified-since-header
[Security] Fix deprecated usage of DigestAuthenticationEntryPoint::getKey() in DigestAuthenticationListener
[Validator] Added additional MasterCard range to the CardSchemeValidator
Make the exception message more clear.
[Form] fixed bug - name in ButtonBuilder
[DoctrineBridge] added missing error code for constraint.
[ClassLoader] Fix declared classes being computed when not needed
[varDumper] Fix missing usage of ExceptionCaster::$traceArgs
Conflicts:
src/Symfony/Bridge/Doctrine/Validator/Constraints/UniqueEntityValidator.php
src/Symfony/Component/ClassLoader/ClassCollectionLoader.php
* 2.7:
[HttpKernel] fixed internal subrequests having an if-modified-since-header
[Validator] Added additional MasterCard range to the CardSchemeValidator
Make the exception message more clear.
[Form] fixed bug - name in ButtonBuilder
[ClassLoader] Fix declared classes being computed when not needed
This PR was merged into the 2.7 branch.
Discussion
----------
[ClassLoader] Fix declared classes being computed when not needed
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
d513eae [ClassLoader] Fix declared classes being computed when not needed
This PR was merged into the 2.7 branch.
Discussion
----------
[Validator] Added additional MasterCard range to the CardSchemeValidator
From October 2016 MasterCard will introduce a new card range, 222100 through 272099.
See: https://www.mctestcards.com/ (click the help in top right)
This implements the additional regex for validation to succeed, and some additional unit tests for this new range.
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Commits
-------
4d68f56 [Validator] Added additional MasterCard range to the CardSchemeValidator
This PR was squashed before being merged into the 2.7 branch (closes#19290).
Discussion
----------
[HttpKernel] fixed internal subrequests having an if-modified-since-header
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
As the InlineFragmentRenderer has no access to a cached copy of a subrequest's target and hence couldn't handle a response with a HTTP status code of 304 (not modified), it makes no sense to send an if-not-modified-since header.
Commits
-------
e90038c [HttpKernel] fixed internal subrequests having an if-modified-since-header
From October 2016 MasterCard will introduce a new card range,
222100 through 272099.
See: https://www.mctestcards.com/ (click the help in top right)
Implements unit tests and validation for this new card range.
* 3.1:
[VarDumper] Fix indentation trimming in ExceptionCaster
[HttpKernel] Clarify deprecation of non-scalar values in surrogate renderer
removed @since
[Security] fixed DebugAccessDecisionManager::setVoters()
Remove and change unrelevant comments in Validator and Security components.
[Validator] add missing interface use statement for phpdoc block return type.
[Validator] UuidValidator must accept a Uuid constraint.
[Validator] make UuidValidator class formatting consistent.
Conflicts:
src/Symfony/Component/Validator/Tests/Constraints/AbstractConstraintValidatorTest.php
* 3.0:
[VarDumper] Fix indentation trimming in ExceptionCaster
removed @since
Remove and change unrelevant comments in Validator and Security components.
[Validator] add missing interface use statement for phpdoc block return type.
[Validator] UuidValidator must accept a Uuid constraint.
[Validator] make UuidValidator class formatting consistent.
* 2.7:
removed @since
Remove and change unrelevant comments in Validator and Security components.
[Validator] UuidValidator must accept a Uuid constraint.
[Validator] make UuidValidator class formatting consistent.
This PR was merged into the 2.7 branch.
Discussion
----------
[Validator] [Security] Remove unrelevant comments in Security and Validator components
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Commits
-------
2cec4a6 Remove and change unrelevant comments in Validator and Security components.
* 3.1: (22 commits)
[travis] Fix deps=low/high builds
[Form] Fix depreciation triggers
fixed CS
skip test with current phpunit bridge
Fix for #19183 to add support for new PHP MongoDB extension in sessions.
[Console] Fix for block() padding formatting after #19189
[Security][Guard] check if session exist before using it
bumped Symfony version to 3.1.3
updated VERSION for 3.1.2
updated CHANGELOG for 3.1.2
bumped Symfony version to 3.0.9
updated VERSION for 3.0.8
updated CHANGELOG for 3.0.8
bumped Symfony version to 2.8.9
updated VERSION for 2.8.8
updated CHANGELOG for 2.8.8
bumped Symfony version to 2.7.16
updated VERSION for 2.7.15
update CONTRIBUTORS for 2.7.15
updated CHANGELOG for 2.7.15
...
Conflicts:
src/Symfony/Component/HttpKernel/Kernel.php
* 3.0:
[travis] Fix deps=low/high builds
fixed CS
skip test with current phpunit bridge
Fix for #19183 to add support for new PHP MongoDB extension in sessions.
[Console] Fix for block() padding formatting after #19189
[Security][Guard] check if session exist before using it
bumped Symfony version to 3.0.9
updated VERSION for 3.0.8
updated CHANGELOG for 3.0.8
bumped Symfony version to 2.8.9
updated VERSION for 2.8.8
updated CHANGELOG for 2.8.8
bumped Symfony version to 2.7.16
updated VERSION for 2.7.15
update CONTRIBUTORS for 2.7.15
updated CHANGELOG for 2.7.15
Fix some lowest deps
Fixed typos in the expectedException annotations
Conflicts:
src/Symfony/Component/HttpKernel/Kernel.php
src/Symfony/Component/Security/Guard/Authenticator/AbstractFormLoginAuthenticator.php
* 2.8:
[travis] Fix deps=low/high builds
fixed CS
skip test with current phpunit bridge
Fix for #19183 to add support for new PHP MongoDB extension in sessions.
[Console] Fix for block() padding formatting after #19189
[Security][Guard] check if session exist before using it
bumped Symfony version to 2.8.9
updated VERSION for 2.8.8
updated CHANGELOG for 2.8.8
bumped Symfony version to 2.7.16
updated VERSION for 2.7.15
update CONTRIBUTORS for 2.7.15
updated CHANGELOG for 2.7.15
Fix some lowest deps
Fixed typos in the expectedException annotations
Conflicts:
CHANGELOG-2.7.md
CHANGELOG-3.0.md
src/Symfony/Bundle/FrameworkBundle/composer.json
src/Symfony/Component/HttpFoundation/Tests/Session/Storage/Handler/MongoDbSessionHandlerTest.php
src/Symfony/Component/HttpKernel/Kernel.php
src/Symfony/Component/HttpKernel/composer.json
src/Symfony/Component/Yaml/Tests/ParserTest.php
* 2.7:
[travis] Fix deps=low/high builds
fixed CS
Fix for #19183 to add support for new PHP MongoDB extension in sessions.
bumped Symfony version to 2.7.16
updated VERSION for 2.7.15
update CONTRIBUTORS for 2.7.15
updated CHANGELOG for 2.7.15
Fixed typos in the expectedException annotations
Conflicts:
src/Symfony/Component/HttpKernel/Kernel.php
This PR was merged into the 3.2-dev branch.
Discussion
----------
[DependencyInjection] Autowiring: add setter injection support
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | todo
Add support for setter injection in the Dependency Injection Component.
Setter injection should be avoided when possible. However, there is some legitimate use cases for it. This PR follows a proposal of @weaverryan to ease using [DunglasActionBundle](https://github.com/dunglas/DunglasActionBundle) with #16863. The basic idea is to include a setter for the required service in the trait and let the DependencyInjection Component autowire the dependency using the setter.
This way, a newcomer can use the trait without having to create or modify the constructor of the action.
/cc @derrabus
Commits
-------
a0d7cbe [DependencyInjection] Autowiring: add setter injection support
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Routing] rename boolean and integer to bool and int
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/11394#issuecomment-228075328
| License | MIT
| Doc PR |
This addresses @Tobion's comment in https://github.com/symfony/symfony/pull/11394#issuecomment-228075328.
@symfony/deciders What do you think? Should we change the element names to how we use the types in PHP code or should we stick with XML element names that rather match the types as defined by the XML schema?
Commits
-------
808dcc8 rename boolean and integer to bool and int
This PR was merged into the 2.8 branch.
Discussion
----------
[Console] Fix block() padding formatting after #19189
| 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/19189#issuecomment-229735157
| License | MIT
| Doc PR | reference to the documentation PR, if any
This fixes the unformatted padding of `block()` output after #19189.
Commits
-------
dc130be [Console] Fix for block() padding formatting after #19189
This PR was squashed before being merged into the 2.8 branch (closes#19218).
Discussion
----------
[Security][Guard] check if session exist before using it
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18958
| License | MIT
| Doc PR | -
As stated by @Shekhovtsovy when the Guard component is used without the Symfony full stack (for instance in Laravel), $request->getSession() may be null.
An additionnal PR will be needed for 3.1 but it may be better to check this one before.
Commits
-------
a3f7510 [Security][Guard] check if session exist before using it
This PR was squashed before being merged into the 2.7 branch (closes#19243).
Discussion
----------
Fixed typos in the expectedException annotations
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
PHPUnit ignores any imports when resolving these. You must always reference the FQCN.
Commits
-------
b36de36 Fixed typos in the expectedException annotations
* 3.1:
Fixed BC Layer in DoctrineChoiceLoader
[HttpKernel] Add listener that checks when request has both Forwarded and X-Forwarded-For
[HttpKernel] Move conflicting origin IPs handling to catch block
[travis] Fix deps=low/high patching
Fixed some issues of the AccessDecisionManager profiler
[DoctrineBridge] fixed default parameter value in UniqueEntityValidator
* 3.0:
[HttpKernel] Add listener that checks when request has both Forwarded and X-Forwarded-For
[HttpKernel] Move conflicting origin IPs handling to catch block
[travis] Fix deps=low/high patching
* 2.8:
[HttpKernel] Add listener that checks when request has both Forwarded and X-Forwarded-For
[HttpKernel] Move conflicting origin IPs handling to catch block
[travis] Fix deps=low/high patching
* 2.7:
[HttpKernel] Add listener that checks when request has both Forwarded and X-Forwarded-For
[HttpKernel] Move conflicting origin IPs handling to catch block
[travis] Fix deps=low/high patching
This PR was squashed before being merged into the 3.2-dev branch (closes#19169).
Discussion
----------
Add test for Definition with exeption InvalidArgument
Add test for Definition with exeption InvalidArgument
| Q | A
| ------------- | ---
| Branch? | "master" for new features / 2.7, 2.8, 3.0 or 3.1 for fixes
| Bug fix? | no
| New feature? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
Commits
-------
91072e6 Add test for Definition with exeption InvalidArgument
This PR was squashed before being merged into the 3.1 branch (closes#18934).
Discussion
----------
Fixed some issues of the AccessDecisionManager profiler
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19022https://github.com/symfony/symfony-standard/issues/968https://github.com/schmittjoh/JMSSecurityExtraBundle/issues/207
| License | MIT
| Doc PR | -
Commits
-------
082f1b5 Fixed some issues of the AccessDecisionManager profiler
This PR was squashed before being merged into the 2.7 branch (closes#18688).
Discussion
----------
[HttpFoundation] Warning when request has both Forwarded and X-Forwarded-For
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR | symfony/symfony-docs#6526
Emit a warning when a request has both a trusted Forwarded header and a trusted X-Forwarded-For header, as this is most likely a misconfiguration which causes security issues.
Commits
-------
ee8842f [HttpFoundation] Warning when request has both Forwarded and X-Forwarded-For
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Serializer] Allow to use easily static constructors
| 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/19027#issuecomment-225527475
| License | MIT
| Doc PR | -
This PR allows to simply use static constructors to instantiate objects with the serializer by extending the default normalizers.
Commits
-------
9be6484 [Serializer] Allow to use easily static constructors
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Yaml] Avoid using both Input/Output and SymfonyStyle in LintCommand
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Fixed some inconsistencies/mistakes from the original YamLintCommand.
Commits
-------
dd84b7f [Yaml] Avoid using both Input/Output and SymfonyStyle in LintCommand
This PR was squashed before being merged into the 3.2-dev branch (closes#19190).
Discussion
----------
[DependencyInjection] Add support for short services configurators syntax
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
This PR adds support for short services configurators syntax in YAML files:
```yaml
services:
app.some_service:
class: ...
# Common syntax
configurator: [ '@app.configurator', 'configure' ]
# Short syntax
configurator: 'app.configurator:configure'
Commits
-------
da2757f [DependencyInjection] Add support for short services configurators syntax
This PR was squashed before being merged into the 2.7 branch (closes#19173).
Discussion
----------
[Console] Decouple SymfonyStyle from TableCell
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Alternative approach, ie BC, for #19136 (i prefer that one though, as it also _fixes_ #19123 )
Commits
-------
51f59d6 [Console] Decouple SymfonyStyle from TableCell
* 3.1:
fixed CS
fixed CS
fixed CS
fixed form tests
[Console] Fix formatting of SymfonyStyle::comment()
[Form] fix post max size translation type extension for >= 2.8
[Security] Allow LDAP loadUser override
removed dots at the end of @param and @return
fixed typo
* 3.0:
fixed CS
fixed CS
fixed form tests
[Console] Fix formatting of SymfonyStyle::comment()
[Form] fix post max size translation type extension for >= 2.8
removed dots at the end of @param and @return
fixed typo
* 2.8:
fixed CS
fixed form tests
[Console] Fix formatting of SymfonyStyle::comment()
[Form] fix post max size translation type extension for >= 2.8
removed dots at the end of @param and @return
fixed typo
This PR was merged into the 2.8 branch.
Discussion
----------
fixed form tests
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commits
-------
d0130d9 fixed form tests
This PR was merged into the 2.7 branch.
Discussion
----------
removed dots at the end of @param and @return
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
For phpdocs, we only add dots for sentences like description, but not for @param and @return for instance. This PR fixes this issue.
This should probably be added to PHP-CS-Fixer as well (/cc @phansys @keradus).
Commits
-------
554303e removed dots at the end of @param and @return
This PR was merged into the 3.1 branch.
Discussion
----------
[Security] Allow LDAP loadUser override
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Back to 3.0, one could extend `Symfony\Component\Security\Core\User\LdapUserProvider` and override how User objects are created.
Among several improvements, #17560 changed `loadUser` signature but also visibility to `private` which disallow any overriding.
Even if the signature BC break is legitimate, we should still be able to override this method IMHO, which is not possible with a private visibility.
This PRs introduces a `protected` visibility to allow again overriding.
Commits
-------
ae99aa8 [Security] Allow LDAP loadUser override
This PR was squashed before being merged into the 3.2-dev branch (closes#19187).
Discussion
----------
[Workflow] CS tweaks
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Just a few minor tweaks/fixes after playing around with it. Some phpdoc should still be added imo, like missing `@throws`, right?
Commits
-------
5428a92 [Workflow] CS tweaks
This PR was merged into the 2.8 branch.
Discussion
----------
[Console] Fix formatting of SymfonyStyle::comment()
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19172
| License | MIT
| Doc PR | n/a
This:
```php
$io->comment('Lorem ipsum dolor sit amet, consectetur adipisicing elit, <comment>sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat </comment>cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.');
```
Before outputs:
![](http://image.prntscr.com/image/1d2ea9de42024b53a77120c482be51d4.png)
After:
![](http://image.prntscr.com/image/36de23ec14b64804b0cbae7a431185be.png)
This moves the lines-cutting logic from `block()` into a specific `createBlock`, used from both `comment()` and `block()`, sort as `comment()` can take messages containing nested tags and outputs a correctly formatted block without escaping tags.
Commits
-------
0a53e1d [Console] Fix formatting of SymfonyStyle::comment()
Remove decoration from frameworkbundle test (avoid testing the Console behaviour)
Set background to default
Test output
Adapt test for FrameworkBundle
Use Helper::strlenWithoutDecoration rather than Helper::strlen(strip_tags(..))
Improve logic for align all lines to the first in block()
Tests more block() possible outputs
Avoid calling Helper::strlenWithoutDecoration in loop for prefix, assign it instead
* 3.1:
[CS] Respect PSR2 4.2
[Form] fix `empty_data` option in expanded `ChoiceType`
[Console] removed unneeded private methods
updated Http-Kernel dependency
[Security] [Guard] Improve comment with working example
sync min email validator version
[TwigBridge] Fix inconsistency in LintCommand help
explicitly forbid e-mail validator 2.0 or higher
Fixed SymfonyQuestionHelper multi-choice with defaults
[DoctrineBridge] Don't use object IDs in DoctrineChoiceLoader when passing a value closure
Differentiate between the first time a progress bar is displayed and subsequent times
finished previous commit
No more exception for malformed input name
fix post_max_size_message translation
[Process] Fix pipes cleaning on Windows
Avoid phpunit 5.4 warnings on getMock
[Form] Add exception to FormRenderer about non-unique block names
[FrameworkBundle] templating can be fully disabled
[Form] Consider a violation even if the form is not submitted
* 3.0:
[CS] Respect PSR2 4.2
[Form] fix `empty_data` option in expanded `ChoiceType`
[Console] removed unneeded private methods
[Security] [Guard] Improve comment with working example
sync min email validator version
[TwigBridge] Fix inconsistency in LintCommand help
explicitly forbid e-mail validator 2.0 or higher
Fixed SymfonyQuestionHelper multi-choice with defaults
[DoctrineBridge] Don't use object IDs in DoctrineChoiceLoader when passing a value closure
Differentiate between the first time a progress bar is displayed and subsequent times
finished previous commit
No more exception for malformed input name
fix post_max_size_message translation
[Process] Fix pipes cleaning on Windows
Avoid phpunit 5.4 warnings on getMock
[Form] Add exception to FormRenderer about non-unique block names
[Form] Consider a violation even if the form is not submitted
* 2.8:
[CS] Respect PSR2 4.2
[Form] fix `empty_data` option in expanded `ChoiceType`
[Console] removed unneeded private methods
[Security] [Guard] Improve comment with working example
sync min email validator version
[TwigBridge] Fix inconsistency in LintCommand help
explicitly forbid e-mail validator 2.0 or higher
Fixed SymfonyQuestionHelper multi-choice with defaults
[DoctrineBridge] Don't use object IDs in DoctrineChoiceLoader when passing a value closure
Differentiate between the first time a progress bar is displayed and subsequent times
finished previous commit
No more exception for malformed input name
fix post_max_size_message translation
[Process] Fix pipes cleaning on Windows
Avoid phpunit 5.4 warnings on getMock
[Form] Add exception to FormRenderer about non-unique block names
[Form] Consider a violation even if the form is not submitted
* 2.7:
[CS] Respect PSR2 4.2
[Form] fix `empty_data` option in expanded `ChoiceType`
[Console] removed unneeded private methods
sync min email validator version
[TwigBridge] Fix inconsistency in LintCommand help
explicitly forbid e-mail validator 2.0 or higher
Fixed SymfonyQuestionHelper multi-choice with defaults
[DoctrineBridge] Don't use object IDs in DoctrineChoiceLoader when passing a value closure
Differentiate between the first time a progress bar is displayed and subsequent times
finished previous commit
No more exception for malformed input name
fix post_max_size_message translation
[Process] Fix pipes cleaning on Windows
Avoid phpunit 5.4 warnings on getMock
[Form] Add exception to FormRenderer about non-unique block names
[Form] Consider a violation even if the form is not submitted
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Cache] Add PhpArrayAdapter to use shared memory on PHP 7.0
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | WIP
| Fixed tickets | -
| License | MIT
| Doc PR | -
Depends on https://github.com/symfony/symfony/pull/18825
This PR aims to implement a Symfony Cache adapter able to build files optimized for OPCache memory storage. Any kind of static data that can be warmed up is a candidate for OPcache storage.
This PR is limited to the implementation of the Adapter. It's usage in the annotations caching system is implemented in the PR https://github.com/symfony/symfony/pull/18533. The aim is also to use this adapter in other contexts (validator, serializer, ...).
Commits
-------
28a40d2 [Cache] Add PhpArrayAdapter to use shared memory on PHP 7.0+
This PR was merged into the 2.7 branch.
Discussion
----------
[WIP] [2.7] [Form] fix `empty_data` option in expanded `ChoiceType`
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17791
| License | MIT
| Doc PR | -
It might happen because in `Form::submit()` the handling of `empty_data` [line 597](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Form/Form.php#L597) comes after each child of a compound field has been submitted [line 549](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Form/Form.php#L549).
So when `ChoiceType` is `expanded`, `compound` option is defaulted to `true` and it passes its empty submitted data to its children before handling its own `empty_data` option.
This PR uses the listener already added in `ChoiceType` only when `expanded` is true to handle `empty_data` at `PRE_SUBMIT` [line 539](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Form/Form.php#L539).
- [ ] Fix FQCN in tests for 2.8
- [ ] Remove `choices_as_values` in tests for 3.0
Commits
-------
d479adf [Form] fix `empty_data` option in expanded `ChoiceType`
Remove input/output from method arguments, use SymfonyStyle instead
Avoid 'error in filename' if no filename as argument
Add missing array typehint to files argument of display*() methods
Store format option as member rather than pass it in method calls
CS fixes
This PR was merged into the 3.2-dev branch.
Discussion
----------
Undefined variable $name
| Q | A
| ------------- | ---
| Branch? | "master" for new features / 2.7, 2.8, 3.0 or 3.1 for fixes
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
Commits
-------
8304bcc Undefined variable $name
This PR was squashed before being merged into the 3.2-dev branch (closes#19104).
Discussion
----------
Adds support for the SameSite attribute in cookies.
| 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
$sameSite can be set to false, "lax", or "strict".
You can read about what the different modes do here: http://www.sjoerdlangkemper.nl/2016/04/14/preventing-csrf-with-samesite-cookie-attribute/
Commits
-------
428d0f7 Adds support for the SameSite attribute in cookies.
This PR was merged into the 2.7 branch.
Discussion
----------
Distinguish between first and subsequent progress bar displays
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19133
| License | MIT
| Doc PR | reference to the documentation PR, if any
Fixes https://github.com/symfony/symfony/issues/19133
When a progress bar is first displayed, if it is multi-line, previously output lines are erased, depending upon the number of lines in the progress bar.
This patch fixes that be distinguishing between the first display (no erasing of previous output) and subsequent displays of the progress bar.
Commits
-------
3871e1a Differentiate between the first time a progress bar is displayed and subsequent times
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Routing] support for array values in route defaults
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
As pointed out in symfony/symfony-docs#4017, the ``XmlFileLoader`` was not capable of defining array default values.
- [x] array values
- [x] integer values
- [x] float values
- [x] boolean
Commits
-------
120b35c [Routing] data type support for defaults
As pointed out in symfony/symfony-docs#4017, the XmlFileLoader was not
capable of defining array default values. Additionally, this commit
adds support for handling associative arrays, boolean, integer, float
and string data types.
This PR was merged into the 3.2-dev branch.
Discussion
----------
[VarDumper] Add support for XmlReader objects
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18989
| License | MIT
| Doc PR | -
Commits
-------
3779ee4 [VarDumper] Add support for XmlReader objects
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Console] Add Lockable trait
| 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 for the moment :)
Hi there,
Since the 2.6 the `LockHandler` class was added to ease concurrency problems. There was a nice post about [using it in your commands](http://symfony.com/blog/new-in-symfony-2-6-lockhandler).
From my humble experience, I find it a bit unpleasant/time consuming to always copy/paste the same code. So here is my proposal:
Before:
```php
class UpdateContentsCommand extends Command
{
protected function configure()
{
// ...
}
protected function execute(InputInterface $input, OutputInterface $output)
{
// create the lock
$lock = new LockHandler('update:contents');
if (!$lock->lock()) {
$output->writeln('The command is already running in another process.');
return 0;
}
// Your code
$lock->release();
}
}
```
After:
```php
class MyCommand extends Command
{
use LockableTrait;
protected function execute(InputInterface $input, OutputInterface $output)
{
if (!$this->lock()) {
// Here you can handle locking errors
}
// Your code
// The lock release is still optionnal
$this->release();
}
}
```
In addition, you can optionally pass two arguments:
- a string argument to change the lock name
- a boolean argument to indicate if you want to wait until the requested lock is released
Commits
-------
b57a83f [Console] Add Lockable trait
Add tests
Fix tests & YamlLintCommand help formatting
fabbot fixes
Use Generator to iterate over the filesystem
Move STDIN related code in a method
Use RecursiveIteratorIterator::LEAVES_ONLY rather than SELF_FIRST
Stop using the Finder component when available (Make findFiles() private)
Re-add FrameworkBundle YamlLintCommandTest
Use CommandTester::getStatusCode() rather than assign execute()
Re-add feature for bundle directories, Test it
This PR was merged into the 3.2-dev branch.
Discussion
----------
Response headers fix
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | yes/no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #16171, #16307
| License | MIT
| Doc PR | n/a
To fix the inconsistency mentioned in #16171, I think the "best" solution would be to add `private` when cache-control is not set, which was the intention but was forgotten.
I propose to make the fix in 3.2 only as it might be a BC break.
Commits
-------
66afa01 [HttpFoundation] added private by default when setting Cache-Control to no-cache
This PR was merged into the 2.7 branch.
Discussion
----------
[DomCrawler] No more exception on field name with strange format
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18569, #18570
| License | MIT
| Doc PR | n/a
Commits
-------
e204913 finished previous commit
953a383 No more exception for malformed input name
This PR was merged into the 2.7 branch.
Discussion
----------
[Form] Consider a violation even if the form is not submitted
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | yes (only for the behavior)
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #11493
| License | MIT
| Doc PR |
Hey!
I'm currently implementing an API using the form component in order to validate the payload sent (in conjonction with the FOSRestBundle). Unfortunatelly, we dig into an issue about the PATCH request which don't map some of our validation rules to the form. Basically, the violations are lost in the middle of the process.
### Use case
We have an entity with the following fields "type", "image" & "video". The field "type"can be either "default", "image" or "video" and then accordingly we use the appropriate field (none for the "default" type, video for the "video" type and image for the "image" type. Then, in our form, we change the validation groups according to our entity type in order to make the "image" field mandatory if the type is "image" and the same for the video field if the type is "video".
### Current behavior
The current behavior (since 2.5) seems to not propages a violation to a form if this form is not submitted but in our use case, changing the field "type" via a PATCH request triggers some new validation which should be reported to end user (inform that a field (video or image) is missing in the PATCH request).
### Expected behavior
The current behavior was introduced in #10567 but IMO, this update is a bug as suggested by @webmozart in https://github.com/symfony/symfony/issues/11493#issuecomment-59549054 Instead, the form component should still map validation errors to the form even if the field was not submitted. If the initial data is not valid, then your initial data was buggy from the beginning but the form should not accept it and instead of silently ignoring the errors, end users should be informed and fix it.
WDYT?
Commits
-------
c483a0f [Form] Consider a violation even if the form is not submitted
This PR was merged into the 2.7 branch.
Discussion
----------
[Process] Fix pipes cleaning on Windows
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19089
| License | MIT
| Doc PR | -
Commits
-------
d54cd02 [Process] Fix pipes cleaning on Windows
* 3.1:
fixed CS
fixed CS
fixed CS
fixed CS
tweaked default CS fixer config
[HttpKernel] Dont close the output stream in debug
move HttpKernel component to require section
Fixed oci and sqlsrv merge queries when emulation is disabled - fixes#17284
[Session] fix PDO transaction aborted under PostgreSQL
[Console] Use InputInterface inherited doc as possible
Mention generating absolute urls in UPGRADE files and CHANGELOG
parse embedded mappings only if value is a string
add docblock type elements to support newly added IteratorAggregate::getIterator PhpStorm support
FormBuilderInterface: fix getForm() return type.
[YAML] Fixed parsing problem with nested DateTime lists
Fixed typo in PHPDoc
* 3.0:
fixed CS
fixed CS
fixed CS
tweaked default CS fixer config
[HttpKernel] Dont close the output stream in debug
move HttpKernel component to require section
Fixed oci and sqlsrv merge queries when emulation is disabled - fixes#17284
[Session] fix PDO transaction aborted under PostgreSQL
[Console] Use InputInterface inherited doc as possible
Mention generating absolute urls in UPGRADE files and CHANGELOG
add docblock type elements to support newly added IteratorAggregate::getIterator PhpStorm support
FormBuilderInterface: fix getForm() return type.
Fixed typo in PHPDoc
* 2.8:
fixed CS
fixed CS
tweaked default CS fixer config
[HttpKernel] Dont close the output stream in debug
move HttpKernel component to require section
Fixed oci and sqlsrv merge queries when emulation is disabled - fixes#17284
[Session] fix PDO transaction aborted under PostgreSQL
[Console] Use InputInterface inherited doc as possible
Mention generating absolute urls in UPGRADE files and CHANGELOG
add docblock type elements to support newly added IteratorAggregate::getIterator PhpStorm support
FormBuilderInterface: fix getForm() return type.
Fixed typo in PHPDoc
* 2.7:
fixed CS
tweaked default CS fixer config
[HttpKernel] Dont close the output stream in debug
move HttpKernel component to require section
Fixed oci and sqlsrv merge queries when emulation is disabled - fixes#17284
[Session] fix PDO transaction aborted under PostgreSQL
[Console] Use InputInterface inherited doc as possible
add docblock type elements to support newly added IteratorAggregate::getIterator PhpStorm support
FormBuilderInterface: fix getForm() return type.
Fixed typo in PHPDoc
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Debug] fix resource type test on HHVM
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19079
| License | MIT
| Doc PR |
Commits
-------
2d03ee8 [Debug] fix resource type test on HHVM
This PR was merged into the 2.7 branch.
Discussion
----------
[HttpKernel] Dont close the reponse stream in debug
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19078
| License | MIT
| Doc PR | -
Because it's `terminate`'s job to clean the state, not the `Response`'s,
and because the current behavior prevents getting any output on trailing errors on FPM especially.
Commits
-------
2fbc200 [HttpKernel] Dont close the output stream in debug
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Console] Add ConsoleLogger::hasErrored()
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
So that it's easy to `exit(1)` whenever any messages have been logged at error levels.
Commits
-------
cfc578a [Console] Add ConsoleLogger::hasErrored()
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Console] Test SymfonyStyle::ask() output
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Now that we can test an interactive command that uses SymfonyStyle (after #18999), we should test their output.
Commits
-------
e870758 [Console] Test SymfonyStyle::ask() output
This PR was merged into the 2.7 branch.
Discussion
----------
[Session] fix PDO transaction aborted under PostgreSQL
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #14641
| License | MIT
| Doc PR |
Fixes the transactional concurrency error handling for PostgreSQL which does not allow to execute further queries in a transaction with an error.
Because of the loop, look at the diff with whitespace ignored to see the difference: https://github.com/symfony/symfony/pull/19101/files?w=1
Commits
-------
f8eefa0 [Session] fix PDO transaction aborted under PostgreSQL
This PR was merged into the 2.7 branch.
Discussion
----------
[HttpFoundation] changed MERGE queries
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17284
| License | MIT
| Doc PR | N/A
Changed the MERGE queries for Oracle and SQL Server to use question mark parameter markers so they work with emulation disabled or enabled - fixes#17284
Commits
-------
ebf3a2f Fixed oci and sqlsrv merge queries when emulation is disabled - fixes#17284
This PR was merged into the 2.7 branch.
Discussion
----------
[Console] Use InputInterface inherited doc as possible
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
In classes implementing `InputInterface`, the methods doc blocks are duplicated from the interface.
Sometimes descriptions are different from the interface's ones and, sometimes, the class doc is clearer. So I tried to keep always the most adapted one.
Commits
-------
b604be7 [Console] Use InputInterface inherited doc as possible
This PR was merged into the 2.7 branch.
Discussion
----------
FormBuilderInterface: fix getForm() return type.
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
FormBuilderInterface->getForm() should depend on abstractions and
not implementations as a return type.
Commits
-------
3fa081c FormBuilderInterface: fix getForm() return type.
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Console] progress bar fix
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #13019
| License | MIT
| Doc PR | -
This is #16490 where I've simplified the code as much as possible and added a test for the bug we're trying to fix.
The main change is the renaming of the `TerminalDimensionsProvider` to just `Terminal`. The new class can probably be useful to add more about the terminal.
Commits
-------
2f81247 switched to use COLUMNS and LINES env vars to change terminal dimensions
bf7a5c5 fixed logic
a589635 deprecated some Console Application methods
8f206c8 fixed CS, simplified code
b030c24 [Console] ProgressBar - adjust to the window width (static)
This PR was merged into the 2.7 branch.
Discussion
----------
add docblock type elements to support newly added IteratorAggregate::getIterator PhpStorm support
| Q | A
| ------------- | ---
| Branch | 2.7
| Bug fix | no
| New feature | no
| BC breaks | no
| Deprecations | no
| Tests pass | yes
| License | MIT
In additional to #16965 PhpStorm supports `IteratorAggregate::getIterator` now. see https://blog.jetbrains.com/phpstorm/2016/06/phpstorm-2016-2-eap-162-844/
example
```
$collection = new \Symfony\Component\Routing\RouteCollection();
foreach ($collection as $route) {
$route->getHost();
}
```
Commits
-------
ede3556 add docblock type elements to support newly added IteratorAggregate::getIterator PhpStorm support
This PR was squashed before being merged into the 3.2-dev branch (closes#19029).
Discussion
----------
[YAML] Fixed parsing problem with nested DateTime lists
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
___
Without this fix, DateTime-aware parsing of a YAML source containing nested lists of dates result in an error. Consider this:
```php
$data = ['date' => ['annivesary' => new \DateTime('now')]];
$yaml = Yaml::dump($data);
var_dump($yaml);
$parsed = Yaml::parse($yaml, Yaml::PARSE_DATETIME);
print_r($parsed);
```
Everything is fine, result is:
```
string(48) "date:
annivesary: 2016-06-11T11:26:30+02:00
"
Array
(
[date] => Array
(
[annivesary] => DateTime Object
(
[date] => 2016-06-11 11:26:30.000000
[timezone_type] => 1
[timezone] => +02:00
)
)
)
```
But making the `anniversary` a list of dates
```php
$data = ['date' => ['annivesary' => [new \DateTime('now')]]];
$yaml = Yaml::dump($data);
var_dump($yaml);
$parsed = Yaml::parse($yaml, Yaml::PARSE_DATETIME);
print_r($parsed);
```
will result in:
```
string(50) "date:
annivesary: [2016-06-11T12:00:05+02:00]
"
PHP Warning: strpos() expects parameter 1 to be string, object given in [...]\vendor\symfony\yaml\Inline.php on line 382
PHP Catchable fatal error: Object of class DateTime could not be converted to string in [...]\vendor\symfony\yaml\Inline.php on line 386
```
(I didn't capture the error messages with the most recent master branch, so line numbers differ somewhat)
Commits
-------
52384cf [YAML] Fixed parsing problem with nested DateTime lists
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Router] added appending of new optional document fragment
added a new optional parameter to the generate method for the document fragment. when specified this is appended to generated urls.
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | none
| License | MIT
| Doc PR | none
Commits
-------
6d79a56 [Routing] adds _fragment special option to url generation for document fragment
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Console] Simplify simulation of user inputs in CommandTester
| 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 | https://github.com/symfony/symfony-docs/pull/6623
After @javiereguiluz pointed it in #17470, I open this PR to simplify the simulation of user inputs for testing a Command.
It would be done by calling `CommandTester::setUserInputs()` with an array of inputs as argument, and so make the CommandTester creating an input stream from the inputs set by the developer, then call `QuestionHelper::setInputStream` and assign it to the helperSet of the command, sort as all is done automatically in one call.
Depends on #18999
Commits
-------
c7ba38a [Console] Set user inputs from CommandTester
* 3.1:
Tweak merge
update tests to use the new error assertion helper
[ci] Upgrade to symfony/phpunit-bridge >=3.2@dev
update tests to use the new error assertion helper
Conflicts:
src/Symfony/Component/DependencyInjection/Tests/ContainerBuilderTest.php
This PR was merged into the 3.1 branch.
Discussion
----------
[3.1] update tests to use the new error assertion helper
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Commits
-------
9c7512b update tests to use the new error assertion helper
* 2.8:
update tests to use the new error assertion helper
[ci] Upgrade to symfony/phpunit-bridge >=3.2@dev
Conflicts:
src/Symfony/Component/DependencyInjection/Tests/ContainerBuilderTest.php
src/Symfony/Component/Yaml/Tests/ParserTest.php
This PR was merged into the 2.8 branch.
Discussion
----------
[2.8] update tests to use the new error assertion helper
| 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
-------
e5cf4d4 update tests to use the new error assertion helper
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Console] Centralize input stream in base Input class
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | #10844
| License | MIT
| Doc PR | not yet
Actually we have two classes that have an `inputStream` property with its getter+setter:
the QuestionHelper ('question' helper) and the SymfonyQuestionHelper (used via SymfonyStyle, that inherits the inputStream from the QuestionHelper class).
This situation makes command testing really hard.
ATM we can't test a command that uses `SymfonyStyle::ask` without ugly hacks, and we can't find a generic way to set the inputs passed to a command from the CommandTester, as it need to be done on a specific helper that may not be the one used by the command (SymfonyStyle case).
What I propose here is to add a `stream` property (and its getter+setter) to the abstract `Symfony\Component\Console\Input\Input` class.
For now I just made the two helpers setting their `inputStream` from `Input::getStream`, as both QuestionHelper and SymfonyQuestionHelper classes have an `ask` method that takes the command Input as argument.
In a next time (4.0), we could remove the `getInputStream` and `setInputStream` methods from the QuestionHelper class (this only deprecates them in favor of Input `setStream` and `getStream`).
This would close PR #18902 (trying to make interactive command testing with SymfonyStyle easier).
This would also make PR #18710 widely better by setting the input stream in a generic way (working for both helpers without caring about if they are used and which one is used).
Please give me your opinions.
Commits
-------
54d3d63 Centralize input stream in base Input class
* 3.1:
[TwigBridge] Add missing type hint to TwigRenderer
[HttpFoundation] Fix UPSERT for PgSql >= 9.5
[Form] fixed DateTime transformers
[PropertyAccess][DX] Enhance exception that say that some methods are missing if they don't
bumped Symfony version to 3.1.2
updated VERSION for 3.1.1
updated CHANGELOG for 3.1.1
[Form] fixed EntityType test with query_builder option
Conflicts:
src/Symfony/Component/HttpKernel/Kernel.php
src/Symfony/Component/PropertyAccess/PropertyAccessor.php
* 3.0:
[TwigBridge] Add missing type hint to TwigRenderer
[HttpFoundation] Fix UPSERT for PgSql >= 9.5
[Form] fixed DateTime transformers
[PropertyAccess][DX] Enhance exception that say that some methods are missing if they don't
[Form] fixed EntityType test with query_builder option
Conflicts:
src/Symfony/Component/HttpFoundation/Cookie.php
* 2.8:
[HttpFoundation] Fix UPSERT for PgSql >= 9.5
[Form] fixed DateTime transformers
[PropertyAccess][DX] Enhance exception that say that some methods are missing if they don't
[Form] fixed EntityType test with query_builder option
Conflicts:
src/Symfony/Component/Form/Extension/Core/DataTransformer/DateTimeToStringTransformer.php
src/Symfony/Component/Form/Extension/Core/DataTransformer/DateTimeToTimestampTransformer.php
* 2.7:
[HttpFoundation] Fix UPSERT for PgSql >= 9.5
[Form] fixed DateTime transformers
[PropertyAccess][DX] Enhance exception that say that some methods are missing if they don't
This PR was merged into the 3.2-dev branch.
Discussion
----------
[ExpressionLanguage] Add a way to hook on each node when dumping the AST
| Q | A
| ------------- | ---
| Branch? | "master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19013
| License | MIT
| Doc PR | -
This is an iteration over #19013 to allow writing dumpers that can decorate dumps (e.g. add HTML tags based on each node type to do syntax highlighting).
Commits
-------
66d23db [ExpressionLanguage] Add a way to hook on each node when dumping the AST
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Console] Better support for one command app
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #9564
| License | MIT
Hello;
I write many CLI application, and "single command" in cli application is not so easy to write.
This is why I propose this patch. IMHO, this PR could replaces #9609.
See it in application:
```php
#!/usr/bin/env php
<?php
require __DIR__.'/vendor/autoload.php';
use Symfony\Component\Console\Application;
use Symfony\Component\Console\Input\InputArgument;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface;
(new Application('echo', '1.0.0'))
->register('echo')
->addArgument('foo', InputArgument::OPTIONAL, 'The directory', 'foo')
->addOption('bar', null, InputOption::VALUE_REQUIRED, 'Foobar', 'bar')
->setCode(function(InputInterface $input, OutputInterface $output) {
$output->writeln('start');
$output->writeln($input->getArgument('foo'));
$output->writeln($input->getOption('bar'));
})
->getApplication()
->setSingleCommand('echo')
->run();
```
Some usage:
```
>(3)[{..}eg/dev/github.com/symfony/symfony](console-one-app) php test.php
start
foo
bar
```
```
>(3)[{..}eg/dev/github.com/symfony/symfony](console-one-app) php test.php "first argument"
start
first argument
bar
```
```
>(3)[{..}eg/dev/github.com/symfony/symfony](console-one-app) php test.php "first argument" --bar="first option"
start
first argument
first option
```
```
>(3)[{..}eg/dev/github.com/symfony/symfony](console-one-app) php test.php "first argument" --bar="first option" --help
Usage:
echo [options] [--] [<foo>]
Arguments:
foo The directory [default: "foo"]
Options:
--bar=BAR Foobar [default: "bar"]
-h, --help Display this help message
-q, --quiet Do not output any message
-V, --version Display this application version
--ansi Force ANSI output
--no-ansi Disable ANSI output
-n, --no-interaction Do not ask any interactive question
-v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug
```
Commits
-------
4a9bb1d [Console] Better support for one command app
This PR was merged into the 3.2-dev branch.
Discussion
----------
Move Constraint validator test case to Test namespace
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | kinda
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
The Validator component has a very usefull test utility to test constraint validators. It's only hidden deep in the Tests namespace. Just as was done with the TypeTestCase of the Form component some years ago, I think it's usefull to move the constraint test case to the Test namespace as well.
*Btw, my last PR of the year and the first deprecation of 3.1* 🎆
Commits
-------
e938361 Move Constraint validator test case to Test namespace
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Process] Allow inheriting env vars instead of replacing them
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18796
| License | MIT
| Doc PR | -
Commits
-------
524508c [Process] Allow merging env vars instead of replacing them
This PR was merged into the 3.2-dev branch.
Discussion
----------
[HttpKernel] Move duplicated logic from Esi/Ssi to an AbstractSurrogate
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations?| no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commits
-------
c5dc50d Move duplicated logic from Esi/Ssi to an AbstractSurrogate
Add StreamableInputInterface
Removed commented code
Prevent BC by looking for QuestionHelper::
Logic fixes
Check for that implements StreamableInputInterface
Rollback E_USER_DEPRECATED notice in getInputStream
Remove legacy tests to avoid KO because of deprecations
Add missing use
Keep old tests marked as legacy
Undeprecate getInputStream, CS Fixes
Move legacy tests in separated class
Revert separated legacy test class
Keep legacy createInputInterfaceMock()
Depreciate QuestionHelper::getInputStream()
This PR was squashed before being merged into the 2.7 branch (closes#18732).
Discussion
----------
[PropertyAccess][DX] Enhance exception that say that some methods are missing if they don't
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18694
| License | MIT
| Doc PR |
When you try do define a manyToMany association but you don't give an array or \Traversable, the raised exception say that some methods are missing while they don't. This PR check if the adder and setter methods exists and if so, give a exception that pointing on the real problem.
Commits
-------
c46519b [PropertyAccess][DX] Enhance exception that say that some methods are missing if they don't
This PR was merged into the 3.2-dev branch.
Discussion
----------
[DependencyInjection] fix the sorting by priority
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18482
| License | MIT
| Doc PR |
Commits
-------
6f72657 [DependencyInjection] fix the sorting by priority
* 3.1: (30 commits)
Fix merge
[HttpFoundation] Use UPSERT for sessions stored in PgSql >= 9.5
[Console] fixed PHPDoc
[Cache] Fix double fetch in ProxyAdapter
[travis] HHVM 3.12 LTS
Fix feature detection for IE
[Form] Fixed collapsed choice attributes
[Console] added explanation of messages usage in a progress bar
force enabling the external XML entity loaders
[Yaml] properly count skipped comment lines
[WebProfilerBundle] Fix invalid CSS style
Added progressive jpeg to mime types guesser
[Yaml] Fix wrong line number when comments are inserted in the middle of a block.
Fixed singular of committee
Fixed singular of committee
Do not inject web debug toolbar on attachments
Fixed issue with legacy client initialization
[FrameworkBundle] Remove unused variable
bumped Symfony version to 3.0.8
updated VERSION for 3.0.7
...
* 3.0: (25 commits)
Fix merge
[HttpFoundation] Use UPSERT for sessions stored in PgSql >= 9.5
[Console] fixed PHPDoc
[travis] HHVM 3.12 LTS
Fix feature detection for IE
[Form] Fixed collapsed choice attributes
[Console] added explanation of messages usage in a progress bar
force enabling the external XML entity loaders
[Yaml] properly count skipped comment lines
[WebProfilerBundle] Fix invalid CSS style
Added progressive jpeg to mime types guesser
[Yaml] Fix wrong line number when comments are inserted in the middle of a block.
Fixed singular of committee
Do not inject web debug toolbar on attachments
bumped Symfony version to 3.0.8
updated VERSION for 3.0.7
updated CHANGELOG for 3.0.7
bumped Symfony version to 2.8.8
updated VERSION for 2.8.7
updated CHANGELOG for 2.8.7
...
Conflicts:
src/Symfony/Component/HttpKernel/Kernel.php
src/Symfony/Component/PropertyAccess/StringUtil.php
src/Symfony/Component/PropertyAccess/Tests/StringUtilTest.php
src/Symfony/Component/Yaml/Parser.php
src/Symfony/Component/Yaml/Tests/ParserTest.php
* 2.8: (22 commits)
Fix merge
[HttpFoundation] Use UPSERT for sessions stored in PgSql >= 9.5
[Console] fixed PHPDoc
[travis] HHVM 3.12 LTS
Fix feature detection for IE
[Form] Fixed collapsed choice attributes
[Console] added explanation of messages usage in a progress bar
force enabling the external XML entity loaders
[Yaml] properly count skipped comment lines
[WebProfilerBundle] Fix invalid CSS style
Added progressive jpeg to mime types guesser
[Yaml] Fix wrong line number when comments are inserted in the middle of a block.
Fixed singular of committee
Do not inject web debug toolbar on attachments
bumped Symfony version to 2.8.8
updated VERSION for 2.8.7
updated CHANGELOG for 2.8.7
bumped Symfony version to 2.7.15
updated VERSION for 2.7.14
update CONTRIBUTORS for 2.7.14
...
Conflicts:
CHANGELOG-2.7.md
CHANGELOG-3.0.md
src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php
src/Symfony/Component/HttpKernel/Kernel.php
* 2.7:
[HttpFoundation] Use UPSERT for sessions stored in PgSql >= 9.5
[Console] fixed PHPDoc
[travis] HHVM 3.12 LTS
Fix feature detection for IE
[Form] Fixed collapsed choice attributes
[Console] added explanation of messages usage in a progress bar
force enabling the external XML entity loaders
[Yaml] properly count skipped comment lines
Conflicts:
src/Symfony/Component/Translation/Loader/XliffFileLoader.php
This PR was merged into the 2.7 branch.
Discussion
----------
[HttpFoundation] Use UPSERT for sessions stored in PgSql >= 9.5
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
9569c74 [HttpFoundation] Use UPSERT for sessions stored in PgSql >= 9.5
This PR was squashed before being merged into the 3.2-dev branch (closes#18322).
Discussion
----------
[DomCrawler] Attach label to form fields
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
While building a software to extract information from a webpage, I need to fill a form with hints on the fields labels.
Example:
```html
<form>
...
<label for="my_field">Input the result of 3 + 4:</label>
<input type="text" id="my_field" name="my_field" />
...
</form>
```
I thought it would be handy to have the field labels attached to each field.
So given the previous form you could now do:
```php
$form->get('my_field')->getLabel()->textContent;
```
Commits
-------
82ef55b [DomCrawler] Attach label to form fields
This PR was squashed before being merged into the 3.2-dev branch (closes#18482).
Discussion
----------
Created a trait to sort tagged services
| 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 writing the `ControllerArgumentValueResolverPass`, I needed a sorting on `priority`. I ended up copying a method from another class. I noticed this was done more often and 99% of the code was the same. I've moved the most common notation into the trait and "used" the trait in the priority aware passes. This increases horizontal re-use and means people can also use this in their bundles.
The cases that were slightly different, are still working completely. I had to fix some tests because they returned an invalid value from the mocked find method.
Commits
-------
778a70b Created a trait to sort tagged services
This PR was merged into the 3.2-dev branch.
Discussion
----------
[ExpressionLanguage] Added a way to dump the AST
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Because it's convenient and it makes easier to inline results of sub/smaller part of the main expression.
Commits
-------
87af6e5 [ExpressionLanguage] Added a way to dump AST
This PR was merged into the 2.7 branch.
Discussion
----------
[Console] added explanation of messages usage in a progress bar
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #19031
| License | MIT
| Doc PR | symfony/symfony-docs#6544
The intent of progress bar messages is currently wrongly documented. This PR updates the phpdoc to hopefully better describe the usage of such messages.
So, basically, messages are a way to add dynamic information in the progress bar; information that cannot be computed by the progress bar (like for all other placeholders).
Commits
-------
d92f3ea [Console] added explanation of messages usage in a progress bar
This PR was merged into the 2.7 branch.
Discussion
----------
[DependencyInjection] force enabling the external XML entity loaders
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18876, #18908
| License | MIT
| Doc PR |
Commits
-------
12b5509 force enabling the external XML entity loaders
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Routing] Throw exception when PHP start tag is missing
| Q | A
| ------------- | ---
| Branch? | master (?)
| Bug fix? | yes
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony-docs/issues/6116 (and many more)
| License | MIT
| Doc PR | -
The Problem
---
In the documentation, we never use the PHP start tag. However, in the first tutorials, people simply copy/past the code examples, save the file and expect things to work. They seem to often forget to add the PHP start tag.
Without start tag, the annotation file loader simply skips the file without providing any reason why. As a big framework is quite overwhelming, simple things like this are completely forgotten.
The Fix
---
If a `*.php` file only consists of `T_INLINE_HTML`, it means there is no `<?php` start tag. In this case, instead of skipping the file, an exception is throwed with a possible fix.
BC Break?
---
As the file loader is only executed for `*.php` files, I think the BC break is minimal, but it is possible that people have applications with `*.php` files *without* a start tag. If this file lives in a routing loaded directory (e.g. when doing `@AppBundle/Controller`), it would now result in an exception.
I think this BC break is minimal and can be ignored. If you don't agree, we can add a little str match to check if `class ... {` exists. If that's the case, I think it's safe to say that it was meant to be a PHP file.
Bug or Feature?
---
I don't know if this is considered a bug or a feature, so I submitted it as a feature.
Commits
-------
1e765c8 Throw exception when PHP start tag is missing
This PR was squashed before being merged into the 3.2-dev branch (closes#18781).
Discussion
----------
[Console] Display errors in quiet mode
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18767
| License | MIT
| Doc PR |
- map VERBOSITY_QUIET normally, rather than suppressing all output
without override
- ensure that we do write to the output if we've determined (via
verbosityLevelMap) that we should
About the second point, it seems ConsoleLogger has the same issue (https://github.com/symfony/symfony/blob/2.8/src/Symfony/Component/Console/Logger/ConsoleLogger.php#L92), but since we're not using that, I haven't checked it.
Commits
-------
278c26f [Console] Display errors in quiet mode
This PR was merged into the 3.2-dev branch.
Discussion
----------
[HttpKernel] Add convenient method ArgumentResolver:: getDefaultArgumentValueResolvers
| 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
I realized while implementing my own `ArgumentValueResolver` that registering a new one is not easy, you have to give the whole list of resolver instead of pushing your one in the stack.
Commits
-------
6fdfc92 [HttpKernel] Add convenient method ArgumentResolver::addArgumentValueResolver
This PR was squashed before being merged into the 3.2-dev branch (closes#18977).
Discussion
----------
[PropertyAccess] Add missing arguments to PropertyAccess::createPropertyAccessor()
| 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 | https://github.com/symfony/symfony-docs/pull/6640
Actually, the recommended way to use the PropertyAccessor is to use `PropertyAccess::createPropertyAccessor`.
The problem is that using this way, we can't specify that invalid indexes should throw an exception, and so when calling `PropertyAccessor::isReadable([], '[foo]')` it returns always true.
It should be possible to make the exception thrown, plus the `PropertyAccessor::$throwExceptionOnInvalidIndex` already exists but is not used in `PropertyAccess::createPropertyAccessor`.
Commits
-------
5ded804 [PropertyAccess] Add missing arguments to PropertyAccess::createPropertyAccessor()
* 2.7:
Added progressive jpeg to mime types guesser
[Yaml] Fix wrong line number when comments are inserted in the middle of a block.
Fixed singular of committee
Do not inject web debug toolbar on attachments
bumped Symfony version to 2.7.15
updated VERSION for 2.7.14
update CONTRIBUTORS for 2.7.14
updated CHANGELOG for 2.7.14
[Console] [SymfonyStyle] Replace long word wrapping test to directly test output
This PR was squashed before being merged into the 3.2-dev branch (closes#18790).
Discussion
----------
[Console] Show aliases in command description instead of in different lines in application description
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18351
| License | MIT
| Doc PR |
This PR is a suggestion about the bug referenced in ticket 18351. The problem is that aliases create new lines with identical descriptions in the application description, it is suggested to show the aliases in the command description.
I had to modify one application fixture to meet this new behaviour and make the tests pass, but I don't think that a new application fixture is needed to test this having the application fixture 2.
Comments are welcome, this is my first PR in Symfony so if I need to meet any more requirements to make it correct to merge just tell me please.
Commits
-------
548ab0a [Console] Show aliases in command description instead of in different lines in application description
This PR was merged into the 2.7 branch.
Discussion
----------
[Console] [SymfonyStyle] Replace long word wrapping test to directly test output
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/18879#discussion_r64783524
| License | MIT
| Doc PR | -
This [line](https://github.com/symfony/symfony/pull/18879/files#diff-d3625f2548a3b329058ca5a0f5aa57feR60) should not have been changed in order to the test to pass. I assume the test was flawed at first, so I suggest to simply test the output as we did for other ones.
Ping @chalasr
Commits
-------
b78fff4 [Console] [SymfonyStyle] Replace long word wrapping test to directly test output
This PR was squashed before being merged into the 3.1 branch (closes#18909).
Discussion
----------
Fixed singular of committee
| Q | A
| ------------- | ---
| Branch? | 3.1?
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18872, #18748
| License | MIT
| Doc PR | -
As in SF 3.1 the StringUtil has been moved to a new Component, I am proposing this for 3.1.
I can easily provide the same in an additional PR against the 2.3? branch.
Commits
-------
b5e1f24 Fixed singular of committee
This PR was squashed before being merged into the 3.2-dev branch (closes#18992).
Discussion
----------
[Cache] AbstractAdapter: avoid an extra call to ApcuAdapter::isSupported
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commits
-------
8f2ea52 [Cache] AbstractAdapter: avoid an extra call to ApcuAdapter::isSupported
This PR was squashed before being merged into the 3.2-dev branch (closes#18337).
Discussion
----------
[PropertyInfo] Support singular adder and remover
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18166
| License | MIT
| Doc PR | n/a
Fix#18166 with only a soft dependency to the PropertyAccess component. If #18260 is accepted, this PR can be reworked to use this new component, in the meantime it fixes the problem with a soft dependency.
I don't now if it should be considered as a bug fix (and then merged in 2.8) or as a new feature. It's technically a bug fix but I'm not sure that introducing a new soft dependency is acceptable if older branches. What do you think @symfony/deciders?
Commits
-------
4cbb60c [PropertyInfo] Support singular adder and remover
* 3.1:
[BrowserKit] Bump dom-crawler minimum version requirement
Make one call to "OutputInterface::write" method per table row
[HttpKernel] Fix context dependent test
[Debug] Fix context dependent test
* 3.0:
[BrowserKit] Bump dom-crawler minimum version requirement
Make one call to "OutputInterface::write" method per table row
[HttpKernel] Fix context dependent test
[Debug] Fix context dependent test
* 2.8:
[BrowserKit] Bump dom-crawler minimum version requirement
Make one call to "OutputInterface::write" method per table row
[HttpKernel] Fix context dependent test
[Debug] Fix context dependent test
* 2.7:
[BrowserKit] Bump dom-crawler minimum version requirement
Make one call to "OutputInterface::write" method per table row
[HttpKernel] Fix context dependent test
[Debug] Fix context dependent test
This PR was merged into the 2.7 branch.
Discussion
----------
[HttpKernel] Fix context dependent test
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Class `Foo` exists when the ClassLoader component is tested alongside with HttpKernel
Commits
-------
065dee8 [HttpKernel] Fix context dependent test
* 3.1:
`@throws` annotations should go after `@return`
Fix merge
updated VERSION for 2.3.42
update CONTRIBUTORS for 2.3.42
updated CHANGELOG for 2.3.42
Revert "bug #18908 [DependencyInjection] force enabling the external XML entity loaders (xabbuh)"
Partial revert of previous PR
[DependencyInjection] Skip deep reference check for 'service_container'
Catch \Throwable
[Serializer] Add missing @throws annotations
Fix for #18843
force enabling the external XML entity loaders
Removed UTC specification with timestamp
* 3.0:
`@throws` annotations should go after `@return`
Fix merge
updated VERSION for 2.3.42
update CONTRIBUTORS for 2.3.42
updated CHANGELOG for 2.3.42
Revert "bug #18908 [DependencyInjection] force enabling the external XML entity loaders (xabbuh)"
Partial revert of previous PR
[DependencyInjection] Skip deep reference check for 'service_container'
Catch \Throwable
[Serializer] Add missing @throws annotations
Fix for #18843
force enabling the external XML entity loaders
Removed UTC specification with timestamp
Conflicts:
src/Symfony/Component/Yaml/Tests/InlineTest.php
* 2.8:
`@throws` annotations should go after `@return`
Fix merge
updated VERSION for 2.3.42
update CONTRIBUTORS for 2.3.42
updated CHANGELOG for 2.3.42
Revert "bug #18908 [DependencyInjection] force enabling the external XML entity loaders (xabbuh)"
Partial revert of previous PR
[DependencyInjection] Skip deep reference check for 'service_container'
Catch \Throwable
[Serializer] Add missing @throws annotations
Fix for #18843
force enabling the external XML entity loaders
Removed UTC specification with timestamp
Conflicts:
CHANGELOG-2.3.md
src/Symfony/Bundle/FrameworkBundle/Routing/DelegatingLoader.php
src/Symfony/Bundle/TwigBundle/Extension/AssetsExtension.php
src/Symfony/Component/Config/Loader/FileLoader.php
src/Symfony/Component/DependencyInjection/Container.php
src/Symfony/Component/DependencyInjection/ContainerBuilder.php
src/Symfony/Component/Finder/Expression/Expression.php
src/Symfony/Component/Finder/Finder.php
src/Symfony/Component/HttpKernel/DependencyInjection/ContainerAwareHttpKernel.php
src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php
* 2.7:
`@throws` annotations should go after `@return`
Fix merge
updated VERSION for 2.3.42
update CONTRIBUTORS for 2.3.42
updated CHANGELOG for 2.3.42
Revert "bug #18908 [DependencyInjection] force enabling the external XML entity loaders (xabbuh)"
Partial revert of previous PR
[DependencyInjection] Skip deep reference check for 'service_container'
Catch \Throwable
[Serializer] Add missing @throws annotations
Fix for #18843
force enabling the external XML entity loaders
Removed UTC specification with timestamp
Conflicts:
src/Symfony/Component/DependencyInjection/Tests/Dumper/PhpDumperTest.php
src/Symfony/Component/Finder/Finder.php
src/Symfony/Component/Security/Acl/Dbal/MutableAclProvider.php
src/Symfony/Component/Security/Acl/Domain/ObjectIdentity.php
src/Symfony/Component/Security/Acl/Model/AclInterface.php
src/Symfony/Component/Security/Acl/Model/MutableAclProviderInterface.php
src/Symfony/Component/Security/Acl/Permission/MaskBuilder.php
src/Symfony/Component/Translation/Loader/XliffFileLoader.php
src/Symfony/Component/Yaml/Tests/InlineTest.php
* 2.3:
updated VERSION for 2.3.42
update CONTRIBUTORS for 2.3.42
updated CHANGELOG for 2.3.42
Revert "bug #18908 [DependencyInjection] force enabling the external XML entity loaders (xabbuh)"
Partial revert of previous PR
[DependencyInjection] Skip deep reference check for 'service_container'
Catch \Throwable
[Serializer] Add missing @throws annotations
Fix for #18843
force enabling the external XML entity loaders
Removed UTC specification with timestamp
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Cache] Added PhpFilesAdapter
| 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 is taking over #18832.
With a warm cache I get these numbers consistently (PhpArrayAdapter being the implem in #18823 ):
```
Fetching randomly 5000 items 10000 times:
Symfony\Component\Cache\Adapter\FilesystemAdapter: 0.1367, 2 megabytes
Symfony\Component\Cache\Adapter\PhpArrayAdapter: 0.0071, 2 megabytes
Symfony\Component\Cache\Adapter\PhpFilesAdapter: 0.0389, 2 megabytes
Symfony\Component\Cache\Adapter\ApcuAdapter: 0.0361, 2 megabytes
```
This means that the PhpArrayAdapter should be used first, then ApcuAdapter preferred over PhpFilesAdapter, then FilesystemAdapter. This is what AbstractAdapter does here.
Also note that to get the cache working, one should stay within the limits defined by the following ini settings:
- memory_limit
- apc.shm_size
- opcache.memory_consumption
- opcache.interned_strings_buffer
- opcache.max_accelerated_files
Commits
-------
8983e83 [Cache] Optimize & wire PhpFilesAdapter
14bcd79 [Cache] Added PhpFilesAdapter
* 3.1:
[travis] Don't use parallel on HHVM
[HttpKernel] Fix RequestDataCollector starting the session
[appveyor] Ignore STATUS_HEAP_CORRUPTION errors on Windows
[FrameworkBundle] Skip redis cache pools test on failed connection
Fixed forwarded request data in templates
[Security] Fix DebugAccessDecisionManager when object is not a scalar
Skip some tests on HHVM due to a PHPunit bug
Use the Trusty Travis infrastructure for HHVM builds
LdapUserProvider: add missing argument type doc
Fixed issue with missing argument in the abstract service definition for the ldap user provider
Add 3.1 to PR template branch row, remove 2.3
Improve memory efficiency
[Console] Fix BC break introduced by #18101
document method name changes in Voter class
add missing hint for vote() argument type
[#18838] add a test to avoid regressions
bumped Symfony version to 3.1.1
updated VERSION for 3.1.0
updated CHANGELOG for 3.1.0
Conflicts:
src/Symfony/Component/HttpKernel/Kernel.php
* 3.0:
[travis] Don't use parallel on HHVM
[appveyor] Ignore STATUS_HEAP_CORRUPTION errors on Windows
Skip some tests on HHVM due to a PHPunit bug
Use the Trusty Travis infrastructure for HHVM builds
Add 3.1 to PR template branch row, remove 2.3
Improve memory efficiency
document method name changes in Voter class
Conflicts:
.travis.yml
* 2.8:
[travis] Don't use parallel on HHVM
[appveyor] Ignore STATUS_HEAP_CORRUPTION errors on Windows
Skip some tests on HHVM due to a PHPunit bug
Use the Trusty Travis infrastructure for HHVM builds
Add 3.1 to PR template branch row, remove 2.3
Improve memory efficiency
document method name changes in Voter class
Conflicts:
.travis.yml
UPGRADE-3.0.md
src/Symfony/Component/HttpKernel/Tests/DataCollector/DumpDataCollectorTest.php
* 2.7:
[travis] Don't use parallel on HHVM
[appveyor] Ignore STATUS_HEAP_CORRUPTION errors on Windows
Skip some tests on HHVM due to a PHPunit bug
Use the Trusty Travis infrastructure for HHVM builds
Add 3.1 to PR template branch row, remove 2.3
Improve memory efficiency
This PR was merged into the 2.7 branch.
Discussion
----------
Improve memory efficiency
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
This avoids concatenating `$message` and `PHP_EOL` (if necessary) as a new value, greatly improving memory efficiency for large `$message`s.
Commits
-------
c1df9f2 Improve memory efficiency
This PR was merged into the 3.1 branch.
Discussion
----------
[3.1][HttpKernel] Fix RequestDataCollector starting the session
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18951
| License | MIT
The RequestDataCollector starts a non-started session on kernel response. This produces bug #18951
I'm not sure if this is the right fix, let's discuss it.
Commits
-------
ab62dcf [HttpKernel] Fix RequestDataCollector starting the session
This PR was merged into the 2.7 branch.
Discussion
----------
Run an uptodate version of HHVM on Travis
| Q | A
| ------------- | ---
| Branch? |2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR | n/a
Using the Trusty infrastructure allows running an uptodate version of HHVM rather than running the latest version supporting Precise, which is very old.
It relies on an undocumented feature of the Travis config file, namely the fact that ``matrix.include`` actually allows to overwrite everything from the config file (it is merged with the main config), even though the Travis linter complains about it. I think it is fine to use this and to replace it with an official approach once there is one.
Refs #18922
Commits
-------
e6956c9 Skip some tests on HHVM due to a PHPunit bug
e041da0 Use the Trusty Travis infrastructure for HHVM builds
This PR was merged into the 3.1 branch.
Discussion
----------
[#18838] add a test to avoid regressions
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18838
| License | MIT
| Doc PR |
Commits
-------
240cf0a [#18838] add a test to avoid regressions
This PR was merged into the 2.3 branch.
Discussion
----------
[DependencyInjection] force enabling the external XML entity loaders
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18876
| License | MIT
| Doc PR |
Commits
-------
142b1a4 force enabling the external XML entity loaders
This PR was merged into the 2.3 branch.
Discussion
----------
[DependencyInjection] Skip deep reference check for 'service_container'
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
The "hasReference" check when dumping the container fails in the case where a service has a method call which includes a reference to a private/inlined service when either that service, or a dependency of it, references the service_container. This because service_container isn't defined while it still tries to check the references of it. So the service_container must be skipped in this case, this shouldn't break anything as the service_container doesn't reference any services, and thus can't reference the service which it is checking for.
Commits
-------
6f36733 [DependencyInjection] Skip deep reference check for 'service_container'
Deep checks on whether a service references another service need to
exclude the 'service_container' service as it doesn't exist. Without this
dumping the container will fail if a service definition references an
inlined service which has a direct or indirect dependency to the
service_container.
This PR was merged into the 2.3 branch.
Discussion
----------
[2.3][Form] Removed UTC specification with timestamp
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
The function `date_parse()` indicates a warning if a timezone is used with the timestamp: `Double timezone specification`. I removed the UTC specification and this time it's more faster!
Commits
-------
0d14aac Removed UTC specification with timestamp
This PR was squashed before being merged into the 2.3 branch (closes#18861).
Discussion
----------
Fix for #18843
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18843
| License | MIT
| Doc PR | -
Commits
-------
7d78196 Fix for #18843
* 3.1:
[Console] SymfonyStyle: Fix alignment/prefixing of multi-line comments
[Routing] Finish annotation loader taking a class constant as a beginning of a class name
[Routing] Fix the annotation loader taking a class constant as a beginning of a class name
* 3.0:
[Console] SymfonyStyle: Fix alignment/prefixing of multi-line comments
[Routing] Finish annotation loader taking a class constant as a beginning of a class name
[Routing] Fix the annotation loader taking a class constant as a beginning of a class name
* 2.8:
[Console] SymfonyStyle: Fix alignment/prefixing of multi-line comments
[Routing] Finish annotation loader taking a class constant as a beginning of a class name
[Routing] Fix the annotation loader taking a class constant as a beginning of a class name
* 2.7:
[Routing] Finish annotation loader taking a class constant as a beginning of a class name
[Routing] Fix the annotation loader taking a class constant as a beginning of a class name
* 2.3:
[Routing] Finish annotation loader taking a class constant as a beginning of a class name
[Routing] Fix the annotation loader taking a class constant as a beginning of a class name
This PR was merged into the 2.3 branch.
Discussion
----------
[Routing] Fix the annotation loader taking a class constant as a beginning of a class name
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18633
| License | MIT
| Doc PR | -
Code copy/pasted from ClassMapGenerator.php
Commits
-------
8d4f35d [Routing] Finish annotation loader taking a class constant as a beginning of a class name
43c7f9b [Routing] Fix the annotation loader taking a class constant as a beginning of a class name
* 3.1:
[PropertyAccess] Fix for PHP 7.0.7
[Yaml] search for colons in strings only
bumped Symfony version to 3.1.0
updated VERSION for 3.1.0-RC1
updated CHANGELOG for 3.1.0-RC1
fixed PHP 5.3 compat in tests
Since the parser is able to return `\DateTime` instances when the
`Yaml::PARSE_DATETIME` flag is passed, we need to ensure that the parsed
value actually is a string before passing the parsed value to string
functions.
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Cache] Create NullAdapter to disable cache if needed
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | WIP
| Fixed tickets | -
| License | MIT
| Doc PR | -
Tthis PR aims to implement a Symfony Cache Null adapter able to disable cache if needed (very useful in tests or in the case of the fallback of the OpCacheAdapter for instance).
This PR is required by https://github.com/symfony/symfony/pull/18823 and https://github.com/symfony/symfony/pull/18533
Commits
-------
0519d22 [Cache] Create NullAdapter to disable cache if needed
* 3.1:
[Console] SymfonyStyle: Align multi-line/very-long-line blocks
[Console][DX] Fixed ambiguous error message when using a duplicate option shortcut
Fix js comment in profiler
[Ldap] Fixed issue with Entry password attribute containing array of values and made password attribute configurable
[Serializer][#18837] adding a test
[Cache] Drop counting hit/miss in ProxyAdapter
[Serializer] AbstractObjectNormalizer: be sure that isAllowedAttribute is called
[Serializer] ObjectNormalizer: add missing parameters
This PR was merged into the 3.1 branch.
Discussion
----------
[Serializer][#18837] adding a test
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18837
| License | MIT
| Doc PR |
Commits
-------
37cacc4 [Serializer][#18837] adding a test
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Debug] More compact HTML
| 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 patch makes the HTML output for exception stack traces slightly more compact. This makes the stack trace a bit more readable when inspecting the HTML source, e.g. when using cURL.
1. Vendor-specific prefixes for border-radius are removed. They are not relevant [in any modern browser](http://caniuse.com/border-radius).
2. The ondblclick is now added only once and relies on event bubbling rather than being added to every `<li>` in the stack trace.
3. Single quotes are not escaped. Escaping single quotes is only required for values enclosed in single quoted HTML attributes - all our attributes are double-quoted.
Commits
-------
9613b75 [Debug] More compact HTML
* 3.1: (24 commits)
[Yaml] fix exception contexts
Added people - person inflection
People - person singularization
[Yaml] properly handle unindented collections
[Serializer] Add test for ignored attributes during denormalization
chomp newlines only at the end of YAML documents
Fixed server status command when port has been omitted
Update UPGRADE FROM 2.x to 3.0
[Config] Allow schemed path in FileResource
fix removed commands wording in upgrade file
Catch \Throwable
Catch \Throwable
[DependencyInjection] Avoid generating call_user_func in more cases
[Validator] Support for DateTimeImmutable
[YAML] fixed "dump" signature in upgrade file
[Cache] Rename nonce to version
[FrameworkBundle] update upgrade instructions
Use levenshtein level for better Bundle matching
[WebProfilerBundle] Fix CORS ajax security issues
remove methods that were needed for PHP 5.3
...
* 3.0:
[Yaml] fix exception contexts
People - person singularization
[Yaml] properly handle unindented collections
[Serializer] Add test for ignored attributes during denormalization
chomp newlines only at the end of YAML documents
Fixed server status command when port has been omitted
Update UPGRADE FROM 2.x to 3.0
fix removed commands wording in upgrade file
Catch \Throwable
Catch \Throwable
[DependencyInjection] Avoid generating call_user_func in more cases
[Validator] Support for DateTimeImmutable
[FrameworkBundle] update upgrade instructions
Use levenshtein level for better Bundle matching
[WebProfilerBundle] Fix CORS ajax security issues
remove methods that were needed for PHP 5.3
[DX][DI] Make Autowiring exceptions more future friendly
* 2.8:
[Yaml] fix exception contexts
People - person singularization
[Yaml] properly handle unindented collections
[Serializer] Add test for ignored attributes during denormalization
chomp newlines only at the end of YAML documents
Fixed server status command when port has been omitted
Update UPGRADE FROM 2.x to 3.0
fix removed commands wording in upgrade file
Catch \Throwable
Catch \Throwable
Use levenshtein level for better Bundle matching
[WebProfilerBundle] Fix CORS ajax security issues
[DX][DI] Make Autowiring exceptions more future friendly
* 2.7:
[Yaml] fix exception contexts
People - person singularization
[Yaml] properly handle unindented collections
[Serializer] Add test for ignored attributes during denormalization
chomp newlines only at the end of YAML documents
Fixed server status command when port has been omitted
Update UPGRADE FROM 2.x to 3.0
Catch \Throwable
Use levenshtein level for better Bundle matching
[WebProfilerBundle] Fix CORS ajax security issues
* 2.3:
[Yaml] fix exception contexts
People - person singularization
[Yaml] properly handle unindented collections
chomp newlines only at the end of YAML documents
This PR was merged into the 2.8 branch.
Discussion
----------
Catch \Throwable
| Q | A
| ------------- | ---
| Branch? | 2.8, 3.0
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | Mostly!
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
The first commit is based on symfony/symfony#15949
Depends on symfony/symfony#18813, symfony/symfony#18812
----
I'm new to symfony, so I'm not sure where are all the places where it makes sense to actually catch the throwable and where not. I added most places that seemed logical and when I wasn't sure, I added it anyway. I'm hoping you guys (and girls?) can point out the places where the catch should not be added, I'll fix it and then I can create several PR's for the older branches. A lot of this IMHO should go also to 3.0.
Commits
-------
de671f4 Catch \Throwable
This PR was squashed before being merged into the 3.0 branch (closes#18759).
Discussion
----------
[Validator] Support for DateTimeImmutable
| Q | A
| ------------- | ---
| Branch? | 3.0
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18752
| License | MIT
| Doc PR |
When validating with DateTime constraint UnexpectedTypeException is thrown for DateTimeImmutable instances.
Why PR?
- DateTimeImmutable behaves like a DateTime. Both implements the same interface DateTimeInterface.
- DateTimeInterface cannot be implemented by the client.
Commits
-------
f49659f [Validator] Support for DateTimeImmutable
This PR was merged into the 3.2-dev branch.
Discussion
----------
[Yaml] Allow using _ in some numeric notations
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | no ?
| New feature? | yes ?
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18094
| License | MIT
| Doc PR | ~
Allows to use the `_` to group "big" ints, as suggested in the yaml integer type specification. As discussed in #18094, we should check if it is still part of the 1.2 specification, but I don't really see why not ? I can't see anywhere anything saying it is not valid anymore... as there are links to these types in some other specs.
This is #18096, but targetted on master as this is considered as a new feature. I also support the dump of such values as only strings. I think I should change how it is dumped thoug, and use the escape filter instead though (as I was misusing the data provider and it provided strange results at the time)
Commits
-------
e6da11c [Yaml] Allow using _ in some numeric notations
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Ldap] Added the possibility to configure all available Ldap options for connection
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18448
| License | MIT
| Doc PR |
This PR lets a user configure [all documented Ldap options](http://php.net/manual/fr/function.ldap-get-option.php), as well as a few undocumented ones (back-ported from the [OpenLdap C library](http://linux.die.net/man/3/ldap_set_option), as well as the [Ldap client specification](https://www.ietf.org/proceedings/50/I-D/ldapext-ldap-c-api-05.txt)).
Commits
-------
a8bae31 Added the possibility to configure all Ldap options for connection
* 3.0:
Fix computation of PR diffs for component matrix lines
[console][table] adjust width of colspanned cell.
[BUG] Delete class 'control-group' in bootstrap 3
[2.8] [Form] Modified iterator_to_array's 2nd parameter to false in ViolationMapper
added missing constant in Response
Update HTTP statuses list
[Console][#18619] Prevent fatal error when calling Command#getHelper() without helperSet
added StaticVerionStrategyTest
Add SplFileInfo array doc on Finder iterator methods so that IDE will know what it returns
[2.3] [Form] Modified iterator_to_array's 2nd parameter to false in ViolationMapper
Updated the link to the list of currency codes
Fixed DateTimeInterface comparaison
[console][table] adjust width of colspanned cell.
* 2.8:
Fix computation of PR diffs for component matrix lines
[console][table] adjust width of colspanned cell.
[BUG] Delete class 'control-group' in bootstrap 3
[2.8] [Form] Modified iterator_to_array's 2nd parameter to false in ViolationMapper
added missing constant in Response
Update HTTP statuses list
[Console][#18619] Prevent fatal error when calling Command#getHelper() without helperSet
added StaticVerionStrategyTest
Add SplFileInfo array doc on Finder iterator methods so that IDE will know what it returns
[2.3] [Form] Modified iterator_to_array's 2nd parameter to false in ViolationMapper
Updated the link to the list of currency codes
[console][table] adjust width of colspanned cell.
* 2.7:
Fix computation of PR diffs for component matrix lines
[BUG] Delete class 'control-group' in bootstrap 3
[2.8] [Form] Modified iterator_to_array's 2nd parameter to false in ViolationMapper
This PR was merged into the 3.1-dev branch.
Discussion
----------
Make failed autowiring error messages more explicit
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no (better DX integration)
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18658
| License | MIT
| Doc PR | N/A
@nicolas-grekas This is a port from #18691 (which was for **2.8**).
It looks like the original PR has been already mostly implemented in **master** by @weaverryan (in #17877).
IMO, this PR is still improving two use cases:
* In case a class cannot be autowired because no service can be found AND a service cannot be registered automatically, the error message now mentions both conditions (instead of simply saying no service has been found)
* In case a class with no service attached to it can be automatically instantiated but cannot be autowired because of further problems, an exception mentioning this is now thrown instead of the lower level exception, making the situation easier to debug. (The lower level exception is still available through `getPrevious()`)
Hence, I still think this PR provides useful additional DX features and is worth to be merged.
Commits
-------
6894e03 Make failed autowiring error messages more explicit
This PR was merged into the 3.1-dev branch.
Discussion
----------
[FrameworkBundle] Default to Apcu+Filesystem cache chain
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | yes (perf)
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
In #16838, @dunglas benched that the filesystem cache is not the fastest one (not a surprise).
Yet, it is the default for now. I propose to replace this default by a dynamically created one that uses APCu when available (of course, we cannot do the check at container-build time), chained with the filesystem.
The benefit is double: APCu is automatically used when available without any configuration, and cache warming up is seeded by the filesystem cache so that the apcu cache can benefit from it.
Commits
-------
b9b57f9 [FrameworkBundle] Default to Apcu+Filesystem cache chain
This PR was merged into the 3.1-dev branch.
Discussion
----------
[DomCrawler] Expose getter for uri
| Q | A
| ------------- | ---
| Branch |
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Same as #18143
Commits
-------
baebdb4 [DomCrawler] Exposed getter for uri
* 2.7:
added missing constant in Response
Update HTTP statuses list
[Console][#18619] Prevent fatal error when calling Command#getHelper() without helperSet
added StaticVerionStrategyTest
Add SplFileInfo array doc on Finder iterator methods so that IDE will know what it returns
[2.3] [Form] Modified iterator_to_array's 2nd parameter to false in ViolationMapper
Updated the link to the list of currency codes
[console][table] adjust width of colspanned cell.
* 2.3:
Update HTTP statuses list
[Console][#18619] Prevent fatal error when calling Command#getHelper() without helperSet
Add SplFileInfo array doc on Finder iterator methods so that IDE will know what it returns
[2.3] [Form] Modified iterator_to_array's 2nd parameter to false in ViolationMapper
Updated the link to the list of currency codes
This PR was merged into the 3.1-dev branch.
Discussion
----------
[HttpKernel] Add request method to logger messages
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
While debugging some functional tests I was looking at the test.log. It would have been quite useful to know if the request was a POST or GET. This adds the request method to the log details.
Commits
-------
d751d59 Add request method to logger messages
This PR was merged into the 3.0 branch.
Discussion
----------
[3.0] Fixed DateTimeInterface comparison
| Q | A
| ------------- | ---
| Branch? | 3.0
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
DateTime class implements the DateTimeInterface.
It is useless to compare is a value is an instance of DateTime or DateTimeInterface.
Commits
-------
9a0bc99 Fixed DateTimeInterface comparaison
This PR was squashed before being merged into the 2.3 branch (closes#18761).
Discussion
----------
[2.3] [Form] Modified iterator_to_array's 2nd parameter to false in ViolationMapper
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
For https://github.com/symfony/symfony/pull/18747
Commits
-------
7101cab [2.3] [Form] Modified iterator_to_array's 2nd parameter to false in ViolationMapper
This PR was merged into the 2.3 branch.
Discussion
----------
Updated the link to the list of currency codes
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18758
| License | MIT
| Doc PR | -
Commits
-------
09b70a1 Updated the link to the list of currency codes
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Clean RedisAdapter pipelining + FilesystemAdapter
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This PR refactorize Redis pipelining so that the case for handling RedisArray is abstracted, thus less bug prone.
Commits
-------
acf0075 [Cache] Clean RedisAdapter pipelining + FilesystemAdapter
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Add nonce based cache invalidation to ApcuAdapter
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
APCu cache invalidation is tedious because it can't be done from the cli.
This PR adds and wires a nonce based cache invalidation strategy to work around this limitation.
Commits
-------
a7899fe [Cache] Add nonce based cache invalidation to ApcuAdapter
This PR was squashed before being merged into the 3.1-dev branch (closes#18762).
Discussion
----------
[Translation] XLIFF Add `id` to meta data.
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | maybe/no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
I would like to get the `id` attribute value from parsed XLIFF v1.2 files in the meta data (of the catalogue).
Commits
-------
ad4adca [Translation] XLIFF Add uid=501(fabien) gid=20(staff) groups=20(staff),401(com.apple.sharepoint.group.1),12(everyone),61(localaccounts),79(_appserverusr),80(admin),81(_appserveradm),98(_lpadmin),33(_appstore),100(_lpoperator),204(_developer),395(com.apple.access_ftp),398(com.apple.access_screensharing),399(com.apple.access_ssh) to meta data.
* 3.0: (31 commits)
Drop hirak/prestissimo
[MonologBridge] Uninstallable together with symfony/http-kernel in 3.0.6
bumped Symfony version to 3.0.7
updated VERSION for 3.0.6
updated CHANGELOG for 3.0.6
bumped Symfony version to 2.8.7
updated VERSION for 2.8.6
updated CHANGELOG for 2.8.6
bumped Symfony version to 2.7.14
updated VERSION for 2.7.13
updated CHANGELOG for 2.7.13
bumped Symfony version to 2.3.42
[Debug] Fix fatal error handlers on PHP 7
updated VERSION for 2.3.41
update CONTRIBUTORS for 2.3.41
updated CHANGELOG for 2.3.41
fixed bad merge
Fixed issue with blank password with Ldap
limited the maximum length of a submitted username
[2.3][Component/Security] Fixed phpdoc in AnonymousToken constructor for user param
...
Conflicts:
src/Symfony/Component/DependencyInjection/Compiler/AutowirePass.php
src/Symfony/Component/DependencyInjection/Tests/Compiler/AutowirePassTest.php
src/Symfony/Component/HttpKernel/Kernel.php
* 2.8:
Drop hirak/prestissimo
bumped Symfony version to 2.8.7
updated VERSION for 2.8.6
updated CHANGELOG for 2.8.6
bumped Symfony version to 2.7.14
updated VERSION for 2.7.13
updated CHANGELOG for 2.7.13
bumped Symfony version to 2.3.42
[Debug] Fix fatal error handlers on PHP 7
updated VERSION for 2.3.41
update CONTRIBUTORS for 2.3.41
updated CHANGELOG for 2.3.41
Conflicts:
CHANGELOG-2.3.md
CHANGELOG-2.7.md
CHANGELOG-3.0.md
appveyor.yml
src/Symfony/Component/HttpKernel/Kernel.php
* 2.7:
Drop hirak/prestissimo
bumped Symfony version to 2.7.14
updated VERSION for 2.7.13
updated CHANGELOG for 2.7.13
bumped Symfony version to 2.3.42
[Debug] Fix fatal error handlers on PHP 7
updated VERSION for 2.3.41
update CONTRIBUTORS for 2.3.41
updated CHANGELOG for 2.3.41
Conflicts:
src/Symfony/Component/HttpKernel/Kernel.php
This PR was merged into the 2.8 branch.
Discussion
----------
Fixed issue with blank password with Ldap
| Q | A
| ------------- | ---
| Branch? | 1.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
Commits
-------
c7d9c62 Fixed issue with blank password with Ldap
The bind operation of LDAP, as described in RFC 4513, provides a method
which allows for authentication of users. For the Simple Authentication
Method a user may use the anonymous authentication mechanism, the
unauthenticated authentication mechanism, or the name/password
authentication mechanism. The unauthenticated authentication mechanism
is used when a client who desires to establish an anonymous
authorization state passes a non-zero length distinguished name and a
zero length password. Most LDAP servers either can be configured to
allow this mechanism or allow it by default.
_Web-based applications which perform the simple bind operation with the
client's credentials are at risk when an anonymous authorization state is
established. This can occur when the web-based application passes a
distinguished name and a zero length password to the LDAP server._
Thus, misconfiguring a server with simple bind can trick Symfony into
thinking the username/password tuple as valid, potentially leading to
unauthorized access.
* 2.8:
[2.3][Component/Security] Fixed phpdoc in AnonymousToken constructor for user param
prevent calling get() for service_container service
call get() after the container was compiled
Fixed readme of OptionsResolver
top-level anonymous services must be public
[DependencyInjection] Suggest ExpressionLanguage in composer.json
added a conflict between Monolog bridge 2.8 and HTTP Kernel 3.0+
* 2.7:
[2.3][Component/Security] Fixed phpdoc in AnonymousToken constructor for user param
prevent calling get() for service_container service
call get() after the container was compiled
Fixed readme of OptionsResolver
[DependencyInjection] Suggest ExpressionLanguage in composer.json
* 2.3:
[2.3][Component/Security] Fixed phpdoc in AnonymousToken constructor for user param
call get() after the container was compiled
Fixed readme of OptionsResolver
This PR was merged into the 2.7 branch.
Discussion
----------
[DependencyInjection] Suggest ExpressionLanguage in composer.json
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
As the DependencyInjection component has lots of classes containing uses of the ExpressionLanguage component, I propose to add it to the composer.json suggests.
Commits
-------
d6c9073 [DependencyInjection] Suggest ExpressionLanguage in composer.json
This PR was squashed before being merged into the 2.3 branch (closes#18727).
Discussion
----------
[2.3][Component/Security] Fixed phpdoc in AnonymousToken constructor for user param
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes, phpdoc one
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Updated phpdoc of AnonymousToken $user param from string to string|object since an object is allowed to in the parent AbstractToken: https://github.com/symfony/symfony/blob/2.3/src/Symfony/Component/Security/Core/Authentication/Token/AbstractToken.php#L91
Commits
-------
b1c60b4 [2.3][Component/Security] Fixed phpdoc in AnonymousToken constructor for user param
The `getListenerPriority()` method was added to the event dispatcher
interface in Symfony 3.0. Thus, it no longer makes sense to have a test
that expects the method not to exist (the corresponding code in the
`TraceableEventDispatcher` was already removed in 576a55c.
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Add support for Predis, RedisArray and RedisCluster
| Q | A
| ------------- | ---
| Branch? | 3.1 ideally
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
b004243 [Cache] Add support for Predis, RedisArray and RedisCluster
* 2.8:
[EventDispatcher] check for method to exist
[DependencyInjection] Fixed the priority of service decoration on service with parent
Make failed autowiring error messages more explicit
This PR was merged into the 2.8 branch.
Discussion
----------
[EventDispatcher] check for method to exist
| 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/16301#issuecomment-193150055
| License | MIT
| Doc PR |
This change must be reverted after being merged into the `3.0` branch (the `getListenerPriority()` method was added to the interface in Symfony 3.0).
Commits
-------
78ae2ad [EventDispatcher] check for method to exist
This PR was merged into the 2.8 branch.
Discussion
----------
[DX][DI] Make failed autowiring error messages more explicit
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no (better DX integration)
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18658
| License | MIT
| Doc PR | N/A
This is the PR improving the auto wiring error messages.
Two errors messages have augmented:
If a type-hint does not match any existing type and a service for this type cannot be automatically created, the error message now says so, instead of simply saying the type cannot be autowired.
If a type-hint matches multiple services and none of them provides an autowiringType for it, the error message now says so and list the candidate services, instead of simply saying the type cannot be autowired.
Commits
-------
2ac81f9 Make failed autowiring error messages more explicit
This PR was merged into the 2.8 branch.
Discussion
----------
[DependencyInjection] Use the priority of service decoration on service with parent
| 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 |
Commits
-------
d1ad43c [DependencyInjection] Fixed the priority of service decoration on service with parent
* 3.0: (24 commits)
add @Event annotation for AuthenticationEvents
bumped Symfony version to 3.0.6
updated VERSION for 3.0.5
updated CHANGELOG for 3.0.5
bumped Symfony version to 2.8.6
[PropertyInfo] PHPDoc correction
add @Event annotation for KernelEvents
Fixed typo
updated VERSION for 2.8.5
updated CHANGELOG for 2.8.5
bumped Symfony version to 2.7.13
updated VERSION for 2.7.12
update CONTRIBUTORS for 2.7.12
updated CHANGELOG for 2.7.12
bumped Symfony version to 2.3.41
updated VERSION for 2.3.40
update CONTRIBUTORS for 2.3.40
updated CHANGELOG for 2.3.40
Revert "minor #18257 [Routing] Don't needlessly execute strtr's as they are fairly expensive (arjenm)"
Revert "fixed CS"
...
* 2.8:
add @Event annotation for AuthenticationEvents
bumped Symfony version to 2.8.6
[PropertyInfo] PHPDoc correction
add @Event annotation for KernelEvents
updated VERSION for 2.8.5
updated CHANGELOG for 2.8.5
bumped Symfony version to 2.7.13
updated VERSION for 2.7.12
update CONTRIBUTORS for 2.7.12
updated CHANGELOG for 2.7.12
bumped Symfony version to 2.3.41
updated VERSION for 2.3.40
update CONTRIBUTORS for 2.3.40
updated CHANGELOG for 2.3.40
Revert "minor #18257 [Routing] Don't needlessly execute strtr's as they are fairly expensive (arjenm)"
Revert "fixed CS"
fixed deprecation notices in tests
[Security] Normalize "symfony/security-acl" dependency versions across all composer.json files
[FrameworkBundle] Remove misleading comment
bug #17460 [DI] fix ambiguous services schema
* 2.7:
add @Event annotation for AuthenticationEvents
add @Event annotation for KernelEvents
bumped Symfony version to 2.7.13
updated VERSION for 2.7.12
update CONTRIBUTORS for 2.7.12
updated CHANGELOG for 2.7.12
bumped Symfony version to 2.3.41
updated VERSION for 2.3.40
update CONTRIBUTORS for 2.3.40
updated CHANGELOG for 2.3.40
Revert "minor #18257 [Routing] Don't needlessly execute strtr's as they are fairly expensive (arjenm)"
Revert "fixed CS"
[FrameworkBundle] Remove misleading comment
bug #17460 [DI] fix ambiguous services schema
* 2.3:
add @Event annotation for AuthenticationEvents
bumped Symfony version to 2.3.41
updated VERSION for 2.3.40
update CONTRIBUTORS for 2.3.40
updated CHANGELOG for 2.3.40
bug #17460 [DI] fix ambiguous services schema
This PR was merged into the 3.1-dev branch.
Discussion
----------
add @Event annotation for AuthenticationEvents
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18684
| License | MIT
split of #18684 for targeting 2.3 branch
Commits
-------
e2c1270 add @Event annotation for AuthenticationEvents
While debugging some functional tests I was looking at the test.log. It would have been quite useful to know if the request was a POST or GET. This adds to the log details.
This PR was merged into the 3.1-dev branch.
Discussion
----------
Updating the error message of an AuthenticationEntryPointInterface
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | not necessary
During a training, we forgot to fill in the `start()` method for an entry point and got a *horrible* error message. Now, if you mess up `start()`, you get:
![screen shot 2016-04-27 at 12 49 50 pm](https://cloud.githubusercontent.com/assets/121003/14860378/92578e68-0c76-11e6-9fe5-45141fe2ce43.png)
Thanks!
Commits
-------
7b6c56c Updating the error message of an AuthenticationEntryPointInterface returns a non-Response object
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Dont use Redis connection when not required
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
1165459 [Cache] Dont use Redis connection when not required
This PR was merged into the 2.8 branch.
Discussion
----------
[Security] Normalize "symfony/security-acl" dependency versions across all composer.json files
| 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 |
There are some inconsistencies in the Symfony 2.8 `symfony/security-acl` dependency versions that would help downstream if we could just package `symfony/security-acl` 3.0.0 instead of having to package both versions 2.8.0 (for Symfony 2.8) and 3.0.0 (for Symfony 3.0).
```
$ git clone https://github.com/symfony/symfony.git
Cloning into 'symfony'...
cd remote: Counting objects: 319438, done.
nyReceiving objects: 4% (12778/319438), 2.06 MiB | 4.12 MiB/s
4Receiving objects: 41% (130970/319438), 40.80 MiB | 7.86 MiB/s
remote: Total 319438 (delta 0), reused 0 (delta 0), pack-reused 319437
Receiving objects: 100% (319438/319438), 68.46 MiB | 8.21 MiB/s, done.
Resolving deltas: 100% (204691/204691), done.
Checking connectivity... done.
$ cd symfony
$ git checkout v2.8.4
Previous HEAD position was 4e17cb2... Merge branch '2.8' into 3.0
HEAD is now at 9e14f9f... Merge branch '2.7' into 2.8
$ find . -name 'composer.json' | xargs grep 'symfony/security-acl'
./src/Symfony/Bundle/SecurityBundle/composer.json: "symfony/security-acl": "~2.7|~3.0.0",
./src/Symfony/Bridge/Twig/composer.json: "symfony/security-acl": "~2.6|~3.0.0",
./src/Symfony/Component/Security/composer.json: "symfony/security-acl": "~2.7",
./composer.json: "symfony/security-acl": "~2.7",
```
Commits
-------
e249bc3 [Security] Normalize "symfony/security-acl" dependency versions across all composer.json files
This PR was merged into the 3.1-dev branch.
Discussion
----------
Fixed a redundant check in DefaultValueResolver
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
In #18308 I have introduced a `DefaultValueResolver`. When writing documentation, I was planning on adding the code as an example and I noticed it did a check in the request attributes. A default value value should always be injected, whether the request has it or not. In case the request _does_ have the value, it would've already been added and thus never reach the default resolver.
Thus as this is never called in the default and configured flows and should not change the default value behavior, I'm removing this.
Commits
-------
e54c1a6 Fixed a redundant check in DefaultValueResolver
This PR was merged into the 3.1-dev branch.
Discussion
----------
[LDAP] Check whether an entry attribute exists
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Currently a method exists for getting the value of an attribute. It would make the Entry class more complete to be able to simply test if an attribute exists in the entry.
Commits
-------
56ef8a0 [LDAP] Check whether an entry attribute exists
This PR was merged into the 3.1-dev branch.
Discussion
----------
[HttpKernel] tweaked redirection profiling in RequestDataCollector
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
- c8ba3b2 removes duplicated code forgotten in #17589
- a47d2e8 fixes the collecting of redirect data in first sub request instead of redirected master request.
Commits
-------
df19c14 use a request attribute flag for redirection profile
b26cb6d [HttpKernel] added RequestDataCollector::onKernelResponse()
c8ba3b2 [HttpKernel] remove legacy duplicated code
This PR was merged into the 2.7 branch.
Discussion
----------
[Form] fixed BC break with pre selection of choices with `ChoiceType` and its children
| Q | A
| ------------- | ---
| Branch | 2.7+
| Bugfix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18173, #14712, #17789
| License | MIT
| Doc PR | -
- f7eea72 reverts BC break introduced in #17760
- 58e8ed0 fixes pre selection of choice with model values such as `false`, `null` or empty string without BC break.
`ChoiceType` now always use `ChoiceToValueTransformer` or `ChoicesToValuesTransformer` depending on `multiple` option.
Hence `CheckboxListMapper` and `RadioListMapper` don't handle the transformation anymore.
Commits
-------
ea5375c [Form] refactor CheckboxListMapper and RadioListMapper
71841c7 Revert "[Form] refactor `RadioListMapper::mapDataToForm()`"
This PR was merged into the 2.8 branch.
Discussion
----------
[Console] Fix wrong exceptions being thrown
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets |
| License | MIT
| Doc PR |
Commits
-------
28fca7c [Console] Fix wrong exceptions being thrown
This PR was merged into the 3.1-dev branch.
Discussion
----------
[FrameworkBundle][Serializer] Fix a deprecation triggered by the ClassMetadataFactory
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets |
| License | MIT
Without apparent reasons, [FOSRestBundle's tests fail](https://travis-ci.org/FriendsOfSymfony/FOSRestBundle/jobs/124384888) since https://github.com/symfony/symfony/pull/18561.
```
Passing a Doctrine Cache instance as 2nd parameter of the "Symfony\Component\Serializer\Mapping\Factory\ClassMetadataFactory" constructor is deprecated. This parameter will be removed in Symfony 4.0. Use the "Symfony\Component\Serializer\Mapping\Factory\CacheClassMetadataFactory" class instead: 6x
1x in ErrorWithTemplatingFormatTest::testSerializeExceptionHtml from FOS\RestBundle\Tests\Functional
1x in SerializerErrorTest::testSerializeExceptionJson from FOS\RestBundle\Tests\Functional
1x in SerializerErrorTest::testSerializeExceptionJsonWithoutDebug from FOS\RestBundle\Tests\Functional
1x in SerializerErrorTest::testSerializeExceptionXml from FOS\RestBundle\Tests\Functional
1x in SerializerErrorTest::testSerializeInvalidFormJson from FOS\RestBundle\Tests\Functional
1x in SerializerErrorTest::testSerializeInvalidFormXml from FOS\RestBundle\Tests\Functional
```
We don't use cache in our tests but some of them are not in ``debug`` mode (will change soon) so the cache is automatically used.
This PR fixes this deprecation by detecting if the cache used by the serializer is psr6 compliant or not (if it is, then it replaces the default metadata factory by an instance of the new class ``CacheClassMetadataFactory``, otherwise the second parameter of the ``ClassMetadataFactory`` is used).
Commits
-------
15579d5 [FrameworkBundle] Deprecate framework.serializer.cache
eccbffb [Serializer] Improve a deprecation message
96e418a Revert "[FrameworkBundle] Fallback to default cache system in production for serializer"
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Minor cleanup
| Q | A
| ------------- | ---
| Branch? | 3.1
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
5786f3d [Cache] Minor cleanup
* 3.0:
use stable 1.0.x Composer versions
Fix typo in VarDumper README
[DI] Fix AutowirePass fatal error with classes that have non-existing parents
[DependencyInjection] Tests for AutowirePass with missing parent class
[WebProfilerBunde] Give an absolute url in case the request occured from another domain
Conflicts:
src/Symfony/Component/DependencyInjection/Compiler/AutowirePass.php
src/Symfony/Component/DependencyInjection/Tests/Compiler/AutowirePassTest.php
* 2.8:
use stable 1.0.x Composer versions
Fix typo in VarDumper README
[DI] Fix AutowirePass fatal error with classes that have non-existing parents
[DependencyInjection] Tests for AutowirePass with missing parent class
[WebProfilerBunde] Give an absolute url in case the request occured from another domain
* 2.7:
use stable 1.0.x Composer versions
Fix typo in VarDumper README
[WebProfilerBunde] Give an absolute url in case the request occured from another domain
This PR was merged into the 2.8 branch.
Discussion
----------
[DI] Fix AutowirePass fatal error with classes that have non-existing parents
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18188
| License | MIT
| Doc PR | -
Commits
-------
202cc77 [DI] Fix AutowirePass fatal error with classes that have non-existing parents
1735b85 [DependencyInjection] Tests for AutowirePass with missing parent class
* 3.0:
[PropertyAccess] ->getValue() should be read-only
[VarDumper] Fix dumping type hints for non-existing parent classes
[Config] Fix XmlUtilsTest namespace
[Console] [TableHelper] make it work with SymfonyStyle.
Remove dead code
[FrameworkBundle] Better output for user in ContainerDebugCommand
[Routing] add query param if value is different from default
* 2.8:
[PropertyAccess] ->getValue() should be read-only
[VarDumper] Fix dumping type hints for non-existing parent classes
[Config] Fix XmlUtilsTest namespace
[Console] [TableHelper] make it work with SymfonyStyle.
Remove dead code
[Routing] add query param if value is different from default
Conflicts:
src/Symfony/Component/VarDumper/Tests/Caster/ReflectionCasterTest.php
* 2.7:
[PropertyAccess] ->getValue() should be read-only
[VarDumper] Fix dumping type hints for non-existing parent classes
[Config] Fix XmlUtilsTest namespace
[Console] [TableHelper] make it work with SymfonyStyle.
Remove dead code
[Routing] add query param if value is different from default
Conflicts:
src/Symfony/Component/VarDumper/Tests/Caster/ReflectionCasterTest.php
* 2.3:
[PropertyAccess] ->getValue() should be read-only
[Config] Fix XmlUtilsTest namespace
[Routing] add query param if value is different from default
Conflicts:
src/Symfony/Component/PropertyAccess/Tests/PropertyAccessorTest.php
* 3.0:
[DI] Fix internal caching in AutowirePass
[PropertyInfo] Remove useless return statement
[Console] use ANSI escape sequences in ProgressBar overwrite method
[HttpKernel] Fix wrong number of arguments in call of ExceptionListener::logException()
Replace iconv_*() uses by mb_*(), add mbstring polyfill when required
[DependencyInjection] Remove YAML check in CrossCheckTest
[Process] Consistently use getProcess() in tests
[LDAP] Free the search result after a search to free memory
[DependencyInjection] fix phpDoc
Conflicts:
src/Symfony/Component/Ldap/LdapClient.php
This PR was merged into the 2.7 branch.
Discussion
----------
[Console] [TableHelper] make it work with SymfonyStyle.
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | #18573
| License | MIT
| Doc PR | ~
Commits
-------
43cc93c [Console] [TableHelper] make it work with SymfonyStyle.
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Serializer] fix parent class of AbstractNormalizer
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/17545#discussion_r58012336
| License | MIT
| Doc PR |
We must maintain the parent class to not break BC.
Commits
-------
45b9ed9 fix parent class of AbstractNormalizer
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Serializer] Integrate the PropertyInfo Component (recursive denormalization and hardening)
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #16143, #17193, #14844
| License | MIT
| Doc PR | todo
Integrates the PropertyInfo Component in order to:
* denormalize a graph of objects recursively (see tests)
* harden the hydratation logic
The hardening part is interesting. Considering the following example:
```php
class Foo
{
public function setDate(\DateTimeInterface $date)
{
}
}
// initialize $normalizer
$normalizer->denormalize(['date' => 1234], Foo::class);
```
Previously, a PHP error was thrown because the type passed to the setter (an int) doesn't match the one checked with the typehint. With the PropertyInfo integration, an `UnexpectedValueExcption` is throw instead.
It's especially interesting for web APIs dealing with JSON documents. For instance in API Platform, previously a 500 error was thrown, but thanks to this fix a 400 HTTP code with a descriptive error message will be returned. (/cc @csarrazi @mRoca @blazarecki, it's an alternative to https://github.com/dunglas/php-to-json-schema for protecting an API).
/cc @mihai-stancu
Commits
-------
5194482 [Serializer] Integrate the PropertyInfo Component
6b464b0 Recursive denormalize using PropertyInfo
This PR was merged into the 3.1-dev branch.
Discussion
----------
DX: better error message if factory class is empty
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | ?
| Fixed tickets | -
| License | MIT
| Doc PR | -
i was trying to debug this service configuration:
```xml
<service id="repository.user" class="Doctrine\ORM\EntityRepository">
<argument>%user_entity_class%</argument>
<factory id="doctrine.orm.default_entity_manager" method="getRepository"/>
</service>
```
Turns out i should have used `<factory service=...` instead of `<factory id=...` but the error message does not even tell which service is wrong. The same happens when only specifying the `method=` attribute. The current exception message tells:
Cannot dump definition because of invalid class name ('')
With this change, the message at least tells the context, hopefully helping the developer debug the issue:
Empty class for factory of service repository.user and no factory service specified
Commits
-------
0999326 better error message if factory class is empty
This PR was merged into the 3.1-dev branch.
Discussion
----------
fix#17993 - Deprecated callable strings
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | no
| Fixed tickets | #17993
| License | MIT
| Doc PR |
Is this ok ?
- [x] Rebase when #18057 is merged
Commits
-------
191b495fix#17993 - Deprecated callable strings
This PR was merged into the 2.3 branch.
Discussion
----------
[Routing] add query param if value is different from default
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | yes
| BC breaks? | most likely not
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | #10940, #18111, #18035
| License | MIT
| Doc PR | -
Commits
-------
1ef2edf [Routing] add query param if value is different from default
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Add DoctrineProvider, for using PSR-6 pools in Doctrine Cache
| 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 would allow cache pool configuration as usual (see #17290) before injecting the resulting doctrine cache provider anywhere such an interface is required.
Commits
-------
5d256dd [Cache] Add DoctrineProvider, for using PSR-6 pools in Doctrine Cache
This PR was merged into the 2.8 branch.
Discussion
----------
Replace iconv_*() uses by mb_*(), add mbstring polyfill when required
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18539
| License | MIT
| Doc PR | -
Looks like `iconv_*()` functions can be really slow (see #18539).
Commits
-------
27f5f81 Replace iconv_*() uses by mb_*(), add mbstring polyfill when required
* 2.8:
[Console] use ANSI escape sequences in ProgressBar overwrite method
[HttpKernel] Fix wrong number of arguments in call of ExceptionListener::logException()
[DependencyInjection] Remove YAML check in CrossCheckTest
[Process] Consistently use getProcess() in tests
[LDAP] Free the search result after a search to free memory
[DependencyInjection] fix phpDoc
* 2.7:
[Console] use ANSI escape sequences in ProgressBar overwrite method
[HttpKernel] Fix wrong number of arguments in call of ExceptionListener::logException()
[DependencyInjection] Remove YAML check in CrossCheckTest
[Process] Consistently use getProcess() in tests
[DependencyInjection] fix phpDoc
This PR was squashed before being merged into the 2.7 branch (closes#18496).
Discussion
----------
[Console] use ANSI escape sequences in ProgressBar overwrite method
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | maybe
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #16957
| License | MIT
| Doc PR |
Rewritten `overwrite` method in ProgressBar class to use ANSI escape sequences to erase lines.
This removes the need to store the last message length as it is not needed to fill the buffer with spaces anymore. As a plus it correctly resets the cursor position while clearing the output
If the output is not decorated the behavior has not been changed.
Could possibly cause a BC break if testing against the decorated emitted output as binary string
Commits
-------
b6cca4c [Console] use ANSI escape sequences in ProgressBar overwrite method
This PR was merged into the 2.8 branch.
Discussion
----------
[LDAP] Free the search result after a search to free memory
| 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 |
Commits
-------
7da4453 [LDAP] Free the search result after a search to free memory
This PR was merged into the 2.7 branch.
Discussion
----------
[Process] Consistently use getProcess() in tests
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
ce13fe7 [Process] Consistently use getProcess() in tests
* 3.0: (24 commits)
[Filesystem] Better error handling in remove()
[DependencyInjection] Add coverage for invalid Expression in exportParameters
[DependencyInjection] Add coverage for all invalid arguments in exportParameters
anonymous services are always private
[Form] FormValidator removed code related to removed option
[Console] Correct time formatting.
[WebProfilerBundle] Fixed error from unset twig variable
Force profiler toolbar svg display
[DependencyInjection] Resolve aliases before removing abstract services + add tests
Fix Dom Crawler select option with empty value
Remove unnecessary option assignment
fix tests (use non-deprecated options)
remove unused variable
mock the proper method
[PropertyAccess] Fix regression
[HttpFoundation] Improve phpdoc
[Logging] Add support for firefox in ChromePhpHandler
Windows 10 version check in just one line
Detect CLI color support for Windows 10 build 10586
[Security] Fixed SwitchUserListener when exiting an impersonication with AnonymousToken
...
* 2.8: (23 commits)
[Filesystem] Better error handling in remove()
[DependencyInjection] Add coverage for invalid Expression in exportParameters
[DependencyInjection] Add coverage for all invalid arguments in exportParameters
anonymous services are always private
[Console] Correct time formatting.
[WebProfilerBundle] Fixed error from unset twig variable
Force profiler toolbar svg display
[DependencyInjection] Resolve aliases before removing abstract services + add tests
Fix Dom Crawler select option with empty value
Remove unnecessary option assignment
fix tests (use non-deprecated options)
remove unused variable
mock the proper method
[PropertyAccess] Fix regression
[HttpFoundation] Improve phpdoc
[Logging] Add support for firefox in ChromePhpHandler
Windows 10 version check in just one line
Detect CLI color support for Windows 10 build 10586
[Security] Fixed SwitchUserListener when exiting an impersonication with AnonymousToken
[EventDispatcher] Try first if the event is Stopped
...
This PR was merged into the 2.7 branch.
Discussion
----------
[DependencyInjection] Add coverage for invalid Expression in exportParameters
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
Commits
-------
1931b14 [DependencyInjection] Add coverage for invalid Expression in exportParameters
This PR was merged into the 2.3 branch.
Discussion
----------
[DependencyInjection] Add coverage for all invalid arguments in exportParameters
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
Commits
-------
87c4f23 [DependencyInjection] Add coverage for all invalid arguments in exportParameters
fixes#14712 and #17789.
`ChoiceType` now always use `ChoiceToValueTransformer` or
`ChoicesToValuesTransformer` depending on `multiple` option.
Hence `CheckboxListMapper` and `RadioListMapper` don’t handle
the transformation anymore.
Fixes pre selection of choice with model values such as `null`,
`false` or empty string.
This PR was merged into the 3.1-dev branch.
Discussion
----------
[FrameworkBundle] integrate the Cache component
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17537
| License | MIT
| Doc PR | -
Last commit is the diff with #17868.
Commits
-------
4152634 [FrameworkBundle] Add default pool & system adapter
714b916 [FrameworkBundle] Add & use Psr6CacheClearer
4740c5c [FrameworkBundle] use abstract cache.pool decoration and aliases
92b1a20 [FrameworkBundle] Fix and add tests for cache pool wiring
e44bfdc [FrameworkBundle] Add cache-pool tag and wiring
281eafa [FrameworkBundle] Integrate the Cache component
bc51fde [Cache] Normalize constructor arguments order
This PR was merged into the 3.1-dev branch.
Discussion
----------
Add the kernel.controller_arguments event
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18362
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/6434
I'm not sure this can be integrated in 3.1 due to the feature freeze, but it would be great if it is, as it is a must-have to be able to make the ``@Security`` annotation compatible with the new argument resolver system (as we need to be able to run the security assertion after the resolving).
I made the arguments mutable here for consistency with ``kernel.controller`` (and @fabpot replied LGTM in the RFC when I suggested it).
Commits
-------
af02e2a Add the kernel.controller_arguments event
This PR was squashed before being merged into the 2.7 branch (closes#18429).
Discussion
----------
[Console] Correct time formatting.
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18420
| License | MIT
| Doc PR |
The previous behavior caused dramatic jumps in the reported time instead of smoothly transitioning between time ranges.
Added tests around the new behavior and the transitions between seconds, minutes, and days.
Commits
-------
b264b66 [Console] Correct time formatting.
This PR was merged into the 2.3 branch.
Discussion
----------
[DomCrawler] Fix select option with empty value
| Q | A
| ------------- | ---
| Branch? | 2.3+
| 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 using the Laravel's testing suite which makes use of the Symfony DOM Crawler (v3.0.2). I have been populating a form with a select which has a value which can be an empty value.
For example, with this select you can choose your gender or leave it empty if you don't want to specify:
```html
<select name="gender">
<option selected></option>
<option>Female</option>
<option>Male</option>
</select>
```
When the `DomCrawler\Field::getValue()` is called I was expect to get the value `''` however I was actually getting `'on'`. This is caused by the [DomCrawler\Field::buildOptionValue()](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/DomCrawler/Field/ChoiceFormField.php#L262-L271) sets the default value to 'on' when there is no value which makes sense for ratios and checkboxes but not for select.
I have tracked this bug back to v2.3 but it is still present in v3, however, the default value was changed from '1' to 'on' in v2.5 which means that this patch will conflict when merging up the maintained versions.
Commits
-------
58276a2 Fix Dom Crawler select option with empty value
This PR was merged into the 2.3 branch.
Discussion
----------
[Form] Remove unnecessary option assignment
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Option assignment is not required because the prototype inherits this option from the parent form via standard inheritance mechanism.
Related pull requests: #16959, #18317
Commits
-------
da8a197 Remove unnecessary option assignment
* reference form type by its FQCN instead of its string name
* use the `entry_type` and `entry_options` options instead of the
deprecated `type` and `options` options
* 2.7:
[HttpFoundation] Improve phpdoc
[Logging] Add support for firefox in ChromePhpHandler
Windows 10 version check in just one line
Detect CLI color support for Windows 10 build 10586
[Security] Fixed SwitchUserListener when exiting an impersonication with AnonymousToken
[EventDispatcher] Try first if the event is Stopped
[FrameworkBundle] fixes grammar in container:debug command manual.
[Form] fix "prototype" not required when parent form is not required
* 2.3:
[HttpFoundation] Improve phpdoc
[Logging] Add support for firefox in ChromePhpHandler
[Security] Fixed SwitchUserListener when exiting an impersonication with AnonymousToken
[Form] fix "prototype" not required when parent form is not required
This PR was merged into the 2.3 branch.
Discussion
----------
[Security] Fixed SwitchUserListener when exiting an impersonation with AnonymousToken
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
If you configure a firewall with switch user with `role: IS_AUTHENTICATED_ANONYMOUSLY` it's impossible to exit the
impersonation because the next line `$this->provider->refreshUser($original->getUser())` will fail. It fails because `RefreshUser`
expects an instance of `UserInterface` and here it's a string.
Therefore, it does not make sense to refresh an Anonymous Token, right ?
Commits
-------
59fea72 [Security] Fixed SwitchUserListener when exiting an impersonication with AnonymousToken
This PR was merged into the 2.3 branch.
Discussion
----------
[Form] fix "prototype" not required when parent form is not required
| Q | A
| ------------- | ---
| Branch? | 2.3+
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18311
| License | MIT
| Doc PR | ~
Commits
-------
7df9ca2 [Form] fix "prototype" not required when parent form is not required
Improve the phpdoc for the `$default` parameter of the `get()` method. It wasn't clear when the default value would be used (whether the key would not exist or the value was `null` or nullish).
The comment is now in sync with `Symfony\Component\HttpFoundation\ParameterBag::get()`.
* 2.3:
Detect CLI color support for Windows 10 build 10586
[EventDispatcher] Try first if the event is Stopped
[FrameworkBundle] fixes grammar in container:debug command manual.
Conflicts:
src/Symfony/Component/EventDispatcher/EventDispatcher.php
src/Symfony/Component/HttpKernel/Debug/TraceableEventDispatcher.php
If you configure a firewall with switch user with `role: IS_AUTHENTICATED_ANONYMOUSLY` it's impossible to exit the
impersonation because the next line `$this->provider->refreshUser($original->getUser())` will fail. It fails because `RefreshUser`
expects an instance of `UserInterface` and here it's a string.
Therefore, it does not make sense to refresh an Anonymous Token, right ?
This PR was merged into the 3.1-dev branch.
Discussion
----------
Added an ArgumentResolver with clean extension point
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | #17933 (pre-work), #1547, #10710
| License | MIT
| Doc PR | symfony/symfony-docs#6422
**This PR is a follow up for and blocked by: #18187**, relates to #11457 by @WouterJ. When reviewing, please take the last commit: [Added an ArgumentResolver with clean extension point](4c092b31f9)
This PR provides:
- The ability to tag your own `ArgumentValueResolverInterface`. This means that you can effectively expand on the argument resolving in the `HttpKernel` without having to implement your own `ArgumentResolver`.
- The possibility to cache away argument metadata via a new `ArgumentMetadataFactory` which simply fetches the data from the cache, effectively omitting 1 reflection call per request. *Not implemented in this PR, but possible once this is merged.*
- The possibility to add a PSR-7 adapter to resolve the correct request, avoids the paramconverters
- The possibility to add a value resolver to fetch stuff from $request->query
- Drupal could simplify [their argument resolving](https://github.com/drupal/drupal/blob/8.1.x/core/lib/Drupal/Core/Controller/ControllerResolver.php) by a lot
- etc.
The aim for this PR is to provide a 100% BC variant to add argument resolving in a clean way, this is shown by the 2 tests: `LegacyArgumentResolverTest` and `ArgumentResolverTest`.
/cc @dawehner @larowlan if you have time, can you check the impact for Drupal? I think this should be a very simple change which should make it more maintainable.
Commits
-------
1bf80c9 Improved DX for the ArgumentResolver
f29bf4c Refactor ArgumentResolverTest
cee5106 cs fixes
cfcf764 Added an ArgumentResolver with clean extension point
360fc5f Extracting arg resolving from ControllerResolver
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Process] Implement IteratorAggregate to stream output
| 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#6424
Sibling to #18386 for iterating of the output streams.
Commits
-------
5947f5d [Process] Implement IteratorAggregate to stream output
This PR was squashed before being merged into the 3.1-dev branch (closes#18144).
Discussion
----------
[DI] Only rebuild autowiring cache when actually needed
| 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 | n/a
With autowiring, the container is currently rebuilt when an autowired class is modified in any way. That makes it unusable for large systems. However, this doesn't need to be true: we only need to rebuild the cache if a construct argument changes. This adds that change, and it's quite simple
This idea can/should also be adapted easily to the `@Route` cache (I don't believe it has something "smart" like this).
Thanks!
Commits
-------
3e97626 [DI] Only rebuild autowiring cache when actually needed
* 3.0:
[travis] Disable hirak/prestissimo for deps=low/high tests
Fixed the "hover" state of the profiler sidebar menu
[HttpFoundation] fix phpdoc of UploadedFile
Lower complexity of Form:isValid()
skipped dns-sensitive tests when DnsMock is not found
fixed typo
[FrameworkBundle] Return the invokable service if its name is the class name
[ci] Skip dns-sensitive tests when DnsMock is not found
Exclude Bridge\PhpUnit from composer.json by default
fixed CS
Optimize ReplaceAliasByActualDefinitionPass
[Process] use __METHOD__ where applicable
[Routing] Don't needlessly execute strtr's as they are fairly expensive
Conflicts:
.travis.yml
* 2.8:
[travis] Disable hirak/prestissimo for deps=low/high tests
Fixed the "hover" state of the profiler sidebar menu
[HttpFoundation] fix phpdoc of UploadedFile
Lower complexity of Form:isValid()
skipped dns-sensitive tests when DnsMock is not found
[FrameworkBundle] Return the invokable service if its name is the class name
[ci] Skip dns-sensitive tests when DnsMock is not found
Exclude Bridge\PhpUnit from composer.json by default
fixed CS
Optimize ReplaceAliasByActualDefinitionPass
[Process] use __METHOD__ where applicable
[Routing] Don't needlessly execute strtr's as they are fairly expensive
Conflicts:
.travis.yml
src/Symfony/Component/DependencyInjection/Compiler/ReplaceAliasByActualDefinitionPass.php
* 2.7:
[travis] Disable hirak/prestissimo for deps=low/high tests
[HttpFoundation] fix phpdoc of UploadedFile
Lower complexity of Form:isValid()
skipped dns-sensitive tests when DnsMock is not found
[FrameworkBundle] Return the invokable service if its name is the class name
[ci] Skip dns-sensitive tests when DnsMock is not found
Exclude Bridge\PhpUnit from composer.json by default
fixed CS
Optimize ReplaceAliasByActualDefinitionPass
[Process] use __METHOD__ where applicable
[Routing] Don't needlessly execute strtr's as they are fairly expensive
* 2.3:
[travis] Disable hirak/prestissimo for deps=low/high tests
[HttpFoundation] fix phpdoc of UploadedFile
[ci] Skip dns-sensitive tests when DnsMock is not found
Optimize ReplaceAliasByActualDefinitionPass
[Process] use __METHOD__ where applicable
Conflicts:
.travis.yml
src/Symfony/Component/DependencyInjection/Compiler/ReplaceAliasByActualDefinitionPass.php
src/Symfony/Component/Process/Process.php
src/Symfony/Component/Process/ProcessBuilder.php
This PR was merged into the 3.0 branch.
Discussion
----------
fixed typo
| Q | A
| ------------- | ---
| Branch? | 3.0
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
As of Symfony 3.0, we only get the _format from the request attributes. Before, we also looked at the request query string, ... This PR fixes the phpdoc for Symfony 3.x.
Commits
-------
78830a1 fixed typo
This PR was squashed before being merged into the 3.1-dev branch (closes#18167).
Discussion
----------
[DependencyInjection] Fix a limitation of the PhpDumper
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/17801
| License | MIT
| Doc PR |
The ``PhpDumper`` cannot currently dump several services' id containing characters unsupported by php.
This PR tries to solve this issue by removing the unsupported characters and by sufixing their camelized association to avoid conflicts.
Commits
-------
0d147b2 [DependencyInjection] Fix a limitation of the PhpDumper
This PR was merged into the 3.1-dev branch.
Discussion
----------
[DX] [LDAP] Added default service name for the Security component's Ldap providers
| 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 PR adds a default service name (`ldap`) for the Security component's Ldap factories (`LdapFactory`, `FormLoginLdapFactory` and `HttpBasicLdapFactory`.
Commits
-------
29e3d38 Added default service name for the Security component's Ldap providers
This PR was merged into the 2.7 branch.
Discussion
----------
skipped dns-sensitive tests when DnsMock is not found (2.7)
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18319
| License | MIT
| Doc PR | -
Commits
-------
efc1de7 skipped dns-sensitive tests when DnsMock is not found
This PR was squashed before being merged into the 3.1-dev branch (closes#18036).
Discussion
----------
[Serializer] XmlEncoder: Make load flags configurable
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17987
| License | MIT
| Doc PR | todo
Commits
-------
0826068 [Serializer] XmlEncoder: Make load flags configurable
This PR was merged into the 2.7 branch.
Discussion
----------
[Routing] Don't needlessly execute strtr's as they are fairly expensive
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | refactor
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | see discussion in #18230
| License | MIT
| Doc PR | see #18230
As requested in #18230 this is a new version of the prevention of using strtr's. I've posted some performance-numbers in that PR as well.
Commits
-------
b3da6a1 [Routing] Don't needlessly execute strtr's as they are fairly expensive
This PR was merged into the 2.3 branch.
Discussion
----------
Optimize ReplaceAliasByActualDefinitionPass
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes (performance)
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Previous implementation passed over every definition for every alias (n*m runtime).
New implementation passes once over all aliases and once over all definitions (n+m).
Also removing needless "restart" logic.
Commits
-------
ab8dc0c Optimize ReplaceAliasByActualDefinitionPass
This PR was merged into the 3.1-dev branch.
Discussion
----------
[3.1] [WebProfilerBundle] [DX] Feature allow forward and redirection detection in wdt
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #14358, #17501
| License | MIT
| Doc PR | ?
This PR allows to :
- track explicit forward from `\Symfony\Bundle\FrameWorkBundle\Controller\Controller` in the web debug toolbar.
- or pass a request attribute `_forwarded` with the current request attributes (an instance of `ParameterBag`) as value to your sub request before handling it.
- see if you've been redirected (require session enabled)
When redirected you will see the name of the route (if any) and a link to the profile of the original request.
![redirect](https://cloud.githubusercontent.com/assets/10107633/12716952/9aacdcba-c8e4-11e5-9a64-d26fe27f1cae.jpg)
In case of forwarding, the name of the controller is a file link and next to it there is a direct link to the profile of the sub request.
![forward](https://cloud.githubusercontent.com/assets/10107633/12716968/ba6b1fbc-c8e4-11e5-85fc-7f71969cb372.jpg)
This works pretty well in __Silex__ too by registering `SessionServiceProvider()` for redirections or by providing this method for forwarding :
```php
class App extends \Silex\Application
// (php7 bootstrap) $app = new class extends \Silex\Application {
{
public function forward($controller, array $path = array(), array $query = array()
{
if (!$this->booted) {
throw new LogicException(sprintf('Method %s must be called from a controller.', __METHOD__));
}
$this->flush();
$request = $this['request_stack']->getCurrentRequest();
$path['_forwarded'] = $request->attributes;
$path['_controller'] = $controller;
$subRequest = $request->duplicate($query, null, $path);
return $this['kernel']->handle($subRequest, HttpKernelInterface::SUB_REQUEST);
}
}
```
Commits
-------
0a0e8af [WebProfilerBundle] show the http method in wdt if not 'GET'
4f020b5 [FrameworkBundle] Extends the RequestDataCollector
227ac77 [WebProfilerBundle] [FrameworkBundle] profile forward controller action
0a1b284 [WebProfiler] [HttpKernel] profile redirections
Previous implementation passed over every alias and every definition, for every
alias (n*(n+m) runtime). New implementation passes once over all aliases and
once over all definitions (n+m).
Also removing needless "restart" logic --- it has no real effect in either case.
This PR was merged into the 3.1-dev branch.
Discussion
----------
Add Inflector component (from StringUtil of PropertyAccess)
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | no
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
As proposed by @dunglas here: https://github.com/symfony/symfony/issues/18166#issuecomment-196707518
This will help us fix#18166
Commits
-------
8abebf6 Add Inflector component (from StringUtil of PropertyAccess)
* 3.0:
[Process] Fix stream_select priority when writing to stdin
bumped Symfony version to 3.0.5
updated VERSION for 3.0.4
updated CHANGELOG for 3.0.4
[Form] NumberToLocalizedStringTransformer should return floats when possible
[Form] remove useless code in ChoiceType
[DependencyInjection] Enabled alias for service_container
Conflicts:
src/Symfony/Component/HttpKernel/Kernel.php
src/Symfony/Component/Process/Pipes/AbstractPipes.php
* 2.8:
[Process] Fix stream_select priority when writing to stdin
[Form] NumberToLocalizedStringTransformer should return floats when possible
[Form] remove useless code in ChoiceType
[DependencyInjection] Enabled alias for service_container
Conflicts:
src/Symfony/Component/DependencyInjection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php
src/Symfony/Component/Form/Extension/Core/Type/ChoiceType.php
* 2.7:
[Process] Fix stream_select priority when writing to stdin
[Form] NumberToLocalizedStringTransformer should return floats when possible
[Form] remove useless code in ChoiceType
[DependencyInjection] Enabled alias for service_container
Conflicts:
src/Symfony/Component/Form/Extension/Core/DataTransformer/NumberToLocalizedStringTransformer.php
* 2.3:
[Form] NumberToLocalizedStringTransformer should return floats when possible
[DependencyInjection] Enabled alias for service_container
Conflicts:
src/Symfony/Component/DependencyInjection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php
This PR was merged into the 3.1-dev branch.
Discussion
----------
Add strict image validation
| Q | A
| ------------- | ---
| Bug fix? | yes (current validator does not validates corrupted images)
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | not, but fail looks like not relates to this PR
| Fixed tickets | -
| License | MIT
| Doc PR | -
getimagesize returns correct size for corrupted images, so I've added another check
Commits
-------
7b6a96e Add corrupted images validation
This PR was squashed before being merged into the 3.1-dev branch (closes#18135).
Discussion
----------
[Security] Deprecate onAuthenticationSuccess()
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | #18027
| License | MIT
| Doc PR | not yet - the existing feature is not currently documented
Because of the new `TargetPathTrait`, implementing `onAuthenticationSuccess` yourself is quite easy. I think we should just remove it. This also will fix#18027.
Thanks!
Commits
-------
c4ae80a [Security] Deprecate onAuthenticationSuccess()
closes#14358
The `Symfony\Bundle\FrameworkBundle\Controller\Controller::forward()`
now passes request attributes to its sub request, so when the profiler
will profile the sub request it will add its token to its hold by
reference parent request attributes.
The profiler main profiler layout displays a shortcut to the forwarded
sub request profile which is actually responsible for returning the
present response.
The web debug toolbar shows a notifying icon, meaning a shortcut to a
forwarded profile is available in the toolbar request panel.
closes#17501.
The profiler stores the current request attributes in a
current session when a `RedirectionResponse` is returned.
So the next request profile will inherit the previous request
attributes.
The main profiler layout displays a shortcut to a previous
redirection profile, along with some useful informations.
The web debug toolbar shows a notifying icon, meaning a shortcut
to a redirection profile is available in the request toolbar panel.
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Yaml] dump non UTF-8 encoded strings as binary data
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | #18241
| License | MIT
| Doc PR |
Commits
-------
86e4a6f dump non UTF-8 encoded strings as binary data
This PR was merged into the 2.3 branch.
Discussion
----------
[Form] NumberToLocalizedStringTransformer should return floats when possible
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18346
| License | MIT
| Doc PR | -
Commits
-------
f5ed09c [Form] NumberToLocalizedStringTransformer should return floats when possible
This PR was merged into the 2.3 branch.
Discussion
----------
[DependencyInjection] Enable alias for service_container
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Commits
-------
6161438 [DependencyInjection] Enabled alias for service_container
* 3.0:
[ci] Get ICU/intl from github instead of nebm.ist.utl.pt/~glopes
[Debug] Fix case sensitivity checks
[Debug] Fix handling of php7 throwables
fix high deps tests
fix testing deprecation messages
[Process] remove dead code
[WebProfilerBundle] Add missing use statement.
[ClassLoader] Fix storing not-found classes in APC cache
[Form] cs fixes in date types
[phpunit] disable prophecy
* 2.8:
[ci] Get ICU/intl from github instead of nebm.ist.utl.pt/~glopes
[Debug] Fix case sensitivity checks
[Debug] Fix handling of php7 throwables
fix high deps tests
fix testing deprecation messages
[Process] remove dead code
[WebProfilerBundle] Add missing use statement.
[ClassLoader] Fix storing not-found classes in APC cache
[Form] cs fixes in date types
[phpunit] disable prophecy
* 2.7:
[ci] Get ICU/intl from github instead of nebm.ist.utl.pt/~glopes
[Debug] Fix case sensitivity checks
[Debug] Fix handling of php7 throwables
fix high deps tests
[Process] remove dead code
[WebProfilerBundle] Add missing use statement.
[ClassLoader] Fix storing not-found classes in APC cache
[Form] cs fixes in date types
[phpunit] disable prophecy
* 2.3:
[ci] Get ICU/intl from github instead of nebm.ist.utl.pt/~glopes
[Debug] Fix handling of php7 throwables
[Process] remove dead code
[ClassLoader] Fix storing not-found classes in APC cache
[Form] cs fixes in date types
This PR was merged into the 2.3 branch.
Discussion
----------
[Debug] Fix handling of php7 throwables
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18269
| License | MIT
| Doc PR | -
Should not be merged into 2.7 because 2.7 already has the required logic.
Commits
-------
b032096 [Debug] Fix handling of php7 throwables
closes#5906.
The submitted data should always be
transformed back to the model as a string
as NULL in this case could stand for "unset
this value" whereas a string property of a
class could rely on the string type.
Furthermore, this prevents potential issues
with PHP 7 which allows type hinting of
strings in functions.
This PR was merged into the 2.3 branch.
Discussion
----------
[Form] cs fixes in date types
| Q | A
| ------------- | ---
| Branch? | 2.3+
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | n/a
| License | MIT
| Doc PR | ~
Commits
-------
bc21828 [Form] cs fixes in date types
* 3.0:
bumped Symfony version to 2.8.5
updated VERSION for 2.8.4
updated CHANGELOG for 2.8.4
Revert "bug #18275 [Form] Fix BC break introduced in #14403 (HeahDude)"
improved comment
[FileSystem] Add support for Google App Engine.
[2.8] fix mocks
bumped Symfony version to 2.7.12
[Form] Fix BC break introduced in #14403
updated VERSION for 2.7.11
updated CHANGELOG for 2.7.11
[Request] Fix support of custom mime types with parameters
fix mocks
fix mocks
[Validator] do not treat payload as callback
* 2.8:
bumped Symfony version to 2.8.5
updated VERSION for 2.8.4
updated CHANGELOG for 2.8.4
bumped Symfony version to 2.7.12
updated VERSION for 2.7.11
updated CHANGELOG for 2.7.11
[Request] Fix support of custom mime types with parameters
fix mocks
fix mocks
[Validator] do not treat payload as callback
* 2.7:
bumped Symfony version to 2.7.12
updated VERSION for 2.7.11
updated CHANGELOG for 2.7.11
[Request] Fix support of custom mime types with parameters
fix mocks
fix mocks
[Validator] do not treat payload as callback
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Add a Chain adapter
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | #17556
| License | MIT
| Doc PR | -
Made in coordination with @dunglas
Commits
-------
68d9cea [Cache] Optimize Chain adapter
ebdcd16 [Cache] Add a Chain adapter
This PR was merged into the 2.7 branch.
Discussion
----------
[Validator] do not treat payload as callback
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
see http://stackoverflow.com/a/36140305/2289865
Commits
-------
2066fc0 [Validator] do not treat payload as callback
`ChoiceListFactoryInterface` expected `$group_by` to be a callable or
null not an array.
The factory defaults `group_by` to
`ChoiceListInterface::getStructuredValues`.
This PR was merged into the 2.3 branch.
Discussion
----------
[HttpFoundation] Fix support of custom mime types with parameters
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/FriendsOfSymfony/FOSRestBundle/issues/1399
| License | MIT
When using mime types with parameters, ``getFormat`` won't return the expected format as illustrated:
```php
$request = new Request();
$request->setFormat('custom', 'app/foo;param=bar');
$request->getFormat('app/foo;param=bar');
// will return null as the parameters are removed
```
So my proposal is to search the format corresponding to a mime type with its raw value or with the its parameters removed.
Commits
-------
f7ad285 [Request] Fix support of custom mime types with parameters
* check for existance of `setMetadataFactory()` method (this is needed
for tests run with deps=high as the method was removed in Symfony
3.0)
* fix mock testing the `EngineInterface` as the `stream()` method cannot
be mocked when it is does not exist in the mocked interface
This PR was merged into the 3.1-dev branch.
Discussion
----------
Make Request::isFromTrustedProxy() public.
| 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 adding custom headers to your proxy (in our particular case, a `X-Base-Url` header, but it could be anything), it is necessary to be able to tell whether the request came from a trusted proxy or not. Unfortunately, currently the `isFromTrustedProxy()` method is private, which means you'll need to subclass `Request` and add your own *differently named* method just to be able to access this information.
This functionality is pretty straightforward, and I don't see a reason to keep this method private so this a trivial pull request to make it public (and it adds a comment so it'll show up in the API docs with proper documentation).
Commits
-------
286f64f Make Request::isFromTrustedProxy() public.
This PR was merged into the 2.8 branch.
Discussion
----------
[Form] Fix `Forms` docblock to use FQCN
| 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 | -
Commits
-------
df61aab [Form] Fix `Forms` docblock to use FQCN
This PR was squashed before being merged into the 3.1-dev branch (closes#18248).
Discussion
----------
Fast multiple setEx with the pipeline transcation (RedisAdapter::doSave)
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
e132763 Fast multiple setEx with the pipeline transcation (RedisAdapter::doSave)
This PR was squashed before being merged into the 3.1-dev branch (closes#18211).
Discussion
----------
[Security] Use auth trust resolver to determine anonymous in ContextListener
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | not done yet
There is a nice class in Symfony that is used to check whether a token is anonymously: `AuthenticationTrustResolver`. However, its logic was still hard coded in the `ContextListener`, making it impossible to customize it (e.g. using another anonymous token class). I think it makes lots of sense to use the dedicated class.
Commits
-------
ab5578e [Security] Use auth trust resolver to determine anonymous in ContextListener
* 3.0: (22 commits)
Fix backport
[travis] Upgrade phpunit wrapper & hirak/prestissimo
[Bridge\PhpUnit] Workaround old phpunit bug, no colors in weak mode, add tests
[PropertyAccess] Fix isPropertyWritable not using the reflection cache
[PropertyAccess] Backport fixes from 2.7
[FrameworkBundle][2.8] Add tests for the Controller class
[DependencyInjection] Update changelog
Added WebProfiler toolbar ajax panel table layout css.
[Validator] use correct term for a property in docblock (not "option")
[Routing] small refactoring for scheme requirement
[PropertyAccess] Remove most ref mismatches to improve perf
[PropertyInfo] Support Doctrine custom mapping type in DoctrineExtractor
[Validator] EmailValidator cannot extract hostname if email contains multiple @ symbols
[NumberFormatter] Fix invalid numeric literal on PHP 7
[Process] fix docblock syntax
use the clock mock for progress indicator tests
Use XML_ELEMENT_NODE in nodeType check
[PropertyAccess] Reduce overhead of UnexpectedTypeException tracking
[PropertyAccess] Throw an UnexpectedTypeException when the type do not match
[FrameworkBundle] Add tests for the Controller class
...
Conflicts:
src/Symfony/Bridge/PhpUnit/SymfonyTestsListener.php
src/Symfony/Bundle/FrameworkBundle/Tests/Controller/ControllerTest.php
src/Symfony/Bundle/FrameworkBundle/composer.json
src/Symfony/Component/PropertyAccess/PropertyAccessor.php
src/Symfony/Component/PropertyAccess/PropertyAccessorInterface.php
src/Symfony/Component/PropertyAccess/Tests/PropertyAccessorTest.php
* 2.8: (22 commits)
Fix backport
[travis] Upgrade phpunit wrapper & hirak/prestissimo
[Bridge\PhpUnit] Workaround old phpunit bug, no colors in weak mode, add tests
[PropertyAccess] Fix isPropertyWritable not using the reflection cache
[PropertyAccess] Backport fixes from 2.7
[FrameworkBundle][2.8] Add tests for the Controller class
[DependencyInjection] Update changelog
Added WebProfiler toolbar ajax panel table layout css.
[Validator] use correct term for a property in docblock (not "option")
[Routing] small refactoring for scheme requirement
[PropertyAccess] Remove most ref mismatches to improve perf
[PropertyInfo] Support Doctrine custom mapping type in DoctrineExtractor
[Validator] EmailValidator cannot extract hostname if email contains multiple @ symbols
[NumberFormatter] Fix invalid numeric literal on PHP 7
[Process] fix docblock syntax
use the clock mock for progress indicator tests
Use XML_ELEMENT_NODE in nodeType check
[PropertyAccess] Reduce overhead of UnexpectedTypeException tracking
[PropertyAccess] Throw an UnexpectedTypeException when the type do not match
[FrameworkBundle] Add tests for the Controller class
...
Conflicts:
.travis.yml
composer.json
src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler.php
src/Symfony/Bundle/FrameworkBundle/composer.json
src/Symfony/Component/Intl/NumberFormatter/NumberFormatter.php
* 2.7:
Fix backport
[travis] Upgrade phpunit wrapper & hirak/prestissimo
[Bridge\PhpUnit] Workaround old phpunit bug, no colors in weak mode, add tests
[PropertyAccess] Fix isPropertyWritable not using the reflection cache
[PropertyAccess] Backport fixes from 2.7
[Validator] use correct term for a property in docblock (not "option")
[Routing] small refactoring for scheme requirement
[PropertyAccess] Remove most ref mismatches to improve perf
[Validator] EmailValidator cannot extract hostname if email contains multiple @ symbols
[NumberFormatter] Fix invalid numeric literal on PHP 7
[Process] fix docblock syntax
Use XML_ELEMENT_NODE in nodeType check
[PropertyAccess] Reduce overhead of UnexpectedTypeException tracking
[PropertyAccess] Throw an UnexpectedTypeException when the type do not match
[FrameworkBundle] Add tests for the Controller class
[FrameworkBundle] Add tests for the Controller class
[Process] getIncrementalOutput should work without calling getOutput
Conflicts:
src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler.php
src/Symfony/Bridge/PhpUnit/TextUI/Command.php
src/Symfony/Bundle/FrameworkBundle/Tests/Controller/ControllerTest.php
* 2.3:
[Validator] use correct term for a property in docblock (not "option")
[PropertyAccess] Remove most ref mismatches to improve perf
[Validator] EmailValidator cannot extract hostname if email contains multiple @ symbols
[NumberFormatter] Fix invalid numeric literal on PHP 7
Use XML_ELEMENT_NODE in nodeType check
[PropertyAccess] Reduce overhead of UnexpectedTypeException tracking
[PropertyAccess] Throw an UnexpectedTypeException when the type do not match
[FrameworkBundle] Add tests for the Controller class
Conflicts:
src/Symfony/Bundle/FrameworkBundle/Tests/Controller/ControllerTest.php
src/Symfony/Component/Intl/NumberFormatter/NumberFormatter.php
src/Symfony/Component/PropertyAccess/PropertyAccessor.php
src/Symfony/Component/PropertyAccess/PropertyAccessorInterface.php
src/Symfony/Component/PropertyAccess/PropertyPath.php
src/Symfony/Component/PropertyAccess/Tests/PropertyAccessorTest.php
src/Symfony/Component/Validator/Constraints/EmailValidator.php
This PR was merged into the 2.3 branch.
Discussion
----------
[PropertyAccess] Remove most ref mismatches to improve perf
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | -
| License | MIT
| Doc PR | -
This PR is for PHP5 where ref mismatches is a perf pain: it removes all ref mismatches along the "getValue" path, and keeps only the required ones on the "setValue" path.
Commits
-------
72940d7 [PropertyAccess] Remove most ref mismatches to improve perf
This PR was merged into the 2.3 branch.
Discussion
----------
[PropertyAccess] Throw an UnexpectedTypeException when the type do not match
| Q | A
| ------------- | ---
| Branch? | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17738, #18032
| License | MIT
| Doc PR | -
Made in coordination with @dunglas,
Diff best viewed [ignoring whitspaces](https://github.com/symfony/symfony/pull/18210/files?w=1).
Quoting #18032:
> it appears that the current implementation is error prone because it throws a `\TypeError` that is an `Error` in PHP 7 but a regular `Exception` in PHP 5 because it uses the Symfony polyfill.
Programs wrote in PHP 5 and catching all exceptions will catch this "custom" `\TypeError ` but not those wrote in PHP 7. It can be very hard to debug.
> In this alternative implementation:
> * catching type mismatch is considered a bug fix and applied to Symfony 2.3
> * for every PHP versions, a domain exception is thrown
Commits
-------
5fe2b06 [PropertyAccess] Reduce overhead of UnexpectedTypeException tracking
10c8d5e [PropertyAccess] Throw an UnexpectedTypeException when the type do not match
This PR was merged into the 2.3 branch.
Discussion
----------
[DomCrawler] Use XML_ELEMENT_NODE in nodeType check
| Q | A
| ------------- | ---
| Branch? | 2.3+
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Making use of the predefined dom constant `XML_ELEMENT_NODE` (which value is `1`) makes more sense while interpreting `parents()` it's functionality. See http://php.net/manual/en/dom.constants.php
Commits
-------
cffea91 Use XML_ELEMENT_NODE in nodeType check
This PR was merged into the 2.7 branch.
Discussion
----------
[Process] getIncrementalOutput should work without calling getOutput
| Q | A
| ------------- | ---
| Branch | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17937
| License | MIT
Commits
-------
37d8695 [Process] getIncrementalOutput should work without calling getOutput
* 3.0:
use the clock mock for progress indicator tests
Removed 3.0 restriction for the Ldap component in the Security component
Conflicts:
phpunit.xml.dist
src/Symfony/Component/Security/Core/composer.json
src/Symfony/Component/Security/composer.json
This PR was merged into the 3.0 branch.
Discussion
----------
Removed 3.0.0 restriction for the Ldap component in the Security component
| Q | A
| ------------- | ---
| Branch? | 3.0
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
This ticket removes the restriction on version 3.0 of the Ldap component, as the component is now both backward and forward-compatible.
This PR is being made against the `3.0` branch and not in the `2.8` branch as it seems that all other dependencies rely on `~2.8|~3.0.0` for the `2.8` branch.
There will be a conflict with the `master` branch. The versions to use on the `master` branch is `~3.1` for both `composer.json` files, as the authentication provider and the user provider rely on the new interface, and the `LdapInterface::query()` method, instead of `LdapClientInterface::search()`, which is deprecated.
Commits
-------
f576c9f Removed 3.0 restriction for the Ldap component in the Security component
* 3.0:
[Validator] Test DNS Url constraints using checkdnsrr() mock
Improved the PHPdoc of FileSystem::copy()
[Validator] Test DNS Email constraints using checkdnsrr() mock
[travis] Run real php subprocesses on hhvm for Process component tests
bug #18161 [Translation] Add support for fuzzy tags in PoFileLoader
[Form] Fix NumberToLocalizedStringTransformer::reverseTransform with big integers
[Form] Fix INT64 cast to float in IntegerType.
[SecurityBundle][PHPDoc] Added method doumentation for SecurityFactoryInterface
FrameworkBundle: Client: getContainer(): fixed phpdoc
[Validator] Updating inaccurate docblock comment
Conflicts:
phpunit.xml.dist
* 2.8:
[Validator] Test DNS Url constraints using checkdnsrr() mock
Improved the PHPdoc of FileSystem::copy()
[Validator] Test DNS Email constraints using checkdnsrr() mock
[travis] Run real php subprocesses on hhvm for Process component tests
bug #18161 [Translation] Add support for fuzzy tags in PoFileLoader
[Form] Fix NumberToLocalizedStringTransformer::reverseTransform with big integers
[Form] Fix INT64 cast to float in IntegerType.
[SecurityBundle][PHPDoc] Added method doumentation for SecurityFactoryInterface
FrameworkBundle: Client: getContainer(): fixed phpdoc
[Validator] Updating inaccurate docblock comment
Conflicts:
.travis.yml
* 2.7:
[Validator] Test DNS Url constraints using checkdnsrr() mock
Improved the PHPdoc of FileSystem::copy()
[Validator] Test DNS Email constraints using checkdnsrr() mock
[travis] Run real php subprocesses on hhvm for Process component tests
bug #18161 [Translation] Add support for fuzzy tags in PoFileLoader
[Form] Fix NumberToLocalizedStringTransformer::reverseTransform with big integers
[Form] Fix INT64 cast to float in IntegerType.
[SecurityBundle][PHPDoc] Added method doumentation for SecurityFactoryInterface
FrameworkBundle: Client: getContainer(): fixed phpdoc
[Validator] Updating inaccurate docblock comment
* 2.3:
Improved the PHPdoc of FileSystem::copy()
[Validator] Test DNS Email constraints using checkdnsrr() mock
[travis] Run real php subprocesses on hhvm for Process component tests
bug #18161 [Translation] Add support for fuzzy tags in PoFileLoader
[Form] Fix NumberToLocalizedStringTransformer::reverseTransform with big integers
[Form] Fix INT64 cast to float in IntegerType.
[SecurityBundle][PHPDoc] Added method doumentation for SecurityFactoryInterface
FrameworkBundle: Client: getContainer(): fixed phpdoc
[Validator] Updating inaccurate docblock comment
Conflicts:
.travis.yml
src/Symfony/Component/Validator/Tests/Constraints/EmailValidatorTest.php
This PR was squashed before being merged into the 2.3 branch (closes#18195).
Discussion
----------
Improved the PHPdoc of FileSystem::copy()
| Q | A
| ------------- | ---
| Branch | 2.3+
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #12937
| License | MIT
| Doc PR | -
Commits
-------
9ad67ca Improved the PHPdoc of FileSystem::copy()
This PR was merged into the 2.3 branch.
Discussion
----------
[Validator] Test DNS Email constraints using checkdnsrr() mock
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
165755a [Validator] Test DNS Email constraints using checkdnsrr() mock
* 3.0:
[PhpUnitBridge] Revert 7f62133939
bumped Symfony version to 2.3.40
Fix leftover conflict marker in UPGRADE-3.0.md
set s-maxage only if all responses are cacheable
updated VERSION for 2.3.39
update CONTRIBUTORS for 2.3.39
updated CHANGELOG for 2.3.39
Improved the "branch" row of the PR table
[Debug] Replaced logic for detecting filesystem case sensitivity
[Process] Wait a bit less on Windows
Use debug member variable
Autowiring the concrete class too - consistent with behavior of other services
Fix typos #18090 1. PHPs session design to PHP's session design 2. Symfony HttpKernel offers to Symfony's HttpKernel offers 3. in which case it it should to in which case it should
Fix for Isssue #18091
replace perfom by perform
minor #18088 Fix typo for profiler
[Validator] Fixing inaccurate typehint in docblock
[ci] remove token for composer now that rate limiting is off
* 2.8:
[PhpUnitBridge] Revert 7f62133939
bumped Symfony version to 2.3.40
set s-maxage only if all responses are cacheable
updated VERSION for 2.3.39
update CONTRIBUTORS for 2.3.39
updated CHANGELOG for 2.3.39
Improved the "branch" row of the PR table
[Debug] Replaced logic for detecting filesystem case sensitivity
[Process] Wait a bit less on Windows
Use debug member variable
Autowiring the concrete class too - consistent with behavior of other services
Fix typos #18090 1. PHPs session design to PHP's session design 2. Symfony HttpKernel offers to Symfony's HttpKernel offers 3. in which case it it should to in which case it should
Fix for Isssue #18091
replace perfom by perform
minor #18088 Fix typo for profiler
[Validator] Fixing inaccurate typehint in docblock
[ci] remove token for composer now that rate limiting is off
Conflicts:
CHANGELOG-2.3.md
src/Symfony/Bridge/PhpUnit/composer.json
* 2.7:
[PhpUnitBridge] Revert 7f62133939
bumped Symfony version to 2.3.40
set s-maxage only if all responses are cacheable
updated VERSION for 2.3.39
update CONTRIBUTORS for 2.3.39
updated CHANGELOG for 2.3.39
Improved the "branch" row of the PR table
[Debug] Replaced logic for detecting filesystem case sensitivity
[Process] Wait a bit less on Windows
Use debug member variable
Fix typos #18090 1. PHPs session design to PHP's session design 2. Symfony HttpKernel offers to Symfony's HttpKernel offers 3. in which case it it should to in which case it should
Fix for Isssue #18091
replace perfom by perform
minor #18088 Fix typo for profiler
[ci] remove token for composer now that rate limiting is off
Conflicts:
src/Symfony/Bridge/PhpUnit/composer.json
The traditional gettext tools usually try to find similar strings when
updating translations. This results in some strings having a translation
but being marked as "fuzzy", even if the translation is not correct.
The expected result when a string is marked as fuzzy is that it should
not be used by the translation system. Using symfony, though, the
translations were used, which could result in "funny" messages being
displayed in the interface despite being often completely out of
context.
This commit discards messages in .po files that have a '#, fuzzy' flag.
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | 18161
| License | MIT
| Doc PR | -
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Restrict flushes to namespace scopes
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | -
| License | MIT
| Doc PR | -
Instead of flushing all cache namespaces all the time, we can flush only the keys in the namespace.
Commits
-------
8744443 [Cache] Restrict flushes to namespace scopes
This PR was merged into the 2.3 branch.
Discussion
----------
[Form] Fix NumberToLocalizedStringTransformer::reverseTransform with big integers
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18077, #18067
| License | MIT
| Doc PR | -
Commits
-------
03c008c [Form] Fix NumberToLocalizedStringTransformer::reverseTransform with big integers
6b6073f [Form] Fix INT64 cast to float in IntegerType.
This PR was squashed before being merged into the 3.1-dev branch (closes#18143).
Discussion
----------
[DomCrawler] Exposed getter for baseHref
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #15584
| License | MIT
| Doc PR | n/a
I know that PR for this issue already created, but it is Hack Day, so I'm making my first contribution anyway.
Commits
-------
53935df [DomCrawler] Exposed getter for baseHref
This PR was merged into the 3.1-dev branch.
Discussion
----------
[HttpFoundation] Add support for sending raw cookies in the response
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #13646
| License | MIT
| Doc PR | TODO
Commits
-------
43760a6 [HttpFoundation] Add support for sending raw cookies in the response
This PR was merged into the 2.3 branch.
Discussion
----------
[Validator] Updating inaccurate docblock comment
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
The formatValue() docblock refers to a $prettyDateTime argument, which does not exist. Instead, it should refer to the $format argument.
I'm also adding parentheses around the `$format & self::OBJECT_TO_STRING` expression on line 102 so it is formatted similarly to the `($format & self::PRETTY_DATE)` expression a few lines above it.
Commits
-------
a784743 [Validator] Updating inaccurate docblock comment
* 2.3:
bumped Symfony version to 2.3.40
set s-maxage only if all responses are cacheable
updated VERSION for 2.3.39
update CONTRIBUTORS for 2.3.39
updated CHANGELOG for 2.3.39
Improved the "branch" row of the PR table
Fix typos #18090 1. PHPs session design to PHP's session design 2. Symfony HttpKernel offers to Symfony's HttpKernel offers 3. in which case it it should to in which case it should
Fix for Isssue #18091
replace perfom by perform
minor #18088 Fix typo for profiler
This PR was merged into the 2.3 branch.
Discussion
----------
[HttpKernel] set s-maxage only if all responses are cacheable
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18160
| License | MIT
| Doc PR |
Commits
-------
b7d9338 set s-maxage only if all responses are cacheable
This PR was merged into the 2.7 branch.
Discussion
----------
[Process] Wait a bit less on Windows
| Q | A
| ------------- | ---
| Branch | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
By using `stream_select` instead of `usleep` when the input is at wait, and by not blocking when the process has halted, we can enhance a bit the performance on Windows.
Commits
-------
380a54f [Process] Wait a bit less on Windows
This PR was merged into the 2.3 branch.
Discussion
----------
[Hack Day] Issue for newcomers (2). Replace perfom by perform
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | #18089
| License | MIT
| Doc PR | reference to the documentation PR, if any
Commits
-------
f33f192 replace perfom by perform
This PR was merged into the 2.3 branch.
Discussion
----------
Fix typos #18090
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18090
| License | MIT
| Doc PR |
1. PHPs session design to PHP's session design
2. Symfony HttpKernel offers to Symfony's HttpKernel offers
3. in which case it it should to in which case it should
Commits
-------
6276452 Fix typos #18090 1. PHPs session design to PHP's session design 2. Symfony HttpKernel offers to Symfony's HttpKernel offers 3. in which case it it should to in which case it should
1. PHPs session design to PHP's session design
2. Symfony HttpKernel offers to Symfony's HttpKernel offers
3. in which case it it should to in which case it should
As of Symfony 2.8, constraint errors are now string UUIDs rather than integers. The corresponding docblock typehint in getErrorName() should reflect this change.
* 3.0:
[ci] use hirak/prestissimo
[Filesystem] Fix transient tests
[WebProfiler] Sidebar button padding
Updated some missing READMEs
[HttpFoundation] Avoid warnings when checking malicious IPs
[HttpFoundation] Set the Content-Range header if the requested Range is unsatisfied
* 2.8:
[ci] use hirak/prestissimo
[Filesystem] Fix transient tests
[WebProfiler] Sidebar button padding
Updated some missing READMEs
[HttpFoundation] Avoid warnings when checking malicious IPs
[HttpFoundation] Set the Content-Range header if the requested Range is unsatisfied
Conflicts:
appveyor.yml
src/Symfony/Component/Intl/Tests/DateFormatter/AbstractIntlDateFormatterTest.php
* 2.7:
[ci] use hirak/prestissimo
[Filesystem] Fix transient tests
[HttpFoundation] Avoid warnings when checking malicious IPs
[HttpFoundation] Set the Content-Range header if the requested Range is unsatisfied
Conflicts:
src/Symfony/Component/Intl/Tests/DateFormatter/AbstractIntlDateFormatterTest.php
* 2.3:
[ci] use hirak/prestissimo
[Filesystem] Fix transient tests
[HttpFoundation] Avoid warnings when checking malicious IPs
[HttpFoundation] Set the Content-Range header if the requested Range is unsatisfied
Conflicts:
appveyor.yml
src/Symfony/Component/Filesystem/Tests/FilesystemTest.php
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Hash using B64+MD5 in FilesystemAdapter
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | -
| License | MIT
| Doc PR | -
Using MD5+B64 is good enough to avoid any hash collision, even on case-insensitive filesystems.
On Windows where the total path length is limited, this saves 44 chars worth.
Even if collisions are extremely unlikely, they are detected by adding then comparing the raw key to saved payloads. This also has the added benefit of easing debugging/grepping the cached items on the filesystem.
Commits
-------
e96bb10 [Cache] Hash using B64+MD5 in FilesystemAdapter
This PR was merged into the 3.1-dev branch.
Discussion
----------
Fixing autowiring collision failure
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | yes (bug introduced in master)
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | none
| License | MIT
| Doc PR | n/a
In #17877, I introduced a bug: https://github.com/symfony/symfony/pull/17877/files#diff-62df969ae028c559d33ffd256de1ac49L200.
Namely, if some class cannot be autowired because there is an *odd* number of matching services, then it *would* autowire the last service found, instead of throwing an exception. The tests only tested even numbers, which is how it was missed. This fixes that.
Thanks!
Commits
-------
2aea337 Fixing a bug where an odd number of type collisions would incorrectly autowire (instead of an error)
This PR was merged into the 2.3 branch.
Discussion
----------
[HttpFoundation] Set the Content-Range header if the requested Range is unsatisfied
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This is a followup to https://github.com/symfony/symfony/pull/17150#issuecomment-174509954
[RFC2616](http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html) specifies the Content-Range header SHOULD be included with a *416 Requested Range Not Satisfiable* response:
> When this status code is returned for a byte-range request, the response SHOULD include a Content-Range entity-header field specifying the current length of the selected resource (see section 14.16). This response MUST NOT use the multipart/byteranges content- type.
[RFC 7233](https://tools.ietf.org/html/rfc7233#section-4.2) specifies what should be the header's value. It's in the "Request for comments" state, but it's the best definition I could find. This value is valid according to rfc2616 as well.
Commits
-------
54329d8 [HttpFoundation] Set the Content-Range header if the requested Range is unsatisfied
* 3.0: (28 commits)
[Console] Fix an autocompletion question helper issue with non-sequentially indexed choices
[Process] Fix pipes handling
[Finder] Partially revert #17134 to fix a regression
Mentioned the deprecation of deep parameters in UPGRADE files
[HttpKernel] Fix mem usage when stripping the prod container
[Filesystem] Fix false positive in ->remove()
[Filesystem] Cleanup/sync with 2.3
[Validator] Fix the locale validator so it treats a locale alias as a valid locale
[HttpFoundation] Fix transient test
[HttpFoundation] Add a dependency on the mbstring polyfill
[2.7] update readme files for new components
add readme files where missing
[2.8] update readme files for new components
fix lowest TwigBridge deps versions
reference form type by name on Symfony 2.7
[EventDispatcher] fix syntax error
Don't use reflections when possible
Don't use reflections when possible
[Form] Update form tests after the ICU data update
[Intl] Update tests and the number formatter to match behaviour of the intl extension
...
Conflicts:
src/Symfony/Component/Ldap/README.md
src/Symfony/Component/Security/Core/README.md
src/Symfony/Component/Security/Csrf/README.md
src/Symfony/Component/Security/Http/README.md
* 2.8:
[Finder] Partially revert #17134 to fix a regression
[HttpKernel] Fix mem usage when stripping the prod container
exception when registering bags for started sessions
Conflicts:
src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php
src/Symfony/Component/Validator/composer.json
* 2.7:
[Finder] Partially revert #17134 to fix a regression
[HttpKernel] Fix mem usage when stripping the prod container
exception when registering bags for started sessions
Conflicts:
src/Symfony/Component/Validator/composer.json
* 2.3:
[Finder] Partially revert #17134 to fix a regression
[HttpKernel] Fix mem usage when stripping the prod container
exception when registering bags for started sessions
Conflicts:
src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php
src/Symfony/Component/HttpKernel/Kernel.php
* 2.8: (25 commits)
[Console] Fix an autocompletion question helper issue with non-sequentially indexed choices
[Process] Fix pipes handling
Mentioned the deprecation of deep parameters in UPGRADE files
[Filesystem] Fix false positive in ->remove()
[Filesystem] Cleanup/sync with 2.3
[Validator] Fix the locale validator so it treats a locale alias as a valid locale
[HttpFoundation] Fix transient test
[HttpFoundation] Add a dependency on the mbstring polyfill
[2.7] update readme files for new components
add readme files where missing
[2.8] update readme files for new components
fix lowest TwigBridge deps versions
reference form type by name on Symfony 2.7
[EventDispatcher] fix syntax error
Don't use reflections when possible
Don't use reflections when possible
[Form] Update form tests after the ICU data update
[Intl] Update tests and the number formatter to match behaviour of the intl extension
[Intl] Update the ICU data to version 55
[Intl] Fix the update-data.php script in preparation for ICU 5.5
...
Conflicts:
UPGRADE-2.8.md
UPGRADE-3.0.md
src/Symfony/Bridge/Twig/composer.json
src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Compiler/FragmentRendererPass.php
src/Symfony/Component/Console/Helper/DialogHelper.php
src/Symfony/Component/Console/Helper/ProgressHelper.php
src/Symfony/Component/Console/Tests/Helper/LegacyDialogHelperTest.php
src/Symfony/Component/HttpFoundation/composer.json
src/Symfony/Component/Security/Core/README.md
src/Symfony/Component/Security/Csrf/README.md
src/Symfony/Component/Security/Http/README.md
src/Symfony/Component/Validator/Constraints/LocaleValidator.php
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Add namespace handling to all adapters
| 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 allows more flexible handling of adapters, allowing e.g. to take one cache pool and split in in several sub-pools by using ProxyAdapter.
Commits
-------
5068f87 [Cache] Add namespace handling to all adapters
This PR was merged into the 2.3 branch.
Discussion
----------
[HttpKernel] Fix mem usage when stripping the prod container
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #18007
| License | MIT
| Doc PR | -
I propose to just replace doc comments by regular comments, so that the parser removes them and opcache doesn't have to keep them in memory, which is the target.
Commits
-------
4fa5844 [HttpKernel] Fix mem usage when stripping the prod container
This PR was merged into the 2.3 branch.
Discussion
----------
[HttpFoundation] exception when registering bags for started sessions
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #10707, #16136
| License | MIT
| Doc PR |
Commits
-------
c4a5b67 exception when registering bags for started sessions
* 2.7:
[Filesystem] Fix false positive in ->remove()
[Filesystem] Cleanup/sync with 2.3
[Validator] Fix the locale validator so it treats a locale alias as a valid locale
reference form type by name on Symfony 2.7
* 2.3:
[Filesystem] Fix false positive in ->remove()
[Validator] Fix the locale validator so it treats a locale alias as a valid locale
Conflicts:
src/Symfony/Component/Filesystem/Tests/FilesystemTest.php
src/Symfony/Component/Validator/Constraints/LocaleValidator.php
src/Symfony/Component/Validator/composer.json
* 2.7:
[HttpFoundation] Fix transient test
[HttpFoundation] Add a dependency on the mbstring polyfill
[2.7] update readme files for new components
add readme files where missing
fix lowest TwigBridge deps versions
[EventDispatcher] fix syntax error
Don't use reflections when possible
Don't use reflections when possible
[Form] Update form tests after the ICU data update
[Intl] Update tests and the number formatter to match behaviour of the intl extension
[Intl] Update the ICU data to version 55
[Intl] Fix the update-data.php script in preparation for ICU 5.5
[Process] Fix memory issue when using large input streams
Use constant instead of function call.
fixed test name
automatically generate safe fallback filename
[Console] default to stderr in the console helpers
Conflicts:
composer.json
src/Symfony/Bridge/PhpUnit/README.md
src/Symfony/Bridge/Twig/composer.json
src/Symfony/Component/Console/Helper/DialogHelper.php
src/Symfony/Component/Debug/DebugClassLoader.php
src/Symfony/Component/HttpFoundation/composer.json
src/Symfony/Component/Security/Acl/README.md
src/Symfony/Component/Security/Core/README.md
src/Symfony/Component/Security/Csrf/README.md
src/Symfony/Component/Security/Http/README.md
* 2.3:
[HttpFoundation] Fix transient test
[HttpFoundation] Add a dependency on the mbstring polyfill
add readme files where missing
Don't use reflections when possible
[Form] Update form tests after the ICU data update
[Intl] Update tests and the number formatter to match behaviour of the intl extension
[Intl] Update the ICU data to version 55
[Intl] Fix the update-data.php script in preparation for ICU 5.5
Use constant instead of function call.
fixed test name
automatically generate safe fallback filename
Conflicts:
src/Symfony/Component/Debug/Debug.php
src/Symfony/Component/HttpFoundation/composer.json
src/Symfony/Component/Serializer/Tests/Normalizer/GetSetMethodNormalizerTest.php
This PR was merged into the 2.3 branch.
Discussion
----------
[Intl] Update ICU to version 55
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #14260
| License | MIT
| Doc PR | -
The update script needed to be fixed to work with latest data files from ICU as well.
The only change I needed to do in stubs and tests is related to the way negative numbers are formatted for currencies (a change from `(£100)` to `-£100`).
Form tests needed an update as well, as some date formats have changed.
Commits
-------
fac3de6 [Form] Update form tests after the ICU data update
6822147 [Intl] Update tests and the number formatter to match behaviour of the intl extension
37a9d8c [Intl] Update the ICU data to version 55
894ce3c [Intl] Fix the update-data.php script in preparation for ICU 5.5
This PR was merged into the 2.7 branch.
Discussion
----------
[2.7] Don't use reflection when possible
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
See https://github.com/symfony/symfony/pull/18021
Commits
-------
35be501 Don't use reflections when possible
This PR was merged into the 2.3 branch.
Discussion
----------
Don't use reflections when possible
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Use php functions instead of reflection when possible (to improve a bit the performance).
Commits
-------
a46270a Don't use reflections when possible
This PR was merged into the 2.7 branch.
Discussion
----------
[2.7][Process] Fix memory issue when using large input streams
| Q | A
| ------------- | ---
| Branch | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17667
| License | MIT
This removes buffering of a stream input. Tests shows that this implementation is much faster and fixes some issues when streams are based on very large inputs
Commits
-------
fb8da9f [Process] Fix memory issue when using large input streams
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Cache] Count cache hits/misses in ProxyAdapter
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17537 partially
| License | MIT
| Doc PR | -
I propose to add this subset of the `Doctrine\Common\Cache\Cache` interface so that we can build data collectors on top and show these stats in the web profiler.
ping @javiereguiluz
Commits
-------
e6f21f9 [Cache] Count cache hits/misses in ProxyAdapter
This PR was squashed before being merged into the 2.3 branch (closes#15794).
Discussion
----------
[Console] default to stderr in the console helpers
Interactive input/output and informational output such as progress should go to `stderr` if available.
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
See #13730 also for previous discussion.
If someone explicitly wants to use `stdout`, they can simply pass `$output->getStream()` instead of `$output` in most use-cases.
Commits
-------
3d4e95e [Console] default to stderr in the console helpers
This PR was squashed before being merged into the 3.1-dev branch (closes#18006).
Discussion
----------
[HttpFoundation] Fix BC break introduced by #17642
| Q | A
| ------------- | ---
| Branch | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17642
| License | MIT
| Doc PR | n/a
@taylorotwell can you confirm it fixes the issue with Laravel?
Commits
-------
73ef995 [HttpFoundation] Fix BC break introduced by #17642
* 3.0:
Updated all the README files
[TwigBundle] Fix failing test on appveyor
Improved the error message when using "@" in a decorated service
Improve error reporting in router panel of web profiler
[DoctrineBridge][Form] Fix performance regression in EntityType
[FrameworkBundle] Fix a regression in handling absolute and namespaced template paths
Allow to normalize \Traversable
minor [Form] fix tests added by #16886
Remove _path from query parameters when fragment is a subrequest and request attributes are already set Added tests for _path removal in FragmentListener
Simplified everything
Added a test
Fixed the problem in an easier way
Fixed a syntax issue
Improved the error message when a template is not found
[CodingStandards] Conformed to coding standards
[TwigBundle] fixed Include file locations in "Template could not be found" exception
* 2.8:
Updated all the README files
[TwigBundle] Fix failing test on appveyor
Improved the error message when using "@" in a decorated service
Improve error reporting in router panel of web profiler
[DoctrineBridge][Form] Fix performance regression in EntityType
[FrameworkBundle] Fix a regression in handling absolute and namespaced template paths
Allow to normalize \Traversable
minor [Form] fix tests added by #16886
Remove _path from query parameters when fragment is a subrequest and request attributes are already set Added tests for _path removal in FragmentListener
Simplified everything
Added a test
Fixed the problem in an easier way
Fixed a syntax issue
Improved the error message when a template is not found
[CodingStandards] Conformed to coding standards
[TwigBundle] fixed Include file locations in "Template could not be found" exception
* 2.7:
Updated all the README files
[TwigBundle] Fix failing test on appveyor
Improved the error message when using "@" in a decorated service
Improve error reporting in router panel of web profiler
[DoctrineBridge][Form] Fix performance regression in EntityType
[FrameworkBundle] Fix a regression in handling absolute and namespaced template paths
Allow to normalize \Traversable
minor [Form] fix tests added by #16886
Remove _path from query parameters when fragment is a subrequest and request attributes are already set Added tests for _path removal in FragmentListener
Simplified everything
Added a test
Fixed the problem in an easier way
Fixed a syntax issue
Improved the error message when a template is not found
[CodingStandards] Conformed to coding standards
[TwigBundle] fixed Include file locations in "Template could not be found" exception
* 2.3:
Updated all the README files
[TwigBundle] Fix failing test on appveyor
[FrameworkBundle] Fix a regression in handling absolute and namespaced template paths
Allow to normalize \Traversable
Remove _path from query parameters when fragment is a subrequest and request attributes are already set Added tests for _path removal in FragmentListener
Simplified everything
Added a test
Fixed the problem in an easier way
Fixed a syntax issue
Improved the error message when a template is not found
[CodingStandards] Conformed to coding standards
[TwigBundle] fixed Include file locations in "Template could not be found" exception
This PR was squashed before being merged into the 3.1-dev branch (closes#17887).
Discussion
----------
Show more information in the security profiler
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17856
| License | MIT
| Doc PR | -
This is an early prototype to explore the feature of displaying more information in the security panel. Example:
![profiler_security](https://cloud.githubusercontent.com/assets/73419/13221929/0235fc46-d97e-11e5-981a-249b7148f3a6.png)
Commits
-------
b12152d Show more information in the security profiler
This PR was merged into the 2.3 branch.
Discussion
----------
Allow to normalize \Traversable when serializing xml
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets |
| License | MIT
It's impossible to normalize an object implementing ``\Traversable`` when using the ``XMLEncoder``. For example we can't customize the serializer output when serializing a ``FormInterface`` instance.
So my proposition is to fix this by using the default XML encoder output only when the serializer can't normalize the data.
Commits
-------
97c5d27 Allow to normalize \Traversable
This PR was squashed before being merged into the 2.3 branch (closes#17997).
Discussion
----------
Updated all the README files
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Related to #17995.
Commits
-------
2e81248 Updated all the README files
This PR was merged into the 3.1-dev branch.
Discussion
----------
[FrameworkBundle] [DX] Add `Controller::json` method to make it easy to send json
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Its currently a awkward to use Serializer component to send a `JsonResponse`.
I have tried two approaches
1. use `Serializer::normalize` and `JsonResponse`
1. use `Serializer::serialize` and a plain `Response`, and set the `content-type`
In either cases there is need for a custom `json` function so as not to repeat yourself and there are disadvantages.
1. In the first case you are only partly using `Serializer` and any custom `Encoder` would be skipped
1. In the second you are not making use of `JsonResponse`, particular disadvantage if you want to support JSONP.
This new `json` method uses the serializer component is enabled it is used to generate the json data, and falls back to normal `JsonResponse` when its not.
Commits
-------
f904a2b Add a Controller function to make it easy to return json
This PR was squashed before being merged into the 2.7 branch (closes#17687).
Discussion
----------
Improved the error message when using "@" in a decorated service
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17666
| License | MIT
| Doc PR | -
Commits
-------
e7690ba Improved the error message when using "@" in a decorated service
This PR was squashed before being merged into the 2.7 branch (closes#17744).
Discussion
----------
Improve error reporting in router panel of web profiler
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17342
| License | MIT
| Doc PR | -
### Problem
If you define a route condition like this:
```yaml
app:
resource: '@AppBundle/Controller/'
type: annotation
condition: "request.server.get('HTTP_HOST') matches '/.*\.dev/'"
```
When browsing the Routing panel in the web profiler, you see an exception:
![problem](https://cloud.githubusercontent.com/assets/73419/12930027/553eeb08-cf76-11e5-90b1-ab0de6175d4e.png)
#### Why?
Because the route condition uses the `request` object, but the special `TraceableUrlMatcher` class doesn't get access to the real `request` object but to the special object obtained via:
```php
$request = $profile->getCollector('request');
```
These are the contents of this pseudo-request:
![cause](https://cloud.githubusercontent.com/assets/73419/12930052/804ea248-cf76-11e5-9c38-2e43e1654065.png)
`request.server.get(...)` condition fails because `request.server` is `null`. The full exception message shows this:
![exception](https://cloud.githubusercontent.com/assets/73419/12930079/9c7d6058-cf76-11e5-8eeb-45f5059c824c.png)
### Solution
I propose to catch all exceptions in `TraceableUrlMatcher` and display an error message with some details of the exception:
![error_message](https://cloud.githubusercontent.com/assets/73419/12930106/b29e31d2-cf76-11e5-868c-98d8b0cc4e5b.png)
Commits
-------
1001554 Improve error reporting in router panel of web profiler
This PR was merged into the 2.3 branch.
Discussion
----------
[HttpKernel] Remove _path from query parameters when fragment is a subrequest
| Q | A
| ------------- | ---
| Bug fix? | Yes
| New feature? | No
| BC breaks? | No
| Deprecations? | No
| Tests pass? | Yes
| Fixed tickets |
| License | MIT
| Doc PR |
Prior to 2.3.29, all requests to the ESI fragment path ("/_fragment" by default) would have the "_path" query parameter removed. This held true whether an external proxy (such as Varnish) handled the request as true ESI, or whether the Symfony kernel was mocking ESI behavior and inlining the subrequest.
Once the "_controller" check was added in 2.3.29, the "_path" query parameter was only removed on master requests (such as those coming from an external proxy) and not subrequests, leading to differing behavior in production and development settings.
Commits
-------
c374420 Remove _path from query parameters when fragment is a subrequest and request attributes are already set Added tests for _path removal in FragmentListener
* 3.0:
fixed CS
[DomCrawler] Dont use LIBXML_PARSEHUGE by default
[Filesystem] Reduce complexity of ->remove()
added tests for non-trusted proxies
add 'guid' to list of exception to filter out
Ensure backend slashes for symlinks on Windows systems
[Filesystem] Try to delete broken symlinks
fixed tests
[FrameworkBundle] Test that ObjectNormalizer is registered
* 2.8:
fixed CS
[DomCrawler] Dont use LIBXML_PARSEHUGE by default
[Filesystem] Reduce complexity of ->remove()
added tests for non-trusted proxies
add 'guid' to list of exception to filter out
Ensure backend slashes for symlinks on Windows systems
[Filesystem] Try to delete broken symlinks
fixed tests
[FrameworkBundle] Test that ObjectNormalizer is registered
* 2.7:
fixed CS
[DomCrawler] Dont use LIBXML_PARSEHUGE by default
[Filesystem] Reduce complexity of ->remove()
added tests for non-trusted proxies
add 'guid' to list of exception to filter out
Ensure backend slashes for symlinks on Windows systems
[Filesystem] Try to delete broken symlinks
fixed tests
[FrameworkBundle] Test that ObjectNormalizer is registered
* 2.3:
[DomCrawler] Dont use LIBXML_PARSEHUGE by default
[Filesystem] Reduce complexity of ->remove()
added tests for non-trusted proxies
add 'guid' to list of exception to filter out
Ensure backend slashes for symlinks on Windows systems
[Filesystem] Try to delete broken symlinks
This PR was merged into the 2.3 branch.
Discussion
----------
[DomCrawler] Dont use LIBXML_PARSEHUGE by default
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | #16873, #17956
| License | MIT
| Doc PR | -
Because of http://symfony.com/blog/security-release-symfony-2-0-17-released
Commits
-------
fda32f8 [DomCrawler] Dont use LIBXML_PARSEHUGE by default
This PR was merged into the 2.3 branch.
Discussion
----------
[Filesystem] Reduce complexity of ->remove()
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
065acb7 [Filesystem] Reduce complexity of ->remove()
If you delete the target of a symlink (at least on Windows systems) you
don't get the kind of the target anymore (obviously). Therefore it might
happen that a broken symlink to a directory should be removed with
unlink() which fails. This patch adds another check for a broken symlink
and tries to remove with rmdir() before throwing an exception. It helps
to clean up test folders on Windows systems (so already proofed by the
existing tests).
This PR was squashed before being merged into the 3.1-dev branch (closes#17714).
Discussion
----------
Adding new TargetPathTrait to get/set the authentication "target_path"
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | not yet...
Hi guys!
This is a small guy. Basically, when you're doing custom auth (i.e. a guard authenticator), it's common to need the previous URL the user tried to get to (i.e. the "target path"). It's not much work to do it now, but it's very abstract - needing to know a weird string pattern. This just wraps that weirdness up in a simple function (`getTargetPath()`).
Thanks!
Commits
-------
18dfe37 Adding new TargetPathTrait to get/set the authentication "target_path"
This PR was merged into the 2.3 branch.
Discussion
----------
[Yaml] ensure dump indentation to be greather than zero
| Q | A
| ------------- | ---
| Branch | 2.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/17943#issuecomment-190881815, #17977
| License | MIT
| Doc PR |
Commits
-------
3464282 ensure dump indentation to be greather than zero
This PR was squashed before being merged into the 2.7 branch (closes#16886).
Discussion
----------
[Form] [ChoiceType] Prefer placeholder to empty_value
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #16885
| License | MIT
| Doc PR | -
Prefer an explicitly set `placeholder` option (i.e. `false` or a non-empty
string) to an `empty_value` option when both are set.
The fix is to change the behaviour in the placeholder normalizer in
ChoiceType::configureOptions so that the value of the `empty_value` option is
used for placeholder only when the value of `placeholder` is null or an empty
string.
Commits
-------
a4d4c8a [Form] [ChoiceType] Prefer placeholder to empty_value
* 3.0:
fix debug toolbar rendering by removing inadvertently added links
[Form] minor fix tests of Bootstrap layout
[From] minor fix tests added by #17798 for bootstrap theme
simplified code
Allow variadic controller parameters to be resolved.
* 2.8:
fix debug toolbar rendering by removing inadvertently added links
[Form] minor fix tests of Bootstrap layout
[From] minor fix tests added by #17798 for bootstrap theme
simplified code
Allow variadic controller parameters to be resolved.
This PR was merged into the 2.7 branch.
Discussion
----------
[From] minor fix tests added by #17798 for bootstrap theme
| Q | A
| ------------- | ---
| Branch | 2.7+
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | -
Commits
-------
ee5b119 [From] minor fix tests added by #17798 for bootstrap theme
This PR was squashed before being merged into the 3.1-dev branch (closes#17761).
Discussion
----------
[Console] Add non-auto column width functionality
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR | [#6296](https://github.com/symfony/symfony-docs/pull/6296)
Be able to fix a columns width in a console table (i.e. set a columns width beforehand).
When a column's contents exceed the given column width, it will stretch.
Very useful, for instance, when one wants to display multiple tables that are separated from each other, but still want to align their columns.
Commits
-------
20c81b2 [Console] Add non-auto column width functionality
* 3.0:
fixed issue with PHP 5.3
The WebProcessor now forwards the client IP
minor changes
[#17878] Fixing a bug where scalar values caused invalid ordering
[#17724] Fixing autowiring bug where if some args are set, new ones are put in the wrong spot
bumped Symfony version to 2.3.39
updated VERSION for 2.3.38
update CONTRIBUTORS for 2.3.38
updated CHANGELOG for 2.3.38
* 2.8:
fixed issue with PHP 5.3
The WebProcessor now forwards the client IP
minor changes
[#17878] Fixing a bug where scalar values caused invalid ordering
[#17724] Fixing autowiring bug where if some args are set, new ones are put in the wrong spot
bumped Symfony version to 2.3.39
updated VERSION for 2.3.38
update CONTRIBUTORS for 2.3.38
updated CHANGELOG for 2.3.38
This PR was merged into the 2.8 branch.
Discussion
----------
[DependencyInjection] Fixing autowiring bug when some args are set
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17724, #17878
| License | MIT
| Doc PR | todo
This fixes#17724 & #17878.
**#17724**
I've set this against the 2.8 branch because imo it's a bug fix. The [test](https://github.com/symfony/symfony/compare/2.8...weaverryan:auto-wiring-individuals?expand=1#diff-d124c3d39cd5f7c732fb3d3be7a8cb42R298) illustrates the bug - having *some* arguments set beforehand caused auto-wired arguments to be set on the wrong index.
**#17878**
I've also included this fix just to get all the weird ordering problems taken care of at once. I don't think this is a behavior change - autowiring with scalars only worked previously if the argument was optional (still works now) or if you specified that argument explicitly (still works). Otherwise, your argument ordering would have gotten messed up.
Commits
-------
260731b minor changes
865f202 [#17878] Fixing a bug where scalar values caused invalid ordering
cf692a6 [#17724] Fixing autowiring bug where if some args are set, new ones are put in the wrong spot
* 3.0:
Improved Bootstrap form theme for hidden fields
[WebProfilerBundle] Fix design issue in profiler when having errors in forms
bumped Symfony version to 3.0.4
updated VERSION for 3.0.3
updated CHANGELOG for 3.0.3
bumped Symfony version to 2.8.4
updated VERSION for 2.8.3
updated CHANGELOG for 2.8.3
bumped Symfony version to 2.7.11
updated VERSION for 2.7.10
updated CHANGELOG for 2.7.10
* 2.8:
Improved Bootstrap form theme for hidden fields
[WebProfilerBundle] Fix design issue in profiler when having errors in forms
bumped Symfony version to 2.8.4
updated VERSION for 2.8.3
updated CHANGELOG for 2.8.3
bumped Symfony version to 2.7.11
updated VERSION for 2.7.10
updated CHANGELOG for 2.7.10
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Validator] Added a format option to the DateTime constraint.
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | #14521
| License | MIT
This PR adds a `format` option to the `DateTime` constraint, this allows to validate dates in custom formats, for example:
```php
use Symfony\Component\Validator\Constraints\DateTime;
use Symfony\Component\Validator\Validation;
$validator = Validation::createValidator();
$validator->validate('December 31, 1999', new DateTime(['format' => 'F d, Y']));
$validator->validate('01:02:03', new DateTime(['format' => 'H:i:s']));
$validator->validate('2010/01/01 01:02', new DateTime(['format' => 'Y/m/d H:i']));
```
As you can see this new option allows to use the `DateTime` constraint to validate dates and times, so, maybe the `Date` and `Time` constraints can be deprecated in this PR.
Commits
-------
9e94c9f Added a format option to the DateTime constraint.
This PR was squashed before being merged into the 2.7 branch (closes#17568).
Discussion
----------
Improved Bootstrap form theme for hidden fields
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #16925
| License | MIT
| Doc PR | -
Commits
-------
ba5d7f9 Improved Bootstrap form theme for hidden fields
* 3.0:
#17676 - making the proxy instantiation compatible with ProxyManager 2.x by detecting proxy features
#17676 - making the proxy instantiation compatible with ProxyManager 2.x by detecting proxy features
Fix bug when using an private aliased factory service
[Form] fix tests added by #17798 by removing `choices_as_values`
[Form] fix FQCN in tests added by #17798
[DependencyInjection] Remove unused parameter of private property
bug #17798 [Form] allow `choice_label` option to be `false`
[Form] fix tests added by #17760 with FQCN
ChoiceFormField of type "select" could be "disabled"
Update contributing docs
[Console] Fix escaping of trailing backslashes
Fix constraint validator alias being required
[DependencyInjection] Simplified code in AutowirePass
[ci] clone with depth=1 to kill push-forced PRs
Add check on If-Range header
* 2.8:
#17676 - making the proxy instantiation compatible with ProxyManager 2.x by detecting proxy features
Fix bug when using an private aliased factory service
ChoiceFormField of type "select" could be "disabled"
Update contributing docs
[Console] Fix escaping of trailing backslashes
Fix constraint validator alias being required
[ci] clone with depth=1 to kill push-forced PRs
Add check on If-Range header
* 2.7:
#17676 - making the proxy instantiation compatible with ProxyManager 2.x by detecting proxy features
Fix bug when using an private aliased factory service
ChoiceFormField of type "select" could be "disabled"
Update contributing docs
[Console] Fix escaping of trailing backslashes
Fix constraint validator alias being required
[ci] clone with depth=1 to kill push-forced PRs
Add check on If-Range header
* 2.3:
#17676 - making the proxy instantiation compatible with ProxyManager 2.x by detecting proxy features
Fix bug when using an private aliased factory service
ChoiceFormField of type "select" could be "disabled"
Update contributing docs
[Console] Fix escaping of trailing backslashes
Fix constraint validator alias being required
[ci] clone with depth=1 to kill push-forced PRs
Add check on If-Range header
* 2.8:
[Form] fix FQCN in tests added by #17798
bug #17798 [Form] allow `choice_label` option to be `false`
[DependencyInjection] Simplified code in AutowirePass
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Yaml] add option to dump objects as maps
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #9870, #12860, #15781, #15937, #16266
| License | MIT
| Doc PR | TODO
Commits
-------
3941d2e [Yaml] add option to dump objects as maps
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Yaml] add support for parsing the !!binary tag
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #8094, #15587, #17599
| License | MIT
| Doc PR | TODO
Commits
-------
79a63d5 [Yaml] add support for the !!binary tag
This PR was merged into the 2.8 branch.
Discussion
----------
[DependencyInjection] Simplified code in AutowirePass
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Commits
-------
ce0357e [DependencyInjection] Simplified code in AutowirePass
This PR was squashed before being merged into the 3.1-dev branch (closes#17738).
Discussion
----------
[PropertyAccess] Throw an InvalidArgumentException when the type do not match
| Q | A
| ------------- | ---
| Bug fix? | no (?)
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Currently, when the Property Access Component call a setter with a value not matching its typehint, a `\TypeError` is thrown with PHP 7 and a `PHP Catchable fatal error` with PHP 5.
This PR make the component returning an `InvalidArgumentException` with both version. It's a (better) alternative to #17660 (the hardening part) to make the Symfony Serializer (and probably many other pieces of code) more robust when types do not match.
/cc @csarrazi @mRoca @blazarecki
Commits
-------
e70fdbc [PropertyAccess] Throw an InvalidArgumentException when the type do not match
* 3.0:
[WIP] [3.0] [Form] fix tests added by #17760 by removing
removed obsolete code
[HttpFoundation] Remove @throws from ParameterBag::get() PHPDoc. This was for the now removed deep flag.
[Form] refactor `RadioListMapper::mapDataToForm()`
[Form] fix choice value "false" in ChoiceType
This PR was squashed before being merged into the 3.0 branch (closes#17886).
Discussion
----------
[WIP] [3.0] [Form] fix tests added by #17760 by removing `choices_as_values`
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | not yet
| Fixed tickets | n/a
| License | MIT
| Doc PR | -
- [x] Wait for #17760 being merged in 3.0
Commits
-------
03a7705 [WIP] [3.0] [Form] fix tests added by #17760 by removing
This PR was merged into the 3.1-dev branch.
Discussion
----------
[PropertyInfo] Use last version of reflection docblock
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
This PR improve the PhpDocExtractor to use https://github.com/phpDocumentor/ReflectionDocBlock 3.0 dev branch instead of https://github.com/phpDocumentor/ReflectionDocBlock 1.0.7 which is not maintained since 2014
I don't know if it's a BC break since it's only a suggested dependency.
This is somehow mandatory (we can maybe use a more stable, but also not maintained version of this repository) for #17516 as it does not have a dependency on php-parser 0.9.4 which is very old and not really suitable for the new component.
Commits
-------
d642eae Use last version of reflection dockblock, avoid extra dependancy if library needed
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Ldap] Added environment-based Ldap server configuration for tests
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
This PR makes Ldap server host and port configurable by using environment variables. This enables a developer to test the Ldap component locally, or on a vagrant virtual machine, depending on the use case.
If one wishes to run the tests against his own Ldap server, one simply needs to use the `LDAP_HOST` and `LDAP_PORT` environment variables when running the `phpunit` command.
Commits
-------
d0fbaea Added environment-based Ldap server configuration for tests
This PR was merged into the 2.7 branch.
Discussion
----------
[2.7] [Form] fix choice value "false" in ChoiceType
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #17292, #14712, #17789
| License | MIT
| Doc PR | -
- [x] Add tests for choices with `boolean` and `null` values, and with a placeholder
- [x] Fix FQCN in 2.8 tests, see #17759
- [x] Remove `choices_as_values` in 3.0 tests, see #17886
Commits
-------
8f918e5 [Form] refactor `RadioListMapper::mapDataToForm()`
3eac469 [Form] fix choice value "false" in ChoiceType
This PR was merged into the 3.0 branch.
Discussion
----------
[HttpFoundation] Remove @throws from ParameterBag::get() PHPDoc
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
This was for the now removed deep flag.
Commits
-------
cdfb696 [HttpFoundation] Remove @throws from ParameterBag::get() PHPDoc. This was for the now removed deep flag.
This PR was merged into the 3.1-dev branch.
Discussion
----------
[Serializer] Add a normalizer that support JsonSerializable objects
This normalizer makes it easier to start to combine using `JsonSerializable` objects with the Symfony serializer. I have implemented it in a number of projects and #13496 shows that others are doing so as well. So it seemed like it would be useful to include it in the Serializer component.
It handles circular references in the same way as the other normalizers.
Because groups and max depth are based on property annotations it doesn't make sense to apply them here.
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #13496
| License | MIT
| Doc PR |
Commits
-------
a678881 Add a normalizer that support JsonSerializable objects
* 3.0:
[3.0] [Tests] minor fix following #17787
[2.8] [Form] minor fix some tests with placeholder in AbstractLayout
[DependencyInjection] fix tests
Validate XLIFF translation files
[DependencyInjection] replace alias in factories
replace alias in factory services
This PR was merged into the 3.0 branch.
Discussion
----------
[3.0] [Form/Tests] minor fix following #17787
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | -
Commits
-------
020ac04 [3.0] [Tests] minor fix following #17787
* 2.8:
[2.8] [Form] minor fix some tests with placeholder in AbstractLayout
[DependencyInjection] fix tests
Validate XLIFF translation files
[DependencyInjection] replace alias in factories
replace alias in factory services
This PR was merged into the 2.8 branch.
Discussion
----------
[2.8] [Form] minor fix some regression in tests with placeholder in AbstractLayout
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | -
Commits
-------
6977583 [2.8] [Form] minor fix some tests with placeholder in AbstractLayout