Commit Graph

17638 Commits

Author SHA1 Message Date
Issei.M 729902a33f [Security] InMemoryUserProvider now concerns whether user's password is changed when refreshing 2015-08-10 22:07:21 +09:00
Fabien Potencier 620a3d4c69 bug #15426 [Serializer] Add support for variadic arguments in the GetSetNormalizer (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

[Serializer] Add support for variadic arguments in the GetSetNormalizer

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

There were 2 broken cases:

- when the value was passed, the array was passed as argument, becoming the first value of the variadic array. The array needs to be spread into multiple arguments when calling the method
- when the value was missing, the code would throw a ReflectionException, similar to the issue reported in #13690, because a variadic argument is optional but does not have a default value

Commits
-------

704760b Add support for variadic arguments in the GetSetNormalizer
2015-08-09 10:58:38 +02:00
Fabien Potencier 0f56497cac bug #15480 [Yaml] Nested merge keys (mathroc)
This PR was merged into the 2.3 branch.

Discussion
----------

[Yaml] Nested merge keys

When trying to use nested merge keys in Yaml, the ref sometimes had the wrong value

eg, with:

```yaml
taz: &taz
    a: Steve
    w:
        p: 1234
nested:
    <<: *taz
    d: Doug
    w: &nestedref
        p: 12345
    z:
        <<: *nestedref
```

in this case, the ref `nestedref` had the value "Doug", which cause this error :

    Symfony\Component\Yaml\Exception\ParseException: YAML merge keys used with a scalar value instead of an array at line 38 (near "<<: *nestedref").

It now works as expected

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

note: this PR replace #15241

Commits
-------

500c57e [Yaml] Nested merge keys
2015-08-09 10:56:25 +02:00
Titouan Galopin 1dda0a615b [Security] Add missing docblock in PreAuthenticatedToken 2015-08-07 09:22:48 +02:00
Mathieu Rochette 500c57e6df [Yaml] Nested merge keys 2015-08-06 22:04:45 +02:00
Nicolas Grekas 7ebda1e155 minor #15473 [travis] Build standalone phpunit without symfony/yaml (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[travis] Build standalone phpunit without symfony/yaml

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

phpunit mixed as a dependency does not work at all. Let's build it standalone, without symfony/yaml.

Commits
-------

4dd0de6 [travis] Build standalone phpunit without symfony/yaml
2015-08-06 10:32:28 +02:00
Nicolas Grekas 4dd0de6694 [travis] Build standalone phpunit without symfony/yaml 2015-08-06 10:22:42 +02:00
Nicolas Grekas 7fdba25e4f Clean wrong whitespaces 2015-08-05 17:43:06 +02:00
Fabien Potencier 805cd9fd61 minor #14115 let Travis builds fail when PHP 7 jobs fail (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

let Travis builds fail when PHP 7 jobs fail

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

Commits
-------

ecc3df5 let Travis builds fail when PHP 7 jobs fail
2015-08-05 17:26:49 +02:00
Fabien Potencier 3c62ff88ff minor #15457 [travis] Build phpunit with local components (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[travis] Build phpunit with local components

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

The tests for PHP7 currently fail because travis ships with a phar phpunit that embeds the yaml components. This one takes priority over the one in the repo. But it is outdated.
The issue arose with PHP7 tests but could have happen with any build.

Commits
-------

ce2a371 [travis] Build phpunit with local components
2015-08-05 17:25:44 +02:00
Nicolas Grekas ce2a3717fd [travis] Build phpunit with local components 2015-08-05 17:18:22 +02:00
Fabien Potencier 0064d9ebf4 bug #15445 do not remove space between attributes (greg0ire)
This PR was merged into the 2.3 branch.

Discussion
----------

do not remove space between attributes

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

This piece of code adds a space then removes it immediately. One could think that only the space after the last element of the loop is removed, but this is not the case. Space between loop elements are also removed.

Commits
-------

