Commit Graph

27526 Commits

Author SHA1 Message Date
Fabien Potencier
47657e55d2 feature #19197 [Serializer][FrameworkBundle] Add a CSV encoder (dunglas)
This PR was squashed before being merged into the 3.2-dev branch (closes #19197).

Discussion
----------

[Serializer][FrameworkBundle] Add a CSV encoder

| 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

Usage:

```php
use Symfony\Component\Serializer\Serializer;
use Symfony\Component\Serializer\Encoder\CsvEncoder;
use Symfony\Component\Serializer\Normalizer\ObjectNormalizer;

$serializer = new Serializer(array(new ObjectNormalizer()), array(new CsvEncoder()));
// or $serializer = $container->get('serializer'); when using the full stack framework
$serializer->encode($something, 'csv');
$serializer->decode(<<<'CSV'
id,name
1,Kévin
CSV
, 'csv');
```

CSV files must contain a header line with property names as keys.

ping @clementtalleu @Simperfit @gorghoa

Commits
-------

e71f5be [Serializer][FrameworkBundle] Add a CSV encoder
2016-09-14 15:14:31 -07:00
Kévin Dunglas
e71f5bea96 [Serializer][FrameworkBundle] Add a CSV encoder 2016-09-14 15:10:23 -07:00
Fabien Potencier
d2a7994a2d feature #19257 [Validator][Choice] Make strict the default option for choice validation (peterrehm)
This PR was squashed before being merged into the 3.2-dev branch (closes #19257).

Discussion
----------

[Validator][Choice] Make strict the default option for choice validation

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

This is just the WIP as there are two options.

1. Just change default which would only possible to introduce in 4.x or in 3.2 if this BC break is considered as acceptable

2. Add a new option e.g. `strictComparison` which defaults to true in 4.x and deprecate the usage of the strict option for 3.2.

3. Just deprecate strict = false and remove the option but I would be against that as we remove flexibility which might be wanted.

As per discussion I went ahead with option 3. We can then still decide if we want to remove the option entirely or eventually reenable setting strict to false in a later release.

Commits
-------

177c513 [Validator][Choice] Make strict the default option for choice validation
2016-09-14 15:04:04 -07:00
Peter Rehm
177c513ece [Validator][Choice] Make strict the default option for choice validation 2016-09-14 15:03:11 -07:00
Fabien Potencier
d6d6a47fcf feature #19326 [Serializer][FrameworkBundle] Add a YAML encoder (dunglas)
This PR was squashed before being merged into the 3.2-dev branch (closes #19326).

Discussion
----------

[Serializer][FrameworkBundle] Add a YAML encoder

| 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

Add YAML support to the Serializer.

Commits
-------

9366a7d [Serializer][FrameworkBundle] Add a YAML encoder
2016-09-14 14:57:14 -07:00
Kévin Dunglas
9366a7dc77 [Serializer][FrameworkBundle] Add a YAML encoder 2016-09-14 14:57:11 -07:00
Fabien Potencier
fa18a4f8a0 feature #19484 [PropertyInfo] Extract the logic converting a php doc to a Type (Ener-Getick)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[PropertyInfo] Extract the logic converting a php doc to a Type

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

This PR creates a new trait `PhpDocTypeHelperTrait` extracting some logic of the `PhpDocExtractor`.
I would like to detect the return type of some methods but this is not easily doable as I have to transform the doc types to a ``Type`` instance.

Is this ok for you ?

Commits
-------

d6e93d8 [PropertyInfo] Extract the logic converting a php doc to a Type in PhpDocTypeHelperTrait
2016-09-14 14:44:37 -07:00
Fabien Potencier
a5108f42bd feature #19495 [master][console] Allow multiple options to be set. (SpacePossum)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[master][console] Allow multiple options to be set.

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

This PR add the possibility to set multiple options on a formatted string output.
Example:
```php
$output->writeln('<fg=green;options=bold,underscore>Test</>');
```

Secondly it makes the behavior on invalid values consistent.
```php
// current
$output->writeln('<fg=lime;>Test</>'); // throws exception
$output->writeln('<options=italic;>Test</>'); // silent ignore

// new
$output->writeln('<fg=lime;>Test</>'); // throws exception
$output->writeln('<options=italic;>Test</>'); // throws exception
```

All other changes are about making the code more strict or other SCA/CS fixes.

Commits
-------

1430138 Allow multiple options to be set.
2016-09-14 14:39:10 -07:00
Fabien Potencier
0e63f4796d feature #19584 [DependencyInjection] Improve ParameterNotFoundException when accessing a nested parameter (wouterj)
This PR was squashed before being merged into the 3.2-dev branch (closes #19584).

Discussion
----------

[DependencyInjection] Improve ParameterNotFoundException when accessing a nested parameter

| 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

A common problem under beginners is to think that the dot notation is used to access nested arrays saved in parameters (*common here means someone asks help for this problem at least once a week on IRC*). Adding a little extra detail to the exception message and a working alternative should help pointing these people in the right direction before spending time debugging this.

It's quite late in the night over here, so the wording of the exception message probably isn't great. I'm happy to accept better suggestions 😃

Commits
-------

df70f06 [DependencyInjection] Improve ParameterNotFoundException when accessing a nested parameter
2016-09-14 14:30:35 -07:00
WouterJ
df70f0622f [DependencyInjection] Improve ParameterNotFoundException when accessing a nested parameter 2016-09-14 14:25:50 -07:00
Fabien Potencier
68737ebbf3 feature #19485 [FrameworkBundle] Introduce a cache warmer for Validator based on PhpArrayAdapter (tgalopin)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[FrameworkBundle] Introduce a cache warmer for Validator based on PhpArrayAdapter

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

Following the cache warmer for annotations PR (https://github.com/symfony/symfony/pull/18533), this PR introduces a cache warmer for YAML and XML Validator configuration.

Based on the PhpArrayAdapter, it uses the naming conventions (`Resources/config/validation`) to find the files and compile them into a single PHP file stored in the cache directory. This file uses shared memory on PHP 7.

The benefit of this PR are the same than the ones of the annotations PR:

- validation configuration can be warmed up offline
- on PHP 7, there is no need for user extension to get maximum performances (ie. if you use this PR and the other one, you probably won't need to enable APCu to have great performances)
- on PHP 7 again, we are not sensitive to APCu memory fragmentation
- last but not least, global performance is slightly better (I get 30us per class gain in Blackfire)

This PR also deprecates the framework.validator.cache key in favor of the cache pool introduced in https://github.com/symfony/symfony/pull/18544.

Commits
-------

6bdaf0b [FrameworkBundle] Introduce a cache warmer for Validator based on PhpArrayAdapter
2016-09-14 14:10:29 -07:00
Fabien Potencier
3416f2128d feature #19790 [FrameworkBundle] add support for prioritizing form type extension tags (dmaicher)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[FrameworkBundle] add support for prioritizing form type extension tags

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

This PR proposes to add support for `priority` on `form.type_extension` dependecyinjection tags to enable sorting/prioritizing form type extensions.

Issue was mentioned here: https://github.com/symfony/symfony/issues/19735

Commits
-------

a3db5f0 [FrameworkBundle] add support for prioritizing form type extension tags
2016-09-14 14:07:36 -07:00
Fabien Potencier
b28cd81575 added a comment about a workaround 2016-09-14 14:04:40 -07:00
Fabien Potencier
23cae581b8 bug #19636 [Finder] no PHP warning on empty directory iteration (ggottwald)
This PR was squashed before being merged into the 2.7 branch (closes #19636).

Discussion
----------

[Finder] no PHP warning on empty directory iteration

| 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        | Since RecursiveDirectoryIterator::SKIP_DOTS is set as flag, opendir gets a warning if an empty directory is reached

Commits
-------

695e341 [Finder] no PHP warning on empty directory iteration
2016-09-14 14:03:47 -07:00
Götz Gottwald
695e341258 [Finder] no PHP warning on empty directory iteration 2016-09-14 14:03:47 -07:00
Fabien Potencier
46dd1d5719 feature #19507 [FrameworkBundle] Introduce a cache warmer for Serializer based on PhpArrayAdapter (tgalopin)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[FrameworkBundle] Introduce a cache warmer for Serializer based on PhpArrayAdapter

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

Following the cache warmer for annotations (#18533) and for the validator (#19485), this PR introduces a cache warmer for the Serializer YAML and XML metadata configuration (mainly groups).

Based on the PhpArrayAdapter, it uses the naming conventions (Resources/config/serialization) to find the files and compile them into a single PHP file stored in the cache directory. This file uses shared memory on PHP 7.

The benefit of this PR are the same than the ones of the previous PR:

- serialization metadata cache can be warmed up offline
- on PHP 7, there is no need for user extension to get maximum performances (ie. if you use this PR and the other one, you probably won't need to enable APCu to have great performances)
- on PHP 7 again, we are not sensitive to APCu memory fragmentation
last but not least, global performance is slightly better (I get 30us per class gain in Blackfire)

As previous work on the Serializer cache system introduced issues (see 96e418a14f), it would be interesting to pay careful attention to the backward compatibility during the review (ping @Ener-Getick).

Commits
-------

810f469 [FrameworkBundle] Introduce a cache warmer for Serializer based on PhpArrayAdapter
2016-09-14 13:50:36 -07:00
Fabien Potencier
65e254c2fe feature #19734 [HttpFoundation] Deprecate extending some methods (Ener-Getick)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[HttpFoundation] Deprecate extending some methods

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

It's really hard to change methods signature because of bc. I'm proposing to deprecate extending some getters/setters of `Response` because of this (and because extending them is not really useful).
If you like this approach it could be used in other places to simplify bc in 4.0.

Edit: This causes issues (warnings always triggered) when mocking `Response` entirely but does it matter as people should only mock needed methods?

Commits
-------

c0a26bc [HttpFoundation] Deprecate extending some methods
2016-09-14 13:47:40 -07:00
Fabien Potencier
4053283383 feature #19795 Replace %count% with a given number out of the box (bocharsky-bw)
This PR was squashed before being merged into the 3.2-dev branch (closes #19795).

Discussion
----------

Replace %count% with a given number out of the box

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

We already have this feature for [transchoice](https://github.com/symfony/symfony/blob/master/src/Symfony/Bridge/Twig/Extension/TranslationExtension.php#L98) Twig filter, but why only for it? It will be consistent to have this for translator in general. We already have a `$number` parameter in `transChoice()` which we could easily use for that.

Before
```php
$this->get('translator')
    ->transChoice('1 apple|%count% apples', 7, [
        '%count%' => 7,
    ]);
```

After:
```php
$this->get('translator')
    ->transChoice('1 apple|%count% apples', 7);
```

Commits
-------

4c1a65d Replace %count% with a given number out of the box
2016-09-14 13:44:22 -07:00
Victor Bocharsky
4c1a65d2a8 Replace %count% with a given number out of the box 2016-09-14 13:44:20 -07:00
Fabien Potencier
3a4eaf968b bug #19784 [HttpKernel] Fixed the nullable support for php 7.1 and below (iltar)
This PR was squashed before being merged into the 3.1 branch (closes #19784).

Discussion
----------

[HttpKernel] Fixed the nullable support for php 7.1 and below

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

This PR gives support for for the new php 7.1 and will only work in beta3 or higher. I've had to backport the support to 3.1 because I consider this a bug that it won't work, even though 3.1 won't be supported for much longer. ~~The deprecation I've added in the `ArgumentMetadata` should not be triggered as all framework cases create it with the argument. Just for developers who for some reason implemented this manually, I've added the deprecation.~~

~~*If needed, I can re-open this against 3.2 and leave 3.1  "broken"*~~

On 7.1 lower than beta3 this will happen but shouldn't affect any higher versions (I hope).
```
There was 1 failure:

1) Symfony\Component\HttpKernel\Tests\ControllerMetadata\ArgumentMetadataFactoryTest::testNullableTypesSignature
Failed asserting that two arrays are equal.
--- Expected
+++ Actual
@@ @@
 Array (
     0 => Symfony\Component\HttpKernel\ControllerMetadata\ArgumentMetadata Object (...)
     1 => Symfony\Component\HttpKernel\ControllerMetadata\ArgumentMetadata Object (
         'name' => 'bar'
-        'type' => 'stdClass'
+        'type' => 'Symfony\Component\HttpKernel\Tests\Fixtures\Controller\stdClass'
         'isVariadic' => false
         'hasDefaultValue' => false
         'defaultValue' => null
         'isNullable' => true
     )
     2 => Symfony\Component\HttpKernel\ControllerMetadata\ArgumentMetadata Object (...)
 )

/home/ivanderberg/projects/symfony/src/Symfony/Component/HttpKernel/Tests/ControllerMetadata/ArgumentMetadataFactoryTest.php:123
```

Commits
-------

4a1ab6d [HttpKernel] Fixed the nullable support for php 7.1 and below
2016-09-14 13:38:12 -07:00
Iltar van der Berg
4a1ab6dcd5 [HttpKernel] Fixed the nullable support for php 7.1 and below 2016-09-14 13:37:40 -07:00
Fabien Potencier
81e9713c80 fixed CS 2016-09-14 13:34:59 -07:00
Fabien Potencier
0d5dbb75ee Merge branch '2.8' into 3.1
* 2.8:
  [Form] Fix typo in doc comment
  [Config] Handle open_basedir restrictions in FileLocator
  [bugfix] [Console] Set `Input::$interactive` to `false` when command is executed with `--quiet` as verbosity level
  Use JSON_UNESCAPED_SLASHES for lint commands output
  Fixed collapsed ChoiceType options attributes
  Fixed the nullable support for php 7.1 and below
2016-09-14 13:33:02 -07:00
Fabien Potencier
be3a827ef1 Merge branch '2.7' into 2.8
* 2.7:
  [Form] Fix typo in doc comment
  [Config] Handle open_basedir restrictions in FileLocator
  [bugfix] [Console] Set `Input::$interactive` to `false` when command is executed with `--quiet` as verbosity level
  Use JSON_UNESCAPED_SLASHES for lint commands output
  Fixed collapsed ChoiceType options attributes
  Fixed the nullable support for php 7.1 and below
2016-09-14 13:31:12 -07:00
Fabien Potencier
c1cc6ca40e bug #19923 [bugfix] [Console] Set Input::$interactive to false when command is executed with --quiet as verbosity level (phansys)
This PR was merged into the 2.7 branch.

Discussion
----------

[bugfix] [Console] Set `Input::$interactive` to `false` when command is executed with `--quiet` as verbosity level

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

Closes #19899.

Commits
-------

4214311 [bugfix] [Console] Set `Input::$interactive` to `false` when command is executed with `--quiet` as verbosity level
2016-09-14 13:28:32 -07:00
Fabien Potencier
059b4363d4 feature #19807 [FrameworkBundle] Add %debug.file_link_format% with remapping for IDE links (nicolas-grekas)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[FrameworkBundle] Add %debug.file_link_format% with remapping for IDE links

| Q             | A
| ------------- | ---
| Branch?       | master
| New feature?  | yes
| Tests pass?   | yes
| Fixed tickets | #14340
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/pull/6944

`templating.helper.code.file_link_format` is a parameter that requires templating to be defined, but holds a concept that is used beyond templating borders.
Let's make it a general parameter that can be injected easily when required.

Commits
-------

1c4ca8c [FrameworkBundle] Add %debug.file_link_format% with remapping for IDE links
2016-09-14 12:22:10 -07:00
Fabien Potencier
277c7fa6a8 feature #19891 [FrameworkBundle] Add cache:pool:clear command (nicolas-grekas)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[FrameworkBundle] Add cache:pool:clear command

| Q             | A
| ------------- | ---
| Branch?       | master
| New feature?  | yes
| Tests pass?   | yes
| License       | MIT

Useful when deploying apps to get better control of cache pool clearing.

Commits
-------

37c5b18 [FrameworkBundle] Add cache:pool:clear command
2016-09-14 12:20:05 -07:00
Fabien Potencier
f9ccdd3db6 feature #19900 [FrameworkBundle] Add CachePoolClearerPass for weak cache pool refs in cache clearers (nicolas-grekas)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[FrameworkBundle] Add CachePoolClearerPass for weak cache pool refs in cache clearers

| Q             | A
| ------------- | ---
| Branch?       | master
| New feature?  | yes
| Tests pass?   | yes
| License       | MIT

On 3.1, when a cache pool is private and not injected anywhere, it is still added to its clearer service.
The `CachePoolClearerPass` fixes this by referencing pools in clearers only after the removing passes.

Commits
-------

c4b9f7d [FrameworkBundle] Add CachePoolClearerPass for weak cache pool refs in cache clearers
2016-09-14 12:17:33 -07:00
Nicolas Grekas
1c4ca8c9a4 [FrameworkBundle] Add %debug.file_link_format% with remapping for IDE links 2016-09-14 21:12:42 +02:00
Fabien Potencier
ce73768d0f bug #19811 Fixed the nullable support for php 7.1 and below (2.7, 2.8, 3.0) (iltar)
This PR was merged into the 2.7 branch.

Discussion
----------

Fixed the nullable support for php 7.1 and below (2.7, 2.8, 3.0)

| Q             | A
| ------------- | ---
| Branch?       | 2.7, 2.8, 3.0
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/19784#issuecomment-243852825
| License       | MIT
| Doc PR        | ~

Fixes the nullable support for 2.7, 2.8 and 3.0, can probably be partially merged into 3.1 but not 100% sure.

/ping @fabpot

Commits
-------

9c48756 Fixed the nullable support for php 7.1 and below
2016-09-14 12:08:00 -07:00
Fabien Potencier
db2e2c888f feature #19570 [Config] Fix YamlReferenceDumper prototyped array support (ogizanagi)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[Config] Fix YamlReferenceDumper prototyped array support

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

Also related to #19480 which fixes another prototype issue, but cannot be tested properly on Travis because marked as skipped by this missing implementation.

Previous output was:

```yaml
    [...]
    parameters:

        # Prototype
        name:                 ~
    connections:
        user:                 ~
        pass:                 ~
```

instead of:

```yaml
    [...]
    parameters:

        # Prototype
        name:                 ~
    connections:

        # Prototype
        -
            user:                 ~
            pass:                 ~
```

Commits
-------

063a980 [Config] Fix YamlReferenceDumper prototyped array support
2016-09-14 12:05:34 -07:00
Fabien Potencier
7136247b3d feature #19824 [Console] Add ability to regress the ProgressBar (jameshalsall)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[Console] Add ability to regress the ProgressBar

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

Commits
-------

42971bb [Console] Add ability to regress the ProgressBar
2016-09-14 12:03:38 -07:00
Fabien Potencier
c69b89a26b feature #19892 [DI] Add corresponding service id in some exception messages (nicolas-grekas)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[DI] Add corresponding service id in some exception messages

| Q             | A
| ------------- | ---
| Branch?       | master
| New feature?  | yes
| Tests pass?   | yes
| License       | MIT

This already helped me figure out where was my mistake :)

Commits
-------

d739f8d [DI] Add corresponding service id in some exception messages
2016-09-14 12:02:36 -07:00
Ener-Getick
c0a26bc8b0
[HttpFoundation] Deprecate extending some methods 2016-09-14 12:52:06 +02:00
Nicolas Grekas
37c5b183e5 [FrameworkBundle] Add cache:pool:clear command 2016-09-14 11:09:26 +02:00
Maxime Steinhausser
063a98040c [Config] Fix YamlReferenceDumper prototyped array support 2016-09-14 10:51:47 +02:00
Nicolas Grekas
bc850b60dd minor #19934 [Form] Fix typo in doc comment (fbourigault)
This PR was merged into the 2.7 branch.

Discussion
----------

[Form] Fix typo in doc comment

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

Commits
-------

82415a1 [Form] Fix typo in doc comment
2016-09-14 10:11:47 +02:00
James Halsall
42971bbfa3
[Console] Add ability to regress the ProgressBar 2016-09-14 08:47:54 +01:00
Fabien Bourigault
82415a1667 [Form] Fix typo in doc comment 2016-09-14 09:33:27 +02:00
Nicolas Grekas
156269d1e0 Merge branch '2.8' into 3.1
* 2.8:
  Fix version constraint
  Fixed bad merge
  [DoctrineBridge][PropertyInfo] Treat Doctrine decimal type as string
  Make ReflectionExtractor compatible with ReflectionType changes in PHP 7.1
2016-09-14 08:13:19 +02:00
Nicolas Grekas
c555d64390 Fix version constraint 2016-09-14 08:12:49 +02:00
Fabien Potencier
3d0d709d84 bug #19853 [PropertyInfo] Make ReflectionExtractor compatible with ReflectionType changes in PHP 7.1 (teohhanhui)
This PR was merged into the 2.8 branch.

Discussion
----------

[PropertyInfo] Make ReflectionExtractor compatible with ReflectionType changes in PHP 7.1

| Q             | A
| ------------- | ---
| Branch?       | 2.8
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/19677#issuecomment-244671828
| License       | MIT
| Doc PR        | N/A

Commits
-------

4a041e9 Make ReflectionExtractor compatible with ReflectionType changes in PHP 7.1
2016-09-13 17:30:09 -07:00
Fabien Potencier
26e2846c8a bug #19904 [Form] Fixed collapsed ChoiceType options attributes (HeahDude)
This PR was merged into the 2.7 branch.

Discussion
----------

[Form] Fixed collapsed ChoiceType options attributes

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

Commits
-------

7806e2a Fixed collapsed ChoiceType options attributes
2016-09-13 17:22:22 -07:00
Fabien Potencier
da565de0af bug #19872 [Filesystem] Consider the umask setting when dumping a file (leofeyer)
This PR was merged into the 3.1 branch.

Discussion
----------

[Filesystem] Consider the umask setting when dumping a file

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

`Filesystem::dumpFile()` does not consider the umask setting and thus creates files with write permissions for everyone (`0666`). Other `chmod()` calls in Symfony do consider the umask setting (see e.g. [here](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpFoundation/File/File.php#L101) or [here](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpFoundation/File/UploadedFile.php#L230)), therefore I have adjusted the `dumpFile()` method accordingly.

Commits
-------

fdd266f Consider the umask setting when dumping a file.
2016-09-13 17:18:46 -07:00
Fabien Potencier
354e8fdc2d bug #19908 [Config] Handle open_basedir restrictions in FileLocator (Nicofuma)
This PR was submitted for the 2.8 branch but it was merged into the 2.7 branch instead (closes #19908).

Discussion
----------

[Config] Handle open_basedir restrictions in FileLocator

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

Commits
-------

e870819 [Config] Handle open_basedir restrictions in FileLocator
2016-09-13 17:08:34 -07:00
Tristan Darricau
e8708195e2 [Config] Handle open_basedir restrictions in FileLocator
Silence `file_exists()` call to avoid open_basedir restrictions warning. (can happen when using relative imports)
2016-09-13 17:08:34 -07:00
Fabien Potencier
5129c4cf7e feature #19843 [Security] Allow run-time configuration of hash algo (nicolas-grekas)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[Security] Allow run-time configuration of hash algo

| Q             | A
| ------------- | ---
| Branch?       | master
| New feature?  | yes
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Required if we want run-time config with env vars. See #19681

Commits
-------

7903a46 [Security] Allow run-time configuration of hash algo
2016-09-13 17:06:01 -07:00
Fabien Potencier
c2b660dc60 bug #19893 [FrameworkBundle] Remove cache clearer default value in config (nicolas-grekas)
This PR was merged into the 3.1 branch.

Discussion
----------

[FrameworkBundle] Remove cache clearer default value in config

| Q             | A
| ------------- | ---
| Branch?       | 3.1
| Bug fix?      | yes
| Tests pass?   | yes
| License       | MIT

`cache.default_clearer` is already the default behavior (tested), but duplicating this in the configuration prevents inheriting the `clearer` setting when configuring child pools.

Commits
-------

193542f [FrameworkBundle] Remove cache clearer default value in config
2016-09-13 17:01:35 -07:00
Fabien Potencier
e5088ac8bf feature #19894 [Cache] Add "persistent_id" option to RedisAdapter::createConnection() (nicolas-grekas)
This PR was merged into the 3.2-dev branch.

Discussion
----------

[Cache] Add "persistent_id" option to RedisAdapter::createConnection()

| Q             | A
| ------------- | ---
| Branch?       | master
| New feature?  | yes
| Tests pass?   | yes
| License       | MIT

Commits
-------

3ee02a0 [Cache] Add persistent_id option to RedisAdapter::createConnection()
2016-09-13 16:58:58 -07:00
Fabien Potencier
18a24fff0a bug #19924 [DoctrineBridge][PropertyInfo] Treat Doctrine decimal type as string (teohhanhui)
This PR was merged into the 2.8 branch.

Discussion
----------

[DoctrineBridge][PropertyInfo] Treat Doctrine decimal type as string

| 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

Using `float` for decimal type defeats the purpose of avoiding rounding errors / loss of precision.

See http://docs.doctrine-project.org/projects/doctrine-dbal/en/latest/reference/types.html#decimal

Commits
-------

62d28f9 [DoctrineBridge][PropertyInfo] Treat Doctrine decimal type as string
2016-09-13 16:52:44 -07:00