Commit Graph

29441 Commits

Author SHA1 Message Date
Fabien Potencier
3193331855 feature #21474 [Process] Accept command line arrays and per-run env vars, fixing signaling and escaping (nicolas-grekas)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[Process] Accept command line arrays and per-run env vars, fixing signaling and escaping

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | #12488, #11972, #10025, #11335, #5759, #5030, #19993, #10486
| License       | MIT
| Doc PR        | -

I think I found a way to fix this network of issues once for all.
Of all the linked ones, only the last two are still open: the remaining were closed in dead ends.

Instead of trying to make `ProcessUtil::escapeArgument` work correctly on Windows - which is impossible as discussed in #21347 - this PR deprecates it in favor of a more powerful approach.

Depending on the use case:

- when a simple command should be run, `Process` now accepts an array of arguments (the "binary" being the first arg). Making this the responsibility of `Process` (instead of `ProcessBuilder`) gives two benefits:
  - escape becomes an internal detail that doesn't leak - thus can't be misused ([see here](https://github.com/symfony/symfony/pull/21347#issuecomment-274051370))
  - since we know we're running a single command, we can prefix it automatically by "exec" - thus fixing a long standing issue with signaling

```php
        $p = new Process(array('php', '-r', 'echo 123;'));
        echo $p->getCommandLine();
        // displays on Linux:
        // exec 'php' '-r' 'echo 123;'
```

- when a shell expression is required, passing a string is still allowed. To make it easy and look-like sql prepared statements, env vars can be used when running the command. Since the shell is OS-specific (think Windows vs Linux) - this PR assumes no portability, so one should just use each shell's specific syntax.

From the fixtures:
```php
        $env = array('FOO' => 'Foo', 'BAR' => 'Bar');
        $cmd = '\\' === DIRECTORY_SEPARATOR ? 'echo !FOO! !BAR! !BAZ!' : 'echo $FOO $BAR $BAZ';
        $p = new Process($cmd, null, $env);
        $p->run(null, array('BAR' => 'baR', 'BAZ' => 'baZ'));

        $this->assertSame('Foo baR baZ', rtrim($p->getOutput()));
        $this->assertSame($env, $p->getEnv());
```

Commits
-------

330b61fecb [Process] Accept command line arrays and per-run env vars, fixing signaling and escaping
2017-02-08 16:45:40 +01:00
Fabien Potencier
2697ceecf7 minor #21561 [DI] Refacto / cleanup / minor fixes (nicolas-grekas)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[DI] Refacto / cleanup / minor fixes

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

An almost neutral refacto touching only new things in master - unlocking some next steps.

- renames "autowire method" to "autowire call"
- renames `GetterProxyInterface` to `InheritanceProxyInterface`
- moves some helpers in a new internal `InheritanceProxyHelper`
- some other minor things

Commits
-------

ad5b5b5d93 [DI] Refacto / cleanup / minor fixes
2017-02-08 16:44:35 +01:00
Nicolas Grekas
ad5b5b5d93 [DI] Refacto / cleanup / minor fixes 2017-02-08 13:32:07 +01:00
Fabien Potencier
554b1a748f Merge branch '3.2'
* 3.2:
  [Form] fixed tests
2017-02-06 13:27:36 +01:00
Fabien Potencier
6516a20e11 Merge branch '2.8' into 3.2
* 2.8:
  [Form] fixed tests
2017-02-06 13:27:26 +01:00
Fabien Potencier
9650b50436 [Form] fixed tests 2017-02-06 13:27:13 +01:00
Fabien Potencier
6ccdcdc330 Merge branch '3.2'
* 3.2:
  Remove 3.1 from PR template
  fixed test name
  [Cache] Fix class exists checks in PhpArrayAdapter
  Casting TableCell value to string.
  [FrameworkBundle] fixed custom domain for translations in php templates
  [Form] Fixed DateType format option
  [Config] Fix checking cache for non existing meta file
2017-02-06 13:04:42 +01:00
Fabien Potencier
cfc6bafed2 Merge branch '2.8' into 3.2
* 2.8:
  Remove 3.1 from PR template
  fixed test name
  Casting TableCell value to string.
  [FrameworkBundle] fixed custom domain for translations in php templates
  [Form] Fixed DateType format option
  [Config] Fix checking cache for non existing meta file
2017-02-06 13:04:21 +01:00
Fabien Potencier
47a8b4dc58 Merge branch '2.7' into 2.8
* 2.7:
  Remove 3.1 from PR template
  fixed test name
  Casting TableCell value to string.
  [FrameworkBundle] fixed custom domain for translations in php templates
  [Form] Fixed DateType format option
2017-02-06 13:04:06 +01:00
Nicolas Grekas
081f7b4f18 bug #21528 [Cache] Fix class exists checks in PhpArrayAdapter (nicolas-grekas)
This PR was merged into the 3.2 branch.

Discussion
----------

[Cache] Fix class exists checks in PhpArrayAdapter

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

Fixes HHVM, as spotted in #21527

Commits
-------

44e5989 [Cache] Fix class exists checks in PhpArrayAdapter
2017-02-05 11:19:28 +01:00
Nicolas Grekas
a736458fb5 bug #21527 [Config] Fix conditional class existence checks (nicolas-grekas)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[Config] Fix conditional class existence checks

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

Commits
-------

686af61 [Config] Fix conditional class existence checks
2017-02-05 11:14:32 +01:00
Nicolas Grekas
6ac1223eca bug #20844 [Config] Fix checking cache for non existing meta file (hason)
This PR was merged into the 2.8 branch.

Discussion
----------

[Config] Fix checking cache for non existing meta file

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

Commits
-------

17f02e0 [Config] Fix checking cache for non existing meta file
2017-02-05 11:11:19 +01:00
Nicolas Grekas
c98832b99b minor #21532 Remove 3.1 from PR template (chalasr)
This PR was merged into the 2.7 branch.

Discussion
----------

Remove 3.1 from PR template

| Q             | A
| ------------- | ---
| Branch?       | 2.7

Commits
-------

57f67e8 Remove 3.1 from PR template
2017-02-05 10:56:15 +01:00
Robin Chalas
57f67e834b
Remove 3.1 from PR template 2017-02-04 19:24:41 +01:00
Fabien Potencier
ad8f18963e fixed test name 2017-02-04 08:36:32 -08:00
Fabien Potencier
1d1f1666e7 bug #21063 [Form] Fixed DateType format option for single text widget (HeahDude)
This PR was merged into the 2.7 branch.

Discussion
----------

[Form] Fixed DateType format option for single text widget

| 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        | ~

It's currently not possible to use a custom format with `DateType` when not using one of the three values day, month or year (i.e in my case "MM/yyyy").

The formatter handles it, it looks like this option check is wrong, this PR fixes it.

Commits
-------

9e0d531d36 [Form] Fixed DateType format option
2017-02-04 08:34:51 -08:00
Nicolas Grekas
686af613aa [Config] Fix conditional class existence checks 2017-02-04 09:30:42 +01:00
Nicolas Grekas
44e5989850 [Cache] Fix class exists checks in PhpArrayAdapter 2017-02-04 09:30:23 +01:00
Fabien Potencier
ed6a2ed3eb minor #21522 [SecurityBundle] Add AutowiringTypesTest (chalasr)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[SecurityBundle] Add AutowiringTypesTest

| Q             | A
| ------------- | ---
| Branch?       | master
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/21517#discussion_r99351908
| License       | MIT

Commits
-------

d1001d4bac [SecurityBundle] Add AutowiringTypesTest
2017-02-03 13:28:46 -08:00
Fabien Potencier
f0d13f4708 bug #21430 Casting TableCell value to string. (jaydiablo)
This PR was squashed before being merged into the 2.7 branch (closes #21430).

Discussion
----------

Casting TableCell value to string.

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

PHP throws a catchable fatal error when the value from this method is
used in strstr in the Table class. This fixes the error by casting to a string before returning the value.

Commits
-------

1e5707fed3 Casting TableCell value to string.
2017-02-03 13:25:39 -08:00
Jay Klehr
1e5707fed3 Casting TableCell value to string. 2017-02-03 13:25:34 -08:00
Fabien Potencier
ff33768eda bug #21359 [FrameworkBundle] fixed custom domain for translations in php templates (robinlehrmann)
This PR was merged into the 2.7 branch.

Discussion
----------

[FrameworkBundle] fixed custom domain for translations in php templates

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

Commits
-------

78c0ec5c13 [FrameworkBundle] fixed custom domain for translations in php templates
2017-02-03 08:29:55 -08:00
Robin Chalas
d1001d4bac [SecurityBundle] Add AutowiringTypesTest 2017-02-03 16:32:53 +01:00
Robin Lehrmann
78c0ec5c13 [FrameworkBundle] fixed custom domain for translations in php templates 2017-02-03 15:56:44 +01:00
Fabien Potencier
7c5dcfcdb8 minor #21521 [SecurityBundle] Remove FirewallMap from classes to compile (chalasr)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[SecurityBundle] Remove FirewallMap from classes to compile

| Q             | A
| ------------- | ---
| Branch?       | master
| Tests pass?   | yes
| Fixed tickets | #21520
| License       | MIT

Commits
-------

d1091091ef [SecurityBundle] Remove FirewallMap from classes to compile
2017-02-03 06:48:44 -08:00
Fabien Potencier
da2710e400 feature #21517 [FrameworkBundle] Add missing autowiring aliases for common interfaces (chalasr)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[FrameworkBundle] Add missing autowiring aliases for common interfaces

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

Commits
-------

c3a2141a45 [FrameworkBundle] Add more autowiring aliases
2017-02-03 06:46:45 -08:00
Nicolas Grekas
23ba91272f Merge branch '3.2'
* 3.2:
  [FrameworkBundle][Console] JsonDescriptor: Respect original output
  [Process] Non ASCII characters disappearing during the escapeshellarg
2017-02-03 13:20:42 +01:00
Robin Chalas
d1091091ef [SecurityBundle] Remove FirewallMap from classes to compile 2017-02-03 13:17:59 +01:00
Nicolas Grekas
d5a95323da Merge branch '2.8' into 3.2
* 2.8:
  [FrameworkBundle][Console] JsonDescriptor: Respect original output
  [Process] Non ASCII characters disappearing during the escapeshellarg
2017-02-03 13:11:38 +01:00
Nicolas Grekas
151fe329d0 Merge branch '2.7' into 2.8
* 2.7:
  [Process] Non ASCII characters disappearing during the escapeshellarg
2017-02-03 13:08:06 +01:00
Nicolas Grekas
a43e1832bf minor #21515 [FrameworkBundle][Console] JsonDescriptor: Respect original output (ogizanagi)
This PR was merged into the 2.8 branch.

Discussion
----------

[FrameworkBundle][Console] JsonDescriptor: Respect original output

| 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

Follows up #21501.

This one fixes the keys order (preserved from the order those keys are added from the `JsonDescriptor`), as for the previous mentioned PR, in order to slightly improve the situation when updating the descriptors fixtures.

@nicolas-grekas : Thanks for taking care of the previous one. There are two other PRs required to me in order to fix everything on every branches, but I wonder if it wouldn't be easier (and reduce noise) to apply the following patches while merging this in upper branches instead:

- 3.2: 51a0a1c25d
- master: b35a244249

WDYT?

Commits
-------

bf71776 [FrameworkBundle][Console] JsonDescriptor: Respect original output
2017-02-03 13:07:20 +01:00
Robin Chalas
c3a2141a45 [FrameworkBundle] Add more autowiring aliases 2017-02-03 10:29:29 +01:00
Fabien Potencier
a46e691ae1 minor #21499 [FrameworkBundle][Console] Fix descriptors to support IteratorArgument, ClosureProxy and arrays (ogizanagi)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[FrameworkBundle][Console] Fix descriptors to support IteratorArgument, ClosureProxy and arrays

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

Fixes both array and iterator/closure-proxy arguments support in descriptors when using `--show-arguments`

Commits
-------

a94924c540 [FrameworkBundle][Console] Fix descriptors to support IteratorArgument, ClosureProxy and arrays
2017-02-02 15:06:10 -08:00
Maxime Steinhausser
a94924c540 [FrameworkBundle][Console] Fix descriptors to support IteratorArgument, ClosureProxy and arrays 2017-02-02 21:16:35 +01:00
Fabien Potencier
2e13d4efa6 feature #21516 [HttpKernel][FrameworkBundle] Lazy load argument value resolvers (chalasr)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[HttpKernel][FrameworkBundle] Lazy load argument value resolvers

| 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

The ArgumentResolver resolves an arg using the first ArgumentValueResolver which `supports()` it (which can be complex, see e.g. [sensiolabs/SensioFrameworkExtraBundle#436](https://github.com/sensiolabs/SensioFrameworkExtraBundle/pull/436/files#diff-865d48d9369c4431bce36ba642834570R10)).

Commits
-------

02b4aaa25f [HttpKernel] Lazy load argument value resolvers
2017-02-02 11:44:56 -08:00
Fabien Potencier
b50efa5006 feature #21031 [DI] Getter autowiring (dunglas)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[DI] Getter autowiring

| 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        | todo

This PR adds support for getter autowiring. #20973 must be merged first.

Example:

```yaml
# app/config/config.yml

services:
    Foo\Bar:
        autowire: ['get*']
```

```php
namespace Foo;

class Bar
{
    protected function getBaz(): Baz // this feature only works with PHP 7+
    {
    }
}

class Baz
{
}
````

`Baz` will be automatically registered as a service and an instance will be returned when `Bar::getBaz` will be called (and only at this time, lazy loading).

This feature requires PHP 7 or superior.

Commits
-------

c48c36be8f [DI] Add support for getter autowiring
2017-02-02 11:39:35 -08:00
Kévin Dunglas
c48c36be8f [DI] Add support for getter autowiring 2017-02-02 20:37:38 +01:00
Robin Chalas
02b4aaa25f
[HttpKernel] Lazy load argument value resolvers 2017-02-02 20:36:37 +01:00
Fabien Potencier
03b7cf72dc feature #21419 [DI][Config] Add & use ReflectionClassResource (nicolas-grekas)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[DI][Config] Add & use ReflectionClassResource

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

With new changes comming to 3.3, we need a more generic reflection tracking logic than the one already managed by the autowiring subsystem.

This PR adds a new ReflectionClassResource in the Config component, and a new ContainerBuilder::getReflectionClass() method in the DI one (for fetching+tracking reflection-related info).

ReflectionClassResource tracks changes to any public or protected properties/method.

PR updated and ready, best viewed [ignoring whitespaces](https://github.com/symfony/symfony/pull/21419/files?w=1).

changelog:

* added `ReflectionClassResource` class
* added second `$exists` constructor argument to `ClassExistenceResource` - with a special mode that prevents fatal errors from happening when some parent class is broken (logic generalized from AutowiringPass)
* made `ClassExistenceResource` also work with interfaces and traits
* added `ContainerBuilder::getReflectionClass()` for retrieving and tracking reflection class info
* deprecated `ContainerBuilder::getClassResource()`, use `ContainerBuilder::getReflectionClass()` or `ContainerBuilder::addObjectResource()` instead

Commits
-------

37e44939ef [DI][Config] Add & use ReflectionClassResource
2017-02-02 10:28:05 -08:00
Maxime Steinhausser
bf71776e20 [FrameworkBundle][Console] JsonDescriptor: Respect original output 2017-02-02 18:43:33 +01:00
Fabien Potencier
87273d9f44 minor #21407 [WebServerBundle] Improved exception message (wouterj)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[WebServerBundle] Improved exception message

| 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 is a quite minor one, but imo "guessing" is something that's optional. If I don't pass value X, a script will guess value X. However, in this case, the front controller file cannot be specified. It has to be one of the "guessed" file names. That's why I renamed "guessing" to "finding".

While doing this, I also added the possible file names in the exception message to ease fixing problems.

Commits
-------

df46188381 Improved exception message
2017-02-02 07:29:17 -08:00
Nicolas Grekas
caba97a62b feature #21455 [DI] Allow to count on lazy collection arguments (ogizanagi)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[DI] Allow to count on lazy collection arguments

| 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/21450#issuecomment-275931764
| License       | MIT
| Doc PR        | todo (with https://github.com/symfony/symfony-docs/issues/7336)

When using the new iterator feature of the DI component to lazy load collection, we always know the number of arguments in the collection (only the invalidBehavior set to `IGNORE_ON_INVALID_REFERENCE` may change this number). So we are able to generate and use a `RewindableGenerator` implementing `\Countable` by computing this value ahead.

So, in a service accepting `array|iterable`, like in the `GuardAuthenticationListener` (see #21450):

```php
class GuardAuthenticationListener implements ListenerInterface
{
    private $guardAuthenticators;

    /**
       * @param iterable|GuardAuthenticatorInterface[]  $guardAuthenticators   The authenticators, with keys that match what's passed to GuardAuthenticationProvider
       * @param LoggerInterface                         $logger                A LoggerInterface instance
    */
    public function __construct($guardAuthenticators, LoggerInterface $logger = null)
    {
          // ...
    }

    public function handle(GetResponseEvent $event)
    {
        if (null !== $this->logger) {
            $context = array()
            if (is_array($this->guardAuthenticators) || $this->guardAuthenticators instanceof \Countable) {
                $context['authenticators'] = count($this->guardAuthenticators);
            }
            $this->logger->debug('Checking for guard authentication credentials.', $context);
        }
        // ...
    }
}
```

we still keep the ability to call count without loosing the lazy load benefits.

Commits
-------

f23e460 [DI] Allow to count on lazy collection arguments
2017-02-02 15:11:42 +01:00
Nicolas Grekas
01a0250d49 bug #21485 [Process] Non ASCII characters disappearing during the escapeshellarg (GuillaumeVerdon)
This PR was submitted for the 3.2 branch but it was merged into the 2.7 branch instead (closes #21485).

Discussion
----------

[Process] Non ASCII characters disappearing during the escapeshellarg

If the LC_CTYPE is not set at UTF-8, the escapeshellarg() function will remove every non-ascii characters.

As it's usual in europe to have directories with non-ascii chars in their name (ex : ~/Vidéos) the function should throw an exception if we're trying to submit it an argument containing non-ascii param and the LC_CTYPE is not set to use UTF-8

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

I had this issue while using the lib ffmpeg and giving it a path like "~/Vidéos" the "é" chars was disappearing from the command giving a RuntimeException.

The problem was my LC_CTYPE that wasn't set properly, I believe an exception should be raised before the RuntimeException to warn the user of that behavior

Commits
-------

3779f3f [Process] Non ASCII characters disappearing during the escapeshellarg
2017-02-02 14:55:53 +01:00
GuillaumeVerdon
3779f3fbb9 [Process] Non ASCII characters disappearing during the escapeshellarg 2017-02-02 14:55:53 +01:00
Nicolas Grekas
55a34b7b51 Merge branch '3.2'
* 3.2:
  Add HEADER_FORWARDED to setTrustedHeaderName docs
  Fix phpDoc typo
  [FrameworkBundle][Console] JsonDescriptor: Respect original output
  Remove dead code
  Enable dump() in autoload-dev
  add missing functional Serializer test case
2017-02-02 14:49:58 +01:00
Nicolas Grekas
4fd91481c2 Merge branch '2.8' into 3.2
* 2.8:
  Add HEADER_FORWARDED to setTrustedHeaderName docs
  Fix phpDoc typo
  [FrameworkBundle][Console] JsonDescriptor: Respect original output
  Enable dump() in autoload-dev
2017-02-02 14:47:35 +01:00
Nicolas Grekas
0a6d3c6d00 Merge branch '2.7' into 2.8
* 2.7:
  Add HEADER_FORWARDED to setTrustedHeaderName docs
  Fix phpDoc typo
  [FrameworkBundle][Console] JsonDescriptor: Respect original output
  Enable dump() in autoload-dev
2017-02-02 14:38:20 +01:00
Nicolas Grekas
3ee1aa0160 minor #21501 [FrameworkBundle][Console] JsonDescriptor: Respect original output (ogizanagi)
This PR was merged into the 2.7 branch.

Discussion
----------

[FrameworkBundle][Console] JsonDescriptor: Respect original output

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

I'm suggesting this one, because I recently pushed some changes to the descriptors, and of course, I'm not editing expected output fixtures by hand, but by dumping the real output to fixture files. But it's tiring to get false positive diffs when reviewing it. Descriptor tests already are painful enough 😅

This PR respects the way elements are actually output. If it's ok to you, I'll submit some other PRs to upper branches, because there are more issues regarding this (items order for instance).

If it causes too much troubles getting this in sync with upper branches, let's close this and never talk about it anymore 😄

Commits
-------

08dd70b [FrameworkBundle][Console] JsonDescriptor: Respect original output
2017-02-02 14:32:11 +01:00
Nicolas Grekas
b182088ca2 minor #21495 Add HEADER_FORWARDED to setTrustedHeaderName docs (pascal-hofmann)
This PR was submitted for the master branch but it was merged into the 2.7 branch instead (closes #21495).

Discussion
----------

Add HEADER_FORWARDED to setTrustedHeaderName docs

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

<!--
- Bug fixes must be submitted against the lowest branch where they apply
  (lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
- Please fill in this template according to the PR you're about to submit.
- Replace this comment by a description of what your PR is solving.
-->

Commits
-------

b46276e Add HEADER_FORWARDED to setTrustedHeaderName docs
2017-02-02 14:27:35 +01:00
Pascal Hofmann
b46276e9b2 Add HEADER_FORWARDED to setTrustedHeaderName docs 2017-02-02 14:27:35 +01:00