8d2b888 do not remove space between attributes
2015-08-04 14:17:43 +02:00
Grégoire Paris 8d2b8881f5 do not remove space between attributes
This piece of code adds a space then removes it immediately. One could think that only the space after the last element of the loop is removed, but this is not the case. Space between loop elements are also removed.
2015-08-04 12:17:13 +02:00
Christophe Coevoet 328ec0133e bug #15263 [HttpFoundation] fixed the check of 'proxy-revalidate' in Response::mustRevalidate() (axiac)
This PR was squashed before being merged into the 2.3 branch (closes #15263).

Discussion
----------

[HttpFoundation] fixed the check of 'proxy-revalidate' in Response::mustRevalidate()

| Q             | A
| ------------- | ---
| Fixed tickets | #15262
| License       | MIT

'proxy-revalidate' is not a header on its own but a 'Cache-Control' directive
See http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9

Commits
-------

6c22f0a [HttpFoundation] fixed the check of 'proxy-revalidate' in Response::mustRevalidate()
2015-08-03 19:22:19 +02:00
Valentin VALCIU 6c22f0af24 [HttpFoundation] fixed the check of 'proxy-revalidate' in Response::mustRevalidate() 2015-08-03 19:22:14 +02:00
Tobias Schultze e5909bea2c bug #15425 [Routing] Fix the retrieval of the default value for variadic arguments in the annotation loader (wdalmut, stof)
This PR was merged into the 2.3 branch.

Discussion
----------

[Routing] Fix the retrieval of the default value for variadic arguments in the annotation loader

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

This takes the test submitted in #13690 and implements the fix for this bug

Commits
-------

73c5eff Fix the retrieval of the default value for variadic arguments
9b7d4c7 Annotated routes with a variadic parameter
2015-08-01 23:19:31 -05:00
Christophe Coevoet 704760b276 Add support for variadic arguments in the GetSetNormalizer 2015-08-01 21:55:55 +02:00
Christophe Coevoet 73c5eff44d Fix the retrieval of the default value for variadic arguments 2015-08-01 21:33:42 +02:00
Walter Dal Mut 9b7d4c7613 Annotated routes with a variadic parameter
There are no variadic default values and that generate a fatal error.
2015-08-01 21:19:19 +02:00
Fabien Potencier 69171d48ea bug #15074 Fixing DbalSessionHandler to work with a Oracle "limitation" or bug? (nuncanada)
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes #15074).

Discussion
----------

Fixing DbalSessionHandler to work with a Oracle "limitation" or bug?

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

Commits
-------

c314659 Fixing DbalSessionHandler to work with a Oracle "limitation" or bug?
2015-08-01 16:15:14 +02:00
nuncanada c3146592d9 Fixing DbalSessionHandler to work with a Oracle "limitation" or bug? 2015-08-01 16:15:13 +02:00
Fabien Potencier 041c489548 minor #15080 Update EngineInterface.php (johnnypeck)
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes #15080).

Discussion
----------

Update EngineInterface.php

Grammer in doc comment.

Commits
-------

d60b2bb Update EngineInterface.php
2015-08-01 16:10:55 +02:00
Johnny Peck d60b2bba60 Update EngineInterface.php
Grammer in doc comment.
2015-08-01 16:10:55 +02:00
Nicolas Grekas 1270e72560 Fix security-acl deps 2015-08-01 10:11:30 +02:00
Fabien Potencier 2966cd2b89 minor #15412 Remove skipping of tests based on ICU data version whenever possible (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

Remove skipping of tests based on ICU data version whenever possible

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

Many tests being skipped based on the ICU data version don't actually need it. They might be testing code paths not relying on Intl, or not performing assertions on the values depending on the ICU data and so not dependant on the exact ICU version being used.

this is somewhat related to https://github.com/symfony/symfony/issues/14259 as it allows to reduce the number of tests not running on Travis.

Commits
-------

7994513 Remove skipping of tests based on ICU data version whenever possible
2015-08-01 09:51:56 +02:00
Fabien Potencier f1fa4238b7 bug #15380 do not dump leading backslashes in class names (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

do not dump leading backslashes in class names

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

Commits
-------

ad6cb10 do not dump leading backslashes in class names
2015-08-01 09:45:23 +02:00
Fabien Potencier 3b6d2a3fa3 bug #15376 [ClassMapGenerator] Skip ::class constant (WouterJ)
This PR was merged into the 2.3 branch.

Discussion
----------

[ClassMapGenerator] Skip ::class constant

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

Commits
-------

a336f0e Skip ::class constant
2015-08-01 09:35:45 +02:00
Fabien Potencier 9293c439a5 bug #15170 [Config] type specific check for emptiness (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Config] type specific check for emptiness

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

Commits
-------

0199fbf [Config] type specific check for emptiness
2015-08-01 08:17:42 +02:00
Fabien Potencier 85c10991d3 bug #15411 Fix the handling of null as locale in the stub intl classes (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

Fix the handling of null as locale in the stub intl classes

The Intl extension accepts null as locale in formatters and the collator and will use the default locale in such case. Given that the stub implementation considers that the default locale is always 'en', it should be supported here too instead of forcing libraries to pass the default locale explicitly. For instance, ``Twig_Extensions_Extension_Intl`` relies on the fact that ``null`` as locale uses the default one: https://github.com/twigphp/Twig-extensions/pull/94

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony-demo/pull/123
| License       | MIT
| Doc PR        | n/a

Commits
-------

d6db6ad Fix the handling of null as locale in the stub intl classes
2015-08-01 08:11:19 +02:00
Fabien Potencier 79b5baf42f minor #15420 Fix doctrine mapping validation type error (luxifer)
This PR was merged into the 2.3 branch.

Discussion
----------

Fix doctrine mapping validation type error

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

The error tell to implement the service `doctrine.orm.<em_name>.metadata_driver`, but this extensions check for the existence of the `doctrine.orm.<em_name>_metadata_driver` where `<em_name>` the entity manager name.

Commits
-------

2c9b1db Fix doctrine mapping validation type error
2015-08-01 08:04:58 +02:00
Florent Viel 2c9b1db05a Fix doctrine mapping validation type error
The error tell to implement the service `doctrine.orm.<em_name>.metadata_driver`, but this extensions check for the existence of the `doctrine.orm.<em_name>_metadata_driver` where `<em_name>` the entity manager name.
2015-07-31 15:18:55 +02:00
Christophe Coevoet 7994513e04 Remove skipping of tests based on ICU data version whenever possible
Many tests being skipped based on the ICU data version don't actually
need it. They might be testing code paths not relying on Intl, or not
performing assertions on the values depending on the ICU data and so not
dependant on the exact ICU version being used.
2015-07-30 18:05:29 +02:00
Fabien Potencier 0fd11d9631 bug #15413 Fix the return value on error for intl methods returning arrays (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

Fix the return value on error for intl methods returning arrays

| Q             | A
| ------------- | ---
| 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 the resource is missing, an empty array should be returned rather than null to respect the interface saying an array is always returned.

Commits
-------

801e5e2 Fix the return value on error for intl methods returning arrays
2015-07-30 17:28:54 +02:00
Christophe Coevoet 801e5e2805 Fix the return value on error for intl methods returning arrays
When the resource is missing, an empty array should be returned rather
than null to respect the interface saying an array is always returned.
2015-07-30 16:28:34 +02:00
Christophe Coevoet d6db6ad7f7 Fix the handling of null as locale in the stub intl classes
The Intl extension accepts null as locale in formatters and the
collator and will use the default locale in such case. Given that the
stub implementation considers that the default locale is always 'en', it
should be supported here too instead of forcing libraries to pass the
default locale explicitly.
2015-07-30 14:20:01 +02:00
Nicolas Grekas 6b02601e7b Fix merge 2015-07-30 09:37:09 +02:00
Fabien Potencier 004c1fdf2a bug #15392 Fix missing _route parameter notice in RouterListener logging case (Haehnchen)
This PR was submitted for the master branch but it was merged into the 2.3 branch instead (closes #15392).

Discussion
----------

Fix missing _route parameter notice in RouterListener logging case

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

`\Symfony\Component\HttpKernel\EventListener\RouterListener::onKernelRequest` missed test cases in logging condition. So if we provide routing matches without a `_route` parameter `notice` messages are thrown. In this case i added a check and use `n/a` for empty route names as this is also shown in profiler if it not exists.

Commits
-------

0ce91a6 Fix missing _route parameter notice in RouterListener logging case
2015-07-29 09:47:07 +02:00
Daniel Espendiller 0ce91a6019 Fix missing _route parameter notice in RouterListener logging case 2015-07-29 09:46:44 +02:00
Christian Flothmann ad6cb10e63 do not dump leading backslashes in class names 2015-07-28 20:25:33 +02:00
Christian Flothmann ecc3df5aae let Travis builds fail when PHP 7 jobs fail 2015-07-28 19:36:45 +02:00
Fabien Potencier ccf52ecd6e bug #15386 [php7] Fix for substr() always returning a string (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[php7] Fix for substr() always returning a string

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

This should be the last required fix for PHP7 support.

The patch in the debug component is a workaround for a bug in PHP7 (http://3v4l.org/8rm9B) that is going to be fixed soon (@jpauli power).

Commits
-------

77ee866 [php7] Fix for substr() always returning a string
2015-07-28 15:07:31 +02:00
Nicolas Grekas 77ee866dd8 [php7] Fix for substr() always returning a string 2015-07-28 14:38:40 +02:00
WouterJ a336f0e98e Skip ::class constant 2015-07-27 20:12:35 +02:00
Fabien Potencier 633d0d835c bug #15355 [Security] Do not save the target path in the session for a stateless firewall (lyrixx)
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes #15355).

Discussion
----------

[Security] Do not save the target path in the session for a stateless firewall

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

Note: I think this PR can be merged into 2.3 because it's like a bug fix

Commits
-------

3358253 [Security] Do not save the target path in the session for a stateless firewall
2015-07-26 20:14:14 +02:00
Grégoire Pineau 335825363d [Security] Do not save the target path in the session for a stateless firewall 2015-07-26 20:14:09 +02:00
Fabien Potencier f1ebfd7b47 minor #15172 [DependencyInjection] fixed FrozenParameterBag and improved Parameter… (Tomaz Ahlin)
This PR was squashed before being merged into the 2.3 branch (closes #15172).

Discussion
----------

[DependencyInjection] fixed FrozenParameterBag and improved Parameter…

The ParameterBagInterface was missing some @throws annotations, so the FrozenParameterBag class was a violation of Liskov subtitution principle. Also the ParameterBagInterface was missing the remove method.

(Optionally the ParameterBagInterface can be later split into two smaller interfaces, because the FrozenParameterBag shouldn't have the add, remove methods in the first place.)

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

I have also fixed removing elements from FrozenParameterBag, as introduced by @satahippy
https://github.com/symfony/DependencyInjection/pull/8

Commits
-------

3ad0794 [DependencyInjection] fixed FrozenParameterBag and improved Parameter…
2015-07-26 20:10:55 +02:00
Tomaz Ahlin 3ad0794aa1 [DependencyInjection] fixed FrozenParameterBag and improved Parameter… 2015-07-26 20:10:26 +02:00
Fabien Potencier 9943fd1b64 minor #15332 [travis] Tests deps=low with PHP 5.6 (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[travis] Tests deps=low with PHP 5.6

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

I noticed that testing deps=low with the lowest supported PHP skips some tests/features.
I propose to merge the 5.6 and deps=low lines of the test matrix in order to both fix this issue and remove one line in the matrix (thus making tests a bit lighter/faster on travis).

Commits
-------

d3874ec [travis] Tests deps=low with PHP 5.6
2015-07-26 11:04:17 +02:00
Fabien Potencier 0198784c58 minor #15357 #15331 add infos about deprecated classes to UPGRADE-3.0 (vincentaubert)
This PR was merged into the 2.3 branch.

Discussion
----------

#15331 add infos about deprecated classes to UPGRADE-3.0

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

Commits
-------

e391446 #15331 add infos about deprecated classes to UPGRADE-3.0
2015-07-26 11:02:50 +02:00
Vincent AUBERT e3914460f3 #15331 add infos about deprecated classes to UPGRADE-3.0 2015-07-26 08:07:15 +02:00