Commit Graph

31645 Commits

Author SHA1 Message Date
Christian Flothmann
fa3586029f catch any UnexpectedValueException on validation 2018-10-24 09:52:19 +02:00
Fabien Potencier
b452c015cc feature #28875 [FWBundle] Add a new method AbstractController::addLink() (dunglas)
This PR was squashed before being merged into the 4.2-dev branch (closes #28875).

Discussion
----------

[FWBundle] Add a new method AbstractController::addLink()

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      |no
| New feature?  | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | todo

This provides a convenient method to add `Link` headers to the current `Response` directly from the `Request` object.
It improves the developer experience and the discoverability of [the WebLink component](https://github.com/symfony/symfony-docs/pull/10309).

Usage:

```php
namespace App\Controller;

use Fig\Link\Link;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;

class MyAction extends AbstractController
{
    public function __invoke(Request $request): Response
    {
        $this->addLink($request, new Link('mercure', 'https://demo.mercure.rocks'));

        return $this->json(['foo' => 'bar']);
    }
}
```

Commits
-------

4d20c39f70 [FWBundle] Add a new method AbstractController::addLink()
2018-10-24 05:28:52 +02:00
Kévin Dunglas
4d20c39f70 [FWBundle] Add a new method AbstractController::addLink() 2018-10-24 05:28:45 +02:00
Fabien Potencier
9d3621eadb bug #28878 [OptionsResolver] Trigger deprecation only if the option is used (yceruto)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[OptionsResolver] Trigger deprecation only if the option is used

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #28848
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/pull/10496

It's true that showing a deprecation message when the option is not used is a bit annoying and it would be heavy to get rid of it.

Now, a deprecated option is triggered only when it's provided by the user or each time is being called from a lazy evaluation (except for deprecations based on the value, they're triggered only when provided by the user).

Commits
-------

1af23c9a74 [OptionsResolver] Trigger deprecation only if the option is used
2018-10-24 05:25:07 +02:00
Yonel Ceruto
1af23c9a74 [OptionsResolver] Trigger deprecation only if the option is used 2018-10-24 05:23:30 +02:00
Fabien Potencier
01dfca1590 feature #28934 [WebProfilerBundle] Add channel log filter (ro0NL)
This PR was squashed before being merged into the 4.2-dev branch (closes #28934).

Discussion
----------

[WebProfilerBundle] Add channel log filter

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #...   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Continuation of #28906

The JS is revised to be more generic;

- support 2 filter types: `level` and `choice` (respectively `Log level` and `Log channel` here)
- remove default filter value support (not used yet, but opportunity kept open) - it requires a bit more work to genericify it.
- filters refines the resultset (e.g. show all logs in the app channel with priority higher than alert)

![image](https://user-images.githubusercontent.com/1047696/47257162-b01bfe00-d48a-11e8-8364-d1eca69c9182.png)

Level filter (works the same as shown in #28906 )

![image](https://user-images.githubusercontent.com/1047696/47257699-78648480-d491-11e8-8c55-1dccda980de4.png)

Choice filter

![image](https://user-images.githubusercontent.com/1047696/47257205-3c2e2580-d48b-11e8-821b-e95bfed36331.png)

![image](https://user-images.githubusercontent.com/1047696/47257209-4bad6e80-d48b-11e8-8fcc-e868aa556ff8.png)

We forgot to update TwigBundle previously, that's still needed after review here.

Commits
-------

e1bd82e89c [WebProfilerBundle] Add channel log filter
2018-10-24 05:22:28 +02:00
Roland Franssen
e1bd82e89c [WebProfilerBundle] Add channel log filter 2018-10-24 05:22:15 +02:00
David Buchmann
28d9f0c84c also clean away the NO_AUTO_CACHE_CONTROL_HEADER if we have no session 2018-10-23 16:30:58 +02:00
Fabien Potencier
e0c6049777 bug #28942 [WebProfilerBundle] Disable messenger panel if needed (ro0NL)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[WebProfilerBundle] Disable messenger panel if needed

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #...   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Before:

![image](https://user-images.githubusercontent.com/1047696/47267243-94bffa00-d541-11e8-9a77-ca93d57629f3.png)

After

![image](https://user-images.githubusercontent.com/1047696/47267248-a4d7d980-d541-11e8-81d2-20e5957970ba.png)

Commits
-------

2c4cb06f0e [WebProfilerBundle] Disable messenger panel if needed
2018-10-23 15:27:42 +02:00
Roland Franssen
f5c355e1ba [WebProfilerBundle] Remove application name 2018-10-23 14:46:28 +02:00
Nicolas Grekas
946d278d7d [Process] fix waitUntil+add tests 2018-10-23 11:03:43 +02:00
Nicolas Grekas
9d9bd2d162 bug #28953 [WebProfilerBundle] Reword referer link (ro0NL)
This PR was squashed before being merged into the 4.2-dev branch (closes #28953).

Discussion
----------

[WebProfilerBundle] Reword referer link

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | https://github.com/symfony/symfony/pull/28936#issuecomment-431679873, https://github.com/symfony/symfony/pull/28936#discussion_r226956445
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

![image](https://user-images.githubusercontent.com/1047696/47310273-e6967c00-d636-11e8-827a-72f8f4ca894b.png)

Commits
-------

a5313ab2e6 [WebProfilerBundle] Reword referer link
2018-10-23 09:41:11 +02:00
Roland Franssen
a5313ab2e6 [WebProfilerBundle] Reword referer link 2018-10-23 09:40:59 +02:00
Nicolas Grekas
fc7aeb95e0 bug #28940 [Process] Adds usleep(1000) to ease CPU usage. (miniyarov)
This PR was squashed before being merged into the 4.2-dev branch (closes #28940).

Discussion
----------

[Process] Adds usleep(1000) to ease CPU usage.

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | symfony/symfony-docs

Commits
-------

9d1416ad82 [Process] Adds usleep(1000) to ease CPU usage.
2018-10-23 09:28:42 +02:00
Ulugbek Miniyarov
9d1416ad82 [Process] Adds usleep(1000) to ease CPU usage. 2018-10-23 09:28:33 +02:00
Nicolas Grekas
717ff2dd68 minor #28737 [DependencyInjection] Optimize exporting variables (Sander van der Vlugt)
This PR was squashed before being merged into the 4.2-dev branch (closes #28737).

Discussion
----------

[DependencyInjection] Optimize exporting variables

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #28292
| License       | MIT

Store previously resolved variables so that the relatively expensive function [resolveEnvPlaceholders](3e7b029524/src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php (L1776)) is not called unnecessarily.

The effect on running ```bin/console``` with an empty cache in a big application (200+ env variables) in seconds:

| Before     | After      |
|------------|------------|
| 24.1       | 15.8       |
| 24.5       | 16.0       |
| 24.7       | 16.3       |
| 24.2       | 16.0       |
|  Avg: 24.4 | Avg:16.0   |

Commits
-------

768de2f7d9 [DependencyInjection] Optimize exporting variables
2018-10-23 09:21:59 +02:00
Sander van der Vlugt
768de2f7d9 [DependencyInjection] Optimize exporting variables 2018-10-23 09:21:50 +02:00
Nicolas Grekas
60394bc348 minor #28200 [Config] Fix slow service discovery for large excluded directories (gonzalovilaseca)
This PR was squashed before being merged into the 4.2-dev branch (closes #28200).

Discussion
----------

[Config] Fix slow service discovery for large excluded directories

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  |  no
| BC breaks?    | no
| Deprecations? |  no
| Tests pass?   | no
| Fixed tickets | #26736
| License       | MIT
| Doc PR        |

Not sure if this is a bug fix or not, is more an improvement.
Please for all detail follow the conversation here:
https://github.com/symfony/symfony/issues/26736

Commits
-------

fa731e53e9 [Config] Fix slow service discovery for large excluded directories
2018-10-23 09:19:46 +02:00
Gonzalo Vilaseca
fa731e53e9 [Config] Fix slow service discovery for large excluded directories 2018-10-23 09:19:36 +02:00
Kévin Dunglas
426cf81c16
feature #28709 [Serializer] Refactor and uniformize the config by introducing a default context (dunglas)
This PR was squashed before being merged into the 4.2-dev branch (closes #28709).

Discussion
----------

[Serializer] Refactor and uniformize the config by introducing a default context

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | yes <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | todo <!-- required for new features -->

This PR uniformizes how the Serializer's configuration is handled:

* As currently, configuration options can be set using the context (options that weren't configurable using the context have been refactored to leverage it)
* Normalizers and encoders' constructors now accept a "default context"
* All existing global configuration flags (constructor parameters) have been deprecated in favor of this new default context
* the stateless context is always tried first, then is the default context

Some examples:

```php
// Configuring groups globally
// Before: not possible
// After
$normalizer = new ObjectNormalizer(/* deps */, ['groups' => 'the_default_group']);

// Escaping Excel-like formulas in CSV files
// Before
$encoder = new CsvEncoder(',', '"', '\\', '.', true);
// After
$encoder = new CsvEncoder(['csv_escape_formulas' => true]);
$encoder->normalize($data, 'csv', ['csv_escape_formulas' => false]); // Override for this call only
```

Benefits:

* The DX is dramatically improved, configuration is always handled in similar way
* The serializer can be used in fully stateless way
* Every options can be configured globally
* Classes that had constructors with a lot of parameters (like `CsvEncoder`) are now much easier to use
* We'll be able to improve the documentation by adding a dictionary of all available context options for the whole component
* Everything can be configured the same way

TODO in subsequent PRs:

* Add a new option in framework bundle to configure the context globally
* Uniformize the constants name (sometimes the name if `FOO`, sometimes `FOO_KEY`)
* Fix the "bug" regarding the format configuration in `DateTimeNormalizer::denormalize()`  (see comments)
* Maybe: move `$defaultContext` as the first parameter (before required services?)
* Make `XmlEncoder` stateless

Commits
-------

52b186a210 [Serializer] Refactor and uniformize the config by introducing a default context
2018-10-23 08:24:58 +02:00
Kévin Dunglas
52b186a210
[Serializer] Refactor and uniformize the config by introducing a default context 2018-10-23 08:24:47 +02:00
Nicolas Grekas
a0cbcacef4 minor #28951 [HttpFoundation] Merging arrays in a loop is slow and causes high CPU usage (zholus)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[HttpFoundation] Merging arrays in a loop is slow and causes high CPU usage

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT

As described here, https://github.com/kalessil/phpinspectionsea/blob/master/docs/performance.md#slow-array-function-used-in-loop, merging arrays in a loop is slow and causes high CPU usage (benchmarks are also on the link), this pull request solves this problem

Commits
-------

3db84789f2 Merging arrays in a loop is slow and causes high CPU usage
2018-10-22 22:12:42 +02:00
Nicolas Grekas
414416ab95 bug #28941 [TwigBundle] Right trim plain text traces (ro0NL)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[TwigBundle] Right trim plain text traces

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #...   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Just polishing now :)

Before:

![image](https://user-images.githubusercontent.com/1047696/47265096-e6a55780-d522-11e8-99ae-5ae5cfa32dd5.png)

After:

![image](https://user-images.githubusercontent.com/1047696/47265091-db522c00-d522-11e8-942b-98c8821793b3.png)

Commits
-------

11dbd1d40e [TwigBundle] Right trim plain text traces
2018-10-22 22:11:03 +02:00
alex
3db84789f2 Merging arrays in a loop is slow and causes high CPU usage 2018-10-22 18:12:06 +02:00
Samuel ROZE
9aaec948d5 minor #28908 [Messenger] internal cleanups (nicolas-grekas)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Messenger] internal cleanups

| Q             | A
| ------------- | ---
| Branch?       | 4.2
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | yes
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

From the updated changelog:
 * `MessengerDataCollector::getMessages()` returns an iterable, not just an array anymore
 * `AbstractHandlerLocator` is now internal
 * `HandlerLocatorInterface::resolve()` has been replaced by `getHandler(Envelope $envelope)`
 * `SenderLocatorInterface::getSenderForMessage()` has been replaced by `getSender(Envelope $envelope)`
 * `SenderInterface::send()` returns `void`

+ some internal simplifications

Commits
-------

4a3edd0b37 [Messenger] internal cleanups
2018-10-21 16:29:45 +01:00
Nicolas Grekas
4a3edd0b37 [Messenger] internal cleanups 2018-10-21 16:46:18 +02:00
Nicolas Grekas
6a5d7a1aac [Messenger] make middlewares truly lazy on a bus 2018-10-21 15:50:49 +02:00
Roland Franssen
2c4cb06f0e [WebProfilerBundle] Disable messenger panel if needed 2018-10-21 14:56:03 +02:00
Nicolas Grekas
ae46a436e7 [Messenger] make Envelope first class citizen for middleware handlers 2018-10-21 14:43:41 +02:00
Samuel ROZE
d901c6d846 feature #28909 [Messenger] made dispatch() and handle() return void (nicolas-grekas)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Messenger] made dispatch() and handle() return void

| Q             | A
| ------------- | ---
| Branch?       | 4.2
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | yes
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Middlewares and dispatchers should not return any value. Forwarding back the results from handlers breaks the scope of the component. The canonical example of some bad design this can lead to is `ChainHandler`: how can the caller know that there is one in the chain and that it should expect an array as a return value? More generally, how can a caller know what to expect back from a call to dispatch()? I think we should not allow such broken designs.

Instead, we should favor east-oriented design: if one needs a command bus, one would have to dispatch a proper command object - and if a result is expected back, it should be done via a setter on the dispatched command - or better, a callback set on the command object. This way we play *by the rules* of the type-system, not against.

Commits
-------

f942ffcb1b [Messenger] made dispatch() and handle() return void
2018-10-21 13:42:19 +01:00
Roland Franssen
11dbd1d40e [TwigBundle] Right trim plain text traces 2018-10-21 11:14:09 +02:00
Fabien Potencier
316e95c06c feature #28936 [WebProfilerBundle] Replay referer URL (ro0NL)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[WebProfilerBundle] Replay referer URL

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26226
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

For non GET/HEAD requests (e.g. POST) that have a referer URL; allow to replay it. And thereby fix the missing navigation piece to get back to your application.

Default

![image](https://user-images.githubusercontent.com/1047696/47259042-3c86ea80-d4a4-11e8-99f7-c3941beaa72c.png)

On hover

![image](https://user-images.githubusercontent.com/1047696/47259048-54f70500-d4a4-11e8-9e44-e20121f5b04f.png)

Commits
-------

9020d49765 [WebProfilerBundle] Replay referer URL
2018-10-21 08:57:01 +02:00
Fabien Potencier
efa4f16ed1 bug #28913 Fix debug:container which crash when the service class has no doc comment (l-vo)
This PR was merged into the 4.2-dev branch.

Discussion
----------

Fix debug:container which crash when the service class has no doc comment

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

The console command container:debug have now the ability to display service description, based on phpdoc comments of the service class. But the command currently crash when selecting a service with a class without phpdoc description.

This PR fixes this issue.

Commits
-------

aed0a5a38a [FrameworkBundle] Fix debug:container which crash when the service class has no doc comment
2018-10-21 08:53:32 +02:00
Titouan Galopin
246a905f93 [TwigBundle] Fix usage of TwigBundle without FrameworkBundle 2018-10-21 08:50:17 +02:00
Fabien Potencier
c620a3bd7f feature #28891 [TwigBundle] Deprecating support for legacy templates directories (yceruto)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[TwigBundle] Deprecating support for legacy templates directories

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/pull/10500

go ahead with https://github.com/symfony/symfony/pull/28810#issuecomment-430245394

- [x] Fix tests

Commits
-------

8b390f346f Deprecating support for legacy templates directories
2018-10-21 08:42:32 +02:00
Dariusz Ruminski
6f83d9f9a3 Revert "fixed CS"
This reverts commit d48a3776fe.
2018-10-21 01:16:31 +02:00
Fabien Bourigault
326c267de2 [Serializer] Reduce class discriminator overhead 2018-10-20 23:22:07 +02:00
Olivier Laviale
baf6f8cc34 Skip empty proxy code 2018-10-20 22:20:36 +02:00
Nicolas Grekas
915870e0a3 bug #28904 [Serializer] fix MetadataAwareNameConverter break denormalization (Britaliope)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Serializer] fix MetadataAwareNameConverter break denormalization

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |  -
| License       | MIT
| Doc PR        |  -

During denormalization of an object, the `normalize` function of the `MetadataAwareNormalizer` is called to find the serialized name of constructor arguments. This do not work if the constructor argument is not in the serialized representation of the object (for example given with a `default_constructor_arguments` option ).

**Checklist**
- [x] Add test to cover the bug

Commits
-------

faf8b009dc [Serializer] fix MetadataAwareNameConverter break denormalization
2018-10-20 20:21:07 +02:00
Roland Franssen
9020d49765 [WebProfilerBundle] Replay referer URL 2018-10-20 20:06:30 +02:00
Nicolas Grekas
69d04b5dcb minor #28921 [FrameworkBundle] Fix CacheInterface ns (ogizanagi)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[FrameworkBundle] Fix CacheInterface ns

| Q             | A
| ------------- | ---
| Branch?       | master <!-- see below -->
| Bug fix?      | yes
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

(used for cache pools autowiring aliases for arguments)

Commits
-------

298a60dc19 [FrameworkBundle] Fix CacheInterface ns
2018-10-20 20:00:42 +02:00
Nicolas Grekas
f942ffcb1b [Messenger] made dispatch() and handle() return void 2018-10-20 15:00:30 +02:00
Nicolas Grekas
4d757b5382 feature #28911 [Messenger] rename "envelope items" and move them in the "Stamp" namespace (nicolas-grekas)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Messenger] rename "envelope items" and move them in the "Stamp" namespace

| Q             | A
| ------------- | ---
| Branch?       | 4.2
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | yes
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Right now, envelope items are scattered in different sub namespaces and use the "Configuration" suffix.
This makes them hard to discover.
This PR creates a new `Stamp` namespace and moves all "envelope items" there, renaming them to use the "stamp" terminology.

From the changelog:
 * `Envelope`'s constructor and `with` method now accept `StampInterface` objects as variadic parameters
 * Renamed `EnvelopeItemInterface` to `StampInterface`
 * Renamed and moved `ReceivedMessage`, `ValidationConfiguration` and `SerializerConfiguration` in the `Stamp` namespace
 * Removed the `WrapIntoReceivedMessage` (it's untested and unused)

Commits
-------

0ad2cb906d [Messenger] rename "envelope items" and move them in the "Stamp" namespace
2018-10-20 14:56:47 +02:00
Albert Casademont
7b256a985d
[Security] Fix "exclude-from-classmap"
The "/Tests/" directory doesn't exist in the Security Component, tests are located within the Security components folders and none of the tests were being excluded in an --classmap-authoritative dump of the autoload.
2018-10-19 23:57:12 +02:00
Laurent VOULLEMIER
aed0a5a38a [FrameworkBundle] Fix debug:container which crash when the service class has no doc comment 2018-10-19 16:17:41 +02:00
Grégoire Pineau
f99786314e [Security] Removed unsed trait import 2018-10-19 14:22:12 +02:00
Fabien Potencier
0acf9e17d4 minor #28916 [Form] Fix @method annotation (ro0NL)
This PR was squashed before being merged into the 4.2-dev branch (closes #28916).

Discussion
----------

[Form] Fix @method annotation

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #...   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Same as #28915 for 4.2 (these are the only occurrences for interfaces)

Actually provides a use case for https://github.com/symfony/symfony/pull/28902#issuecomment-430904459 🎉

Commits
-------

13f0db718e [Form] Fix @method annotation
2018-10-19 12:21:50 +02:00
Roland Franssen
13f0db718e [Form] Fix @method annotation 2018-10-19 12:21:43 +02:00
Roland Franssen
0d7a961338 [Config] Fix @method annotation 2018-10-19 12:20:44 +02:00
Fabien Potencier
3abb993081 minor #28922 [Cache] Fix outdated CHANGELOG line (ogizanagi)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Cache] Fix outdated CHANGELOG line

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

Unless it was kept on purpose, for `Symfony\Contracts\Cache\CacheInterface` discoverability? In which case I'd add the FQCN.

Commits
-------

4e89a4bc03 [Cache] Fix outdated CHANGELOG line
2018-10-19 11:47:11 +02:00
Fabien Potencier
91a2d758b0 minor #28906 Redesigned the log message filter (javiereguiluz)
This PR was merged into the 4.2-dev branch.

Discussion
----------

Redesigned the log message filter

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | -   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | - <!-- required for new features -->

In 4.2 we've added a log filter that looks like this:

![filter-before](https://user-images.githubusercontent.com/73419/47091585-71d1d500-d225-11e8-9090-fa36defa598d.png)

I propose a complete redesign to make it more subtle, but still useful. Filter is now displayed like this:

![filter-overview](https://user-images.githubusercontent.com/73419/47091639-857d3b80-d225-11e8-87ba-beaa5bf5c83b.png)

When you click on each level, only the messages of that and higher levels are displayed ... and the other levels look disabled:

| Initial | Selected
| --- | ---
| ![filter-initial](https://user-images.githubusercontent.com/73419/47091706-ac3b7200-d225-11e8-84c3-bb5ef9fcabc5.png) | ![filter-selected](https://user-images.githubusercontent.com/73419/47091717-b198bc80-d225-11e8-972b-6f03cdbbd0ab.png)

The icons display an "up arrow" and "down arrow" depending on the level to try to explain that you are rising or reducing the current level:

![filter-in-action](https://user-images.githubusercontent.com/73419/47091827-ec9af000-d225-11e8-96cf-383e93688b29.gif)

Commits
-------

2271a3bf4d Redesigned the log message filter
2018-10-19 11:44:36 +02:00
Maxime Steinhausser
4e89a4bc03 [Cache] Fix outdated CHANGELOG line 2018-10-19 10:25:57 +02:00
Maxime Steinhausser
298a60dc19 [FrameworkBundle] Fix CacheInterface ns 2018-10-19 08:26:23 +02:00
Nicolas Grekas
0ad2cb906d [Messenger] rename "envelope items" and move them in the "Stamp" namespace 2018-10-18 15:00:56 +02:00
Nicolas Grekas
2a2914e208 [Serializer] Improve perf a bit by not using a signaling exception when not needed 2018-10-17 20:52:05 +02:00
Fabien Potencier
8322494a47 bug #28801 Convert InsufficientAuthenticationException to HttpException with 401 status code (vincentchalamon)
This PR was merged into the 2.8 branch.

Discussion
----------

Convert InsufficientAuthenticationException to HttpException with 401 status code

| Q             | A
| ------------- | ---
| Branch?       | 2.8
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed ticket | #8467
| License       | MIT

I was trying to implement the `json_login` authentication and test it with an API Platform project. When I call a secured endpoint without authentication, an InsufficientAuthenticationException is thrown with a 500 status code instead of a 401.

After some researches with @dunglas, there is no default `entrypoint` on the security firewall. As one already exists for `form_login` in the FormLoginFactory, this component might need a default one to convert this 500 exception to a correct 401 HTTP error.

This fixes https://github.com/symfony/symfony/issues/25806#issuecomment-368461952.

Commits
-------

4503ac8e9f Convert InsufficientAuthenticationException to HttpException
2018-10-17 18:35:42 +02:00
Bruno MATEU
faf8b009dc [Serializer] fix MetadataAwareNameConverter break denormalization 2018-10-17 17:16:10 +02:00
Yonel Ceruto
8b390f346f Deprecating support for legacy templates directories 2018-10-17 10:07:16 -04:00
Javier Eguiluz
2271a3bf4d Redesigned the log message filter 2018-10-17 15:56:13 +02:00
Fabien Potencier
5145084808 bug #28840 add missing double-quotes to extra_fields output message (danielkay)
This PR was squashed before being merged into the 2.8 branch (closes #28840).

Discussion
----------

add missing double-quotes to extra_fields output message

| Q             | A
| ------------- | ---
| Branch?       | 2.8
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | N/A
| License       | MIT
| Doc PR        | N/A

When using the extra_fields_message option on FormTypes to include the extra_fields items in the message, the output included some superfluous (or, perhaps, missing?) quotes. This resulted in some strange output: `This form should not contain extra fields: notes1\", \"notes2\", \"notes3`.

This PR removes the quotes and instead implodes the extra_fields array using merely ', ' as the glue, resulting in the output: `This form should not contain extra fields: notes1, notes2, notes3`.

Commits
-------

9e7414159c add missing double-quotes to extra_fields output message
2018-10-17 15:52:59 +02:00
Daniel Kay
9e7414159c add missing double-quotes to extra_fields output message 2018-10-17 15:52:52 +02:00
Fabien Potencier
dd432c4f1e minor #28901 [HttpKernel] Introduce KernelInterface::getProjectDir() (ro0NL)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[HttpKernel] Introduce KernelInterface::getProjectDir()

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | not yet
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | https://github.com/symfony/symfony/pull/28897#issuecomment-430523336
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Removes the last call to getParameter('kernel.project_dir') during runtime in core. Yay :)

cc @fabpot @nicolas-grekas

Commits
-------

b046f414e7 [HttpKernel] Introduce KernelInterface::getProjectDir()
2018-10-17 11:43:15 +02:00
Roland Franssen
b046f414e7 [HttpKernel] Introduce KernelInterface::getProjectDir()
This reverts commit 704867986d, reversing
changes made to 557f85d1b3.
2018-10-17 11:36:49 +02:00
Fabien Potencier
f0814e17d7 feature #27043 [Form][TwigBridge] Add help_attr (mpiot)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Form][TwigBridge] Add help_attr

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Add help_attr to the  form_help method.

Commits
-------

42d54b73c3 Add help_attr
2018-10-17 09:52:45 +02:00
Fabien Potencier
72ab16d4c9 bug #28838 [DI] Default undefined env to empty string during compile (ro0NL)
This PR was squashed before being merged into the 4.1 branch (closes #28838).

Discussion
----------

[DI] Default undefined env to empty string during compile

| Q             | A
| ------------- | ---
| Branch?       | 4.1
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #28827
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Instead of using `null` for undefined envs, use `""` instead. We already default the type to string, so actually providing a string value makes sense. During runtime it will always be string also.

Commits
-------

38a8ab92fa [DI] Default undefined env to empty string during compile
2018-10-17 09:43:06 +02:00
Roland Franssen
38a8ab92fa [DI] Default undefined env to empty string during compile 2018-10-17 09:42:53 +02:00
Mathieu Piot
42d54b73c3 Add help_attr 2018-10-17 09:30:39 +02:00
Roland Franssen
894c155299 [FrameworkBundle] Avoid calling getProjectDir() on KernelInterface 2018-10-16 22:39:17 +02:00
Nicolas Grekas
819f525547 [HttpKernel] fix deprecating KernelInterface::getRootDir() 2018-10-16 17:46:02 +02:00
Nicolas Grekas
4964ffc8c0 [HttpKernel] fix kernel.name deprecation 2018-10-16 14:29:39 +02:00
Fabien Potencier
97c8fac856 Merge branch '4.1'
* 4.1:
  [FWBundle] Uniformize errors when a component is missing
  Fixes 28816 Translation commands should not talk about the old app/ directory since 3.4
2018-10-16 03:11:07 +02:00
Fabien Potencier
01808ca3bc Merge branch '3.4' into 4.1
* 3.4:
  [FWBundle] Uniformize errors when a component is missing
  Fixes 28816 Translation commands should not talk about the old app/ directory since 3.4
2018-10-16 03:10:55 +02:00
Fabien Potencier
fdc9e0993f minor #28829 Translation commands should not tell about the old app/ directory (e-moe)
This PR was merged into the 3.4 branch.

Discussion
----------

Translation commands should not tell about the old app/ directory

Fixes #28816 Translation commands should not talk about the old "app/" directory since 3.4

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #28816
| License       | MIT
| Doc PR        | n/a

Commits
-------

5fcc0b4d8d Fixes 28816 Translation commands should not talk about the old app/ directory since 3.4
2018-10-16 02:41:49 +02:00
Fabien Potencier
0b851c6956 [HttpKernel] deprecated usage of getRootDir() and kernel.root_dir 2018-10-15 20:25:13 +02:00
Fabien Potencier
5fda7e2fb1 feature #28809 [HttpKernel] Deprecate the Kernel name (fabpot)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[HttpKernel] Deprecate the Kernel name

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | yes <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26904
| License       | MIT
| Doc PR        | n/a

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - Bug fixes must be submitted against the lowest branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against the master branch.
-->

Commits
-------

98ff750ee1 [HttpKernel] deprecated the Kernel name
2018-10-15 17:49:38 +02:00
Fabien Potencier
98ff750ee1 [HttpKernel] deprecated the Kernel name 2018-10-15 17:39:36 +02:00
Roland Franssen
ce95d0d33d
[HttpFoundation] Publicify new consts 2018-10-15 17:16:38 +02:00
Fabien Potencier
76f80e9153 feature #28807 [HttpFoundation] Make ResponseHeaderBag::makeDisposition static (fabpot)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[HttpFoundation] Make ResponseHeaderBag::makeDisposition static

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes-ish
| BC breaks?    | no
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes
| Fixed tickets | #27851
| License       | MIT
| Doc PR        | n/a

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - Bug fixes must be submitted against the lowest branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against the master branch.
-->

Commits
-------

d29b410262 [HttpFoundation] made ResponseHeaderBag::makeDisposition static
2018-10-15 16:54:25 +02:00
Fabien Potencier
d29b410262 [HttpFoundation] made ResponseHeaderBag::makeDisposition static 2018-10-15 16:53:01 +02:00
Fabien Potencier
dc11f7b30a minor #28867 [FWBundle] Uniformize errors when a component is missing (dunglas)
This PR was merged into the 3.4 branch.

Discussion
----------

[FWBundle] Uniformize errors when a component is missing

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Commits
-------

fa3da4e72c [FWBundle] Uniformize errors when a component is missing
2018-10-15 15:14:28 +02:00
Christian Flothmann
f642355859 use constraint options instead of properties 2018-10-15 11:01:19 +02:00
Nicolas Grekas
3db3ad21d0 Merge branch '4.1'
* 4.1:
  Remove Process::escapeArgument argument type hint
  [Console] fix test using deprecated code
  [travis] build libsodium only if it's not already enabled
  Add a test case for stringifying of Process arguments
  Add a missing English translation
  [Console] Fixes multiselect choice question in interactive mode with default values
  [Validator] Add a missing Polish translation
  Allow integers as default console option value
  Setting missing default paths under BC layer
  Changed "epost-adress" to "e-postadress"
  Fix for race condition in console output stream write
  reverse transform RFC 3339 formatted dates
2018-10-14 13:50:41 -07:00
Valentin
acf8b8338a Remove Process::escapeArgument argument type hint 2018-10-14 13:48:13 -07:00
Nicolas Grekas
5bd240314c Merge branch '3.4' into 4.1
* 3.4:
  [Console] fix test using deprecated code
  [travis] build libsodium only if it's not already enabled
  Add a test case for stringifying of Process arguments
  Add a missing English translation
  [Console] Fixes multiselect choice question in interactive mode with default values
  [Validator] Add a missing Polish translation
  Allow integers as default console option value
  Setting missing default paths under BC layer
  Changed "epost-adress" to "e-postadress"
  Fix for race condition in console output stream write
  reverse transform RFC 3339 formatted dates
2018-10-14 12:02:12 -07:00
Nicolas Grekas
2caee9435f [Console] fix test using deprecated code 2018-10-14 12:00:59 -07:00
Kévin Dunglas
fa3da4e72c
[FWBundle] Uniformize errors when a component is missing 2018-10-14 20:50:15 +02:00
Nikolay Labinskiy
5fcc0b4d8d Fixes 28816 Translation commands should not talk about the old app/ directory since 3.4 2018-10-14 21:46:05 +03:00
Nicolas Grekas
55978d793f minor #28864 [Process] A test case for stringifying of Process arguments (vudaltsov)
This PR was merged into the 3.4 branch.

Discussion
----------

[Process] A test case for stringifying of Process arguments

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | for https://github.com/symfony/symfony/pull/28863
| License       | MIT
| Doc PR        |

Checks that non-string arguments passed to Process constructor are typecasted to string

Commits
-------

0d543428ad Add a test case for stringifying of Process arguments
2018-10-14 11:39:46 -07:00
Nicolas Grekas
a5792bfe01 Merge branch '2.8' into 3.4
* 2.8:
  Add a missing English translation
  [Console] Fixes multiselect choice question in interactive mode with default values
  [Validator] Add a missing Polish translation
  Allow integers as default console option value
  Changed "epost-adress" to "e-postadress"
  Fix for race condition in console output stream write
  reverse transform RFC 3339 formatted dates
2018-10-14 11:32:13 -07:00
Nicolas Grekas
c6b288e775 bug #28712 [Form] reverse transform RFC 3339 formatted dates (xabbuh)
This PR was merged into the 2.8 branch.

Discussion
----------

[Form] reverse transform RFC 3339 formatted dates

| Q             | A
| ------------- | ---
| Branch?       | 2.8
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #28699
| License       | MIT
| Doc PR        |

Technically, dates formatted according to the HTML specifications do not
contain any timezone information. But since our DateTimeType used to
contain this information in the passed, users had configure their JS
libraries to accept (and create) dates in that format.

To not break BC we should accept these dates and silently ignore the
additional timezone information.

Commits
-------

503239f75e reverse transform RFC 3339 formatted dates
2018-10-14 11:31:00 -07:00
Nicolas Grekas
0651e7cfb4 bug #28813 Fix for race condition in console output stream write (rudolfratusinski)
This PR was merged into the 2.8 branch.

Discussion
----------

Fix for race condition in console output stream write

| Q             | A
| ------------- | ---
| Branch?       | 2.8
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

In high throughput environments writing `message` and `PHP_EOL` separately causes race condition issues, where messages might be written in order

- message
- message
- EOL
- EOL

instead of

- message
- EOL
- message
- EOL

An example below is a laravel application log tail of queue workers  (multiple app instances writing to the same log file) handled by supervisor.

Before:
![ezgif-1-77388f9210cf](https://user-images.githubusercontent.com/2752769/46792349-bec13180-cd75-11e8-8f91-92f05762f964.gif)

After:
![ezgif-1-0b839d642644](https://user-images.githubusercontent.com/2752769/46792420-e617fe80-cd75-11e8-9414-4bfc85d9c569.gif)

Commits
-------

428dea6fb1 Fix for race condition in console output stream write
2018-10-14 11:27:40 -07:00
Valentin
0d543428ad Add a test case for stringifying of Process arguments 2018-10-14 20:33:21 +03:00
Roland Franssen
647a937abc [VarDumper] Scroll into view when searching 2018-10-14 09:29:41 +02:00
Fabien Potencier
e4e615958a minor #28845 Revert "feature #27801 [MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors" (nicolas-grekas)
This PR was merged into the 4.2-dev branch.

Discussion
----------

Revert "feature #27801 [MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors"

This reverts commit f27c3a8584, reversing
changes made to 9da045469e.

| Q             | A
| ------------- | ---
| Branch?       | 4.2
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

A bridge shouldn't provide interfaces to me so I submitted https://github.com/Seldaek/monolog/pull/1204 instead.

This PR reverts the possibility to autoconfigure processors for now, so that it could be moved to the MonologBundle instead.

To have TokenProcessor and WebProcessor classes implement the new ProcessorInterface, we could bump the minimum version of monolog. This cannot be done until a new version of it is tagged, so we need to resolve this before tagging 4.2 ourselves.

Commits
-------

cfc3f254e7 Revert "feature #27801 [MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors (nicolas-grekas)"
2018-10-13 06:08:28 -07:00
Fabien Potencier
9bec1fcf08 feature #28842 [Validator] Deprecate checkMX and checkHost on Email validator (fabpot)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Validator] Deprecate checkMX and checkHost on Email validator

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | yes
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | fixes #27559 fixes #28665
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - Bug fixes must be submitted against the lowest branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against the master branch.
-->

Commits
-------

c6009a0144 [Validator] deprecate checkMX and checkHost on Email validator
2018-10-12 15:49:26 -07:00
Fabien Potencier
8199809fe5 minor #26190 [SecurityBundle] Improve error when argon2i is not available (Coffee2CodeNL)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[SecurityBundle] Improve error when argon2i is not available

| Q             | A
| ------------- | ---
| Branch?       | master?
| Bug fix?      | yes
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass?   | ?
| Fixed tickets | ~
| License       | MIT
| Doc PR        | ~

Commits
-------

eb6436ac82 [SecurityBundle] Improve error when argon2i is not available
2018-10-12 15:48:32 -07:00
Nicolas Grekas
cfc3f254e7 Revert "feature #27801 [MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors (nicolas-grekas)"
This reverts commit f27c3a8584, reversing
changes made to 9da045469e.
2018-10-12 12:11:29 -07:00
Fabien Potencier
c6009a0144 [Validator] deprecate checkMX and checkHost on Email validator 2018-10-12 12:10:09 -07:00
Fabien Potencier
f0bcab5ac6 minor #28808 [HttpKernel] Add a note about env name restrictions (fabpot)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[HttpKernel] Add a note about env name restrictions

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26884
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - Bug fixes must be submitted against the lowest branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against the master branch.
-->

Commits
-------

b0f863d77e [HttpKernel] added a note about env name restrictions
2018-10-12 10:21:57 -07:00
Fabien Potencier
7d9ae2f6a6 minor #28841 Sync English translations (jakzal)
This PR was merged into the 2.8 branch.

Discussion
----------

Sync English translations

| Q             | A
| ------------- | ---
| Branch?       | 2.8
| Bug fix?      | no
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? |no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | https://github.com/symfony/symfony/pull/28828#issuecomment-429362737
| License       | MIT
| Doc PR        | -

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - Bug fixes must be submitted against the lowest branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against the master branch.
-->

Commits
-------

bb573524cb Add a missing English translation
2018-10-12 10:17:46 -07:00
ReScO
eb6436ac82 [SecurityBundle] Improve error when argon2i is not available 2018-10-12 18:18:41 +02:00
Fabien Potencier
bad48671a4 bug #27772 [Console] Fixes multiselect choice question defaults in non-interactive mode (veewee)
This PR was merged into the 2.8 branch.

Discussion
----------

[Console] Fixes multiselect choice question defaults in non-interactive mode

| Q             | A
| ------------- | ---
| Branch?       | >4.1.1
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

[This commit](41ffc69fa0) introduced a warning in multiselect mode:

```
PHP Notice:  Undefined index:  in /tmp/vendor/symfony/console/Helper/QuestionHelper.php on line 52
PHP Stack trace:
PHP   1. {main}() /tmp/vendor/phpro/grumphp/bin/grumphp:0
PHP   2. GrumPHP\Console\Application->run() /tmp/vendor/phpro/grumphp/bin/grumphp:31
PHP   3. GrumPHP\Console\Application->run() /tmp/vendor/phpro/grumphp/src/Console/Application.php:240
PHP   4. GrumPHP\Console\Application->doRun() /tmp/vendor/symfony/console/Application.php:145
PHP   5. GrumPHP\Console\Application->doRunCommand() /tmp/vendor/symfony/console/Application.php:262
PHP   6. GrumPHP\Console\Command\ConfigureCommand->run() /tmp/vendor/symfony/console/Application.php:904
PHP   7. GrumPHP\Console\Command\ConfigureCommand->execute() /tmp/vendor/symfony/console/Command/Command.php:251
PHP   8. GrumPHP\Console\Command\ConfigureCommand->buildConfiguration() /tmp/vendor/phpro/grumphp/src/Console/Command/ConfigureCommand.php:95
PHP   9. Symfony\Component\Console\Helper\QuestionHelper->ask() /tmp/vendor/phpro/grumphp/src/Console/Command/ConfigureCommand.php:156

Notice: Undefined index:  in /tmp/vendor/symfony/console/Helper/QuestionHelper.php on line 52
```

This PR fixes this issue by parsing the default value using the built-in validator if available. (which most likely is ...)

Commits
-------

099e265711 [Console] Fixes multiselect choice question in interactive mode with default values
2018-10-12 09:06:41 -07:00
Fabien Potencier
60aaa808c1 minor #28839 [LDAP] Revamp LDAP options with nested options definition (yceruto)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[LDAP] Revamp LDAP options with nested options definition

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Next move after https://github.com/symfony/symfony/pull/27291 :)

This will work exactly that before, nothing change regarding behavior, BUT now we've *less code* and *intuitive definition of nested options*.

Commits
-------

a26c284d2d Revamp LDAP options with nested definition
2018-10-12 09:03:12 -07:00
Fabien Potencier
4cd71b406c feature #28833 [Intl] Blacklist invalid languages (ro0NL)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Intl] Blacklist invalid languages

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes?
| New feature?  | yes?
| BC breaks?    | no?
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #...   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

see https://en.wikipedia.org/wiki/ISO_639-3#Special_codes

Commits
-------

4f5404bdcb [Intl] Blacklist invalid languages
2018-10-12 09:01:53 -07:00
Yonel Ceruto
a26c284d2d Revamp LDAP options with nested definition 2018-10-12 11:49:15 -04:00
Jakub Zalas
bb573524cb
Add a missing English translation 2018-10-12 16:17:55 +01:00
Toon Verwerft
099e265711 [Console] Fixes multiselect choice question in interactive mode with default values 2018-10-12 16:17:31 +02:00
Jakub Zalas
c1314b315e [Validator] Add a missing Polish translation 2018-10-12 07:07:32 -07:00
Fabien Potencier
f89ef42ba4 bug #28835 [FrameworkBundle] Setting missing default paths under BC layer (yceruto)
This PR was merged into the 3.4 branch.

Discussion
----------

[FrameworkBundle] Setting missing default paths under BC layer

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Commits
-------

18ac673dc2 Setting missing default paths under BC layer
2018-10-12 06:57:42 -07:00
Niels Keurentjes
064950a03f Allow integers as default console option value 2018-10-12 06:55:43 -07:00
Yonel Ceruto
18ac673dc2 Setting missing default paths under BC layer 2018-10-12 09:17:24 -04:00
Fabien Potencier
261c0dea91 minor #28830 'yml' is not a format and shouldn't be visible as constant from 'YamlEncoder' (kevin-biig)
This PR was merged into the 4.2-dev branch.

Discussion
----------

'yml' is not a format and shouldn't be visible as constant from 'YamlEncoder'

A little fix of my [previous PR](https://github.com/symfony/symfony/pull/28815)

This PR changes the constant visibility of the `yml` format as private.

Because as @stof [mentionned](https://github.com/symfony/symfony/pull/28815#issuecomment-428941972) `yml` isn't a format, so the constant  shoudn't be public.

Otherwise, this will be confusing while using autocomplete, you see two formats. The user can ask himself if there is a difference between `yaml` / `yml`.

No need of that :)

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Fixed tickets | -
| License       | MIT
| Doc PR        |

Commits
-------

674b359610 'yml' is not a format and shouldn't be visible as constant from 'YamlEncoder' class
2018-10-12 05:58:47 -07:00
Fabien Potencier
975f58f3a2 fixed typo in class name 2018-10-12 05:57:08 -07:00
Fabien Potencier
dd67a450f7 Merge branch '4.1'
* 4.1:
  Class should be case sensitive
  fixed CS
  [CS] Enable phpdoc_types_order
2018-10-12 05:56:18 -07:00
Fabien Potencier
7e0a369f73 Merge branch '3.4' into 4.1
* 3.4:
  Class should be case sensitive
  fixed CS
  [CS] Enable phpdoc_types_order
2018-10-12 05:56:03 -07:00
Nguyen Xuan Quynh
6a0ab51f1c Class should be case sensitive 2018-10-12 05:54:24 -07:00
Roland Franssen
4f5404bdcb [Intl] Blacklist invalid languages 2018-10-12 12:51:09 +02:00
Kevin Grenier
674b359610 'yml' is not a format and shouldn't be visible as constant from 'YamlEncoder' class 2018-10-12 10:13:44 +02:00
Christian Flothmann
91f6e69334 fix typo 2018-10-12 09:26:31 +02:00
Fabien Potencier
b399527ba1 feature #28815 YamlEncoder handle yml format (kevin-biig)
This PR was merged into the 4.2-dev branch.

Discussion
----------

YamlEncoder handle yml format

| Q             | A
| ------------- | ---
| Branch?       | ?
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #28768
| License       | MIT

`Symfony\Component\Serializer\Encoder\YamlEncoder` now handle the `yml` format too

```
use Symfony\Component\Serializer\Serializer;
use Symfony\Component\Serializer\Encoder\YamlEncoder;

$serializer = new Serializer([], [new YamlEncoder()]);
$content = file_get_contents(__DIR__ . '/test.yml');
$data = $serializer->decode($content, YamlEncoder::ALTERNATIVE_FORMAT);
```

Let me know if something is wrong for you

Commits
-------

d8640f965b YamlEncoder handle yml extension
2018-10-11 11:09:58 -07:00
Fabien Potencier
4a4fda5679 feature #27742 [Process] Add feature "wait until callback" to process class (Nek-)
This PR was squashed before being merged into the 4.2-dev branch (closes #27742).

Discussion
----------

[Process] Add feature "wait until callback" to process class

I often see code like the following:

```php
$process->start();
// wait for the process to be ready
sleep(3);
```

Many times in tests, sometimes in other places. There is a problem with this kind of code because if for any reason the process starts slower than the usual... Your code may fail after that. Also if it's faster, you're losing time for waiting.

So here is my proposal:

```php
$process->start();
$process->waitUntil(function($type, $output) {
    // check the output and return true to stop waiting when you got what you wait
});
```

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | none
| License       | MIT
| Doc PR        | Waiting for feedbacks

Commits
-------

27eaf83b63 [Process] Add feature \"wait until callback\" to process class
2018-10-11 10:22:46 -07:00
Maxime Veber
27eaf83b63 [Process] Add feature \"wait until callback\" to process class 2018-10-11 10:22:38 -07:00
Tobias Nyholm
91e36579b4 Changed "epost-adress" to "e-postadress" 2018-10-11 10:17:16 -07:00
Kevin Grenier
d8640f965b YamlEncoder handle yml extension 2018-10-11 15:09:10 +02:00
Fabien Potencier
80670fc0a7 Merge branch '2.8' into 3.4
* 2.8:
  fixed CS
  [CS] Enable phpdoc_types_order
2018-10-11 06:05:17 -07:00
Fabien Potencier
d48a3776fe fixed CS 2018-10-11 04:32:54 -07:00
Fabien Potencier
7cb823a5b6 minor #28811 Remove usage of sf2 when possible (fabpot)
This PR was merged into the 4.2-dev branch.

Discussion
----------

Remove usage of sf2 when possible

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

I've not removed all `sf2` occurrences as I've kept the ones that would introduce a BC break.

Commits
-------

8406ee86a9 removed usage of sf2 when possible
2018-10-11 03:53:47 -07:00
Rudolf Ratusiński
428dea6fb1 Fix for race condition in console output stream write 2018-10-11 17:13:12 +08:00
Fabien Potencier
8406ee86a9 removed usage of sf2 when possible 2018-10-10 12:30:04 -07:00
Fabien Potencier
620094a12c feature #28713 [Cache] added support for connecting to Redis clusters via DSN (nicolas-grekas)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Cache] added support for connecting to Redis clusters via DSN

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Replaces #28300 and #28175

This PR allows configuring a cluster of Redis servers using all available options of either the phpredis extension or the Predis package:
- the `redis_cluster=0/1` boolean option configures whether the client should use the Redis cluster protocol;
- several hosts can be provided using a syntax very similar to #28598, enabling consistent hashing distribution of keys;
- `failover=error/distribute/slaves` can be set to direct reads at slave servers;
- extra options are passed as is to the driver (e.g. `profile=2.8`)
- Predis per-server settings are also possible, using e.g. `host[localhost][alias]=foo` in the query string, or `host[localhost]=alias%3Dfoo` (ie PHP query arrays or urlencoded key/value pairs)

Commits
-------

a42e8774d6 [Cache] added support for connecting to Redis clusters via DSN
2018-10-10 12:22:21 -07:00
Fabien Potencier
b0f863d77e [HttpKernel] added a note about env name restrictions 2018-10-10 09:56:03 -07:00
Christian Flothmann
493c13a9fb Merge branch '4.1'
* 4.1:
  fix merge
2018-10-10 16:58:57 +02:00
Christian Flothmann
61cf143727 fix merge 2018-10-10 16:49:00 +02:00
Nicolas Grekas
8848a1aa30 Merge branch '4.1'
* 4.1: (27 commits)
  Added the Code of Conduct file
  do not override custom access decision configs
  [Security] Do not deauthenticate user when the first refreshed user has changed
  fix a return type hint
  invalidate stale commits for PRs too
  add missing cache prefix seed attribute to XSD
  fix command description
  Fix class documentation
  [Validator] Add a missing translation
  [FrameworkBundle] Fix 3.4 tests
  [DI] fix dumping inline services again
  Rename consumer to receiver
  Register messenger before the profiler
  Fix phpdocs
  [EventDispatcher] Remove template method in test case
  Added LB translation for #27993 (UUID validator message translation)
  Replace deprecated validateValue with validate
  [FWBundle] Automatically enable PropertyInfo when using Flex
  [Process] fix locking of pipe files on Windows
  Correct PHPDoc type for float ttl
  ...
2018-10-10 06:54:27 -07:00
Nicolas Grekas
d9c9e0cf52 Merge branch '3.4' into 4.1
* 3.4: (21 commits)
  Added the Code of Conduct file
  do not override custom access decision configs
  [Security] Do not deauthenticate user when the first refreshed user has changed
  invalidate stale commits for PRs too
  add missing cache prefix seed attribute to XSD
  fix command description
  Fix class documentation
  [Validator] Add a missing translation
  [FrameworkBundle] Fix 3.4 tests
  [DI] fix dumping inline services again
  Fix phpdocs
  [EventDispatcher] Remove template method in test case
  Added LB translation for #27993 (UUID validator message translation)
  Replace deprecated validateValue with validate
  [FWBundle] Automatically enable PropertyInfo when using Flex
  [Process] fix locking of pipe files on Windows
  Correct PHPDoc type for float ttl
  bumped Symfony version to 3.4.18
  updated VERSION for 3.4.17
  updated CHANGELOG for 3.4.17
  ...
2018-10-10 06:52:42 -07:00
Nicolas Grekas
a42e8774d6 [Cache] added support for connecting to Redis clusters via DSN 2018-10-10 06:45:03 -07:00
Nicolas Grekas
68e54f01cc bug #28760 [DI] fix dumping inline services again (nicolas-grekas)
This PR was merged into the 3.4 branch.

Discussion
----------

[DI] fix dumping inline services again

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #28720 #28710
| License       | MIT
| Doc PR        | -

The main fix is in `PhpDumper::addInlineService()`
Fixes a few other glitches found meanwhile.

Commits
-------

a854b0a01c [DI] fix dumping inline services again
2018-10-10 06:42:04 -07:00
Nicolas Grekas
af2938eac4 Merge branch '2.8' into 3.4
* 2.8:
  Added the Code of Conduct file
  [Process] fix locking of pipe files on Windows
  fix multi-digit seconds fraction handling
2018-10-10 06:41:17 -07:00
Fabien Potencier
9a37ba4ab1 bug #28805 Revert "feature #27549 [Cache] Unconditionally use PhpFilesAdapter for system pools" (nicolas-grekas)
This PR was merged into the 4.2-dev branch.

Discussion
----------

Revert "feature #27549 [Cache] Unconditionally use PhpFilesAdapter for system pools"

This reverts commit d4f5d46b13, reversing
changes made to 7e3b7b0b50.

| Q             | A
| ------------- | ---
| Branch?       | 4.2
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Reading #28800, I've just realized that #27549 breaks using system caches with read-only filesystem.
Using ApcuAdapter makes system caches compatible with read-only filesystems.
Note that this affects only non-warmed up pools, as the warmed-up ones use a faster `PhpArrayAdapter` in front.

Commits
-------

dbc1230735 Revert "feature #27549 [Cache] Unconditionally use PhpFilesAdapter for system pools (nicolas-grekas)"
2018-10-10 06:31:32 -07:00
Nicolas Grekas
4d70a0b7d4 [Finder] fix reverse sorting custom-ordering functions 2018-10-10 06:30:17 -07:00
Nicolas Grekas
dbc1230735 Revert "feature #27549 [Cache] Unconditionally use PhpFilesAdapter for system pools (nicolas-grekas)"
This reverts commit d4f5d46b13, reversing
changes made to 7e3b7b0b50.
2018-10-10 06:18:46 -07:00
Fabien Potencier
0ea1adf3cc minor #28798 [Routing] simplify PhpMatcherDumper by splitting code logic from route data (nicolas-grekas)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Routing] simplify PhpMatcherDumper by splitting code logic from route data

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

This PR splits all logic that is currently dumped into the matcher in a dedicated trait.
This makes the code easier to maintain and prepares for the next step (making the dumper compile routes as a set of PHP arrays instead of code.)

This diff is huge because affected fixtures are also huge, but it's negative, removing 1200 lines!

Commits
-------

22186c7045 [Routing] simplify PhpMatcherDumper by splitting code logic from route data
2018-10-10 05:51:58 -07:00
Vincent Chalamon
4503ac8e9f
Convert InsufficientAuthenticationException to HttpException 2018-10-10 14:45:47 +02:00
Roland Franssen
8f88753381 Filter logs by level 2018-10-10 05:43:48 -07:00
Fabien Potencier
61d336b4ca feature #24151 Display the log context in the debug pages (javiereguiluz)
This PR was squashed before being merged into the 4.2-dev branch (closes #24151).

Discussion
----------

Display the log context in the debug pages

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #23589
| License       | MIT
| Doc PR        | -

### Before

![before](https://user-images.githubusercontent.com/73419/30269760-564ff2e8-96ea-11e7-98fa-0610d6a0322f.png)

### After

![after](https://user-images.githubusercontent.com/73419/30269764-5830482e-96ea-11e7-946a-a6805c28741a.png)

I'd like to exclude the `event` channel context because it only adds noise:

![event-noise](https://user-images.githubusercontent.com/73419/30269774-67036f52-96ea-11e7-87c0-5ef8328f315a.png)

-----

This change would require to add a hard dependency to the VarDumper component. Do we want to do that? Thanks!

Commits
-------

c59fbde74b Display the log context in the debug pages
2018-10-10 05:31:32 -07:00
Javier Eguiluz
c59fbde74b Display the log context in the debug pages 2018-10-10 05:31:23 -07:00
Fabien Potencier
722c8162c9 feature #26261 [Validator] Improvement: provide file basename for constr. violation messages in FileValidator. (TheCelavi)
This PR was squashed before being merged into the 4.2-dev branch (closes #26261).

Discussion
----------

[Validator] Improvement: provide file basename for constr. violation messages in FileValidator.

| Q             | A
| ------------- | ---
| Branch?       | 3.4 <!-- see below -->
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | no
| License       | MIT
| Doc PR        | N/A

`\Symfony\Component\Validator\Constraints\FileValidator` provides absolute path to file on server when user, per example, uploads empty file, too large file, of wrong mime type, etc...

Absolute path to file on server does not have value to the end user, on top of that, exposing it can be a security issue - end user should not be aware of server filesystem.

Basename of file, however, has value (per example: MyAwesomeSheet.xlsx, MyCV.doc, etc..) - if something is wrong with file upload (size, mime, etc...).

If basename is exposed, we can construct messages like: "Your file 'MyCV.doc' is not allowed for upload due to....whatever"...

This PR provides basename of file so end user of `\Symfony\Component\Validator\Constraints\FileValidator` can construct error messages of higher value for end user.

Commits
-------

a77abadf06 [Validator] Improvement: provide file basename for constr. violation messages in FileValidator.
2018-10-10 05:29:04 -07:00
Nikola Svitlica a.k.a. TheCelavi
a77abadf06 [Validator] Improvement: provide file basename for constr. violation messages in FileValidator. 2018-10-10 05:28:53 -07:00
Nicolas Grekas
ce861d1861 [Finder] make reverse sorting a bit more generic 2018-10-10 05:18:16 -07:00
Nicolas Grekas
22186c7045 [Routing] simplify PhpMatcherDumper by splitting code logic from route data 2018-10-10 04:44:04 -07:00