Commit Graph

22102 Commits

Author SHA1 Message Date
Fabien Potencier
2da03b186a fixed typo 2015-08-23 18:18:32 +02:00
Fabien Potencier
472b374790 Merge branch '2.7' into 2.8
* 2.7:
  fixed Twig deprecations
  replaced deprecated Twig sameas test by same as
  fixed a namespace in the upgrade file
2015-08-23 18:16:48 +02:00
Fabien Potencier
95a2ab385f bug #15590 Made Symfony 2.7 compatible with Twig 2.0 (fabpot)
This PR was merged into the 2.7 branch.

Discussion
----------

Made Symfony 2.7 compatible with Twig 2.0

| 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

Commits
-------

7b64354 fixed Twig deprecations
99a1fcc replaced deprecated Twig sameas test by same as
2015-08-23 18:16:21 +02:00
Fabien Potencier
7b64354058 fixed Twig deprecations 2015-08-23 17:59:39 +02:00
Wouter J
7e9991ed69 Fix BC break after split of ACL from core 2015-08-23 15:35:32 +02:00
Bernhard Schussek
d3c70fe1a4 minor #15529 [Form][2.7] fix a namespace in the upgrade file (craue)
This PR was merged into the 2.7 branch.

Discussion
----------

[Form][2.7] fix a namespace in the upgrade file

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

Commits
-------

f4a785b fixed a namespace in the upgrade file
2015-08-23 15:09:29 +02:00
Fabien Potencier
99a1fcc3e2 replaced deprecated Twig sameas test by same as 2015-08-23 09:32:15 +02:00
Fabien Potencier
4de4180457 made Symfony compatible with both Twig 1.x and 2.x 2015-08-22 18:18:42 +02:00
Fabien Potencier
1fc31243de Merge branch '2.7' into 2.8
* 2.7:
  [Form] fixed BC-break on grouped choice lists
  [WebProfilerBundle] add import for Twig macro
  made Symfony compatible with both Twig 1.x and 2.x
  [Debug/VarDumper] minor cleanups
  [Form] only use PropertyPath if not already callable
  [Form] fix reworked choice list phpdoc
  [DoctrineBridge][Form] Add old tests to legacy group
  Fixed warning when command alias is longer than command name
  removed _self usage when not needed
  Implement the support of timezone objects in the stub IntlDateFormatter
  typofix - https://github.com/vlajos/misspell_fixer
  make doctrine mappings compiler pass exception message more understandable
  fix debug-ext 003.phpt
  [Yaml] Nested merge keys
  [FrameworkBundle] [Command] removed unused variable.
  [Debug] Enhance DebugClassLoader performance on MacOSX
  Add support for variadic arguments in the GetSetNormalizer
  [DoctrineBridge][Form] Fix IdReader when indexing by primary foreign key
  [DoctrineBridge][Form] Fix EntityChoiceList when indexing by primary foreign key
2015-08-22 09:42:07 +02:00
Fabien Potencier
e25aca7072 Merge branch '2.3' into 2.7
* 2.3:
  made Symfony compatible with both Twig 1.x and 2.x
2015-08-22 09:41:51 +02:00
Fabien Potencier
cc73e19175 bug #15535 made Symfony compatible with both Twig 1.x and 2.x (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

made Symfony compatible with both Twig 1.x and 2.x

| 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

Commits
-------

a5c7a85 made Symfony compatible with both Twig 1.x and 2.x
2015-08-22 09:40:01 +02:00
Fabien Potencier
b4de379a15 bug #15561 [Form] only use PropertyPath if not already callable (Tobion)
This PR was merged into the 2.7 branch.

Discussion
----------

[Form] only use PropertyPath if not already callable

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | could be in edge cases
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #15542
| License       | MIT
| Doc PR        | -

Currently it uses a PropertyPath even when the string is already a callable. But the callable string should have higher priority since that is also the one documented in ChoiceListFactoryInterface.

Commits
-------

470b140 [Form] only use PropertyPath if not already callable
2015-08-22 09:21:30 +02:00
Fabien Potencier
c1c5f1debb feature #15555 [VarDumper] Add caster for pgsql resources (nicolas-grekas)
This PR was merged into the 2.8 branch.

Discussion
----------

[VarDumper] Add caster for pgsql resources

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

If pgsql users could give feedback on this one, that would we great!

Commits
-------

6c3cfe5 [VarDumper] Add caster for pgsql resources
2015-08-22 09:20:08 +02:00
Fabien Potencier
259bc7837b bug #15588 [WebProfilerBundle] add import for Twig macro (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[WebProfilerBundle] add import for Twig macro

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

Commits
-------

1795071 [WebProfilerBundle] add import for Twig macro
2015-08-22 09:13:13 +02:00
Fabien Potencier
5bede45e29 bug #15546 [Form] fixed BC-break on grouped choice lists (origaminal)
This PR was squashed before being merged into the 2.7 branch (closes #15546).

Discussion
----------

[Form] fixed BC-break on grouped choice lists

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

Commits
-------

12a7dd1 [Form] fixed BC-break on grouped choice lists
2015-08-22 09:11:11 +02:00
origaminal
12a7dd1714 [Form] fixed BC-break on grouped choice lists 2015-08-22 09:11:02 +02:00
Christian Flothmann
17950711a2 [WebProfilerBundle] add import for Twig macro 2015-08-22 09:00:15 +02:00
Tobias Schultze
698341631b minor #15558 [Form] fix reworked choice list phpdoc (Tobion)
This PR was merged into the 2.7 branch.

Discussion
----------

[Form] fix reworked choice list phpdoc

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

Fix leftover phpdoc change from #15061

Commits
-------

747c1a5 [Form] fix reworked choice list phpdoc
2015-08-21 17:30:00 +02:00
Fabien Potencier
a5c7a85b78 made Symfony compatible with both Twig 1.x and 2.x 2015-08-18 14:26:23 +02:00
Nicolas Grekas
6c3cfe59a4 [VarDumper] Add caster for pgsql resources 2015-08-18 14:21:03 +02:00
Nicolas Grekas
c84a403557 minor #15566 [Debug/VarDumper] minor cleanups (nicolas-grekas)
This PR was merged into the 2.7 branch.

Discussion
----------

[Debug/VarDumper] minor cleanups

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

Commits
-------

f1d379d [Debug/VarDumper] minor cleanups
2015-08-17 13:30:13 +02:00
Nicolas Grekas
f1d379db7d [Debug/VarDumper] minor cleanups 2015-08-17 10:58:33 +02:00
Tobias Schultze
470b1400d6 [Form] only use PropertyPath if not already callable 2015-08-15 21:15:17 +02:00
Tobias Schultze
747c1a5aee [Form] fix reworked choice list phpdoc 2015-08-15 20:22:17 +02:00
Nicolas Grekas
adb5327dbb [FrameworkBundle] Fix precedence of xdebug.file_link_format 2015-08-14 15:34:27 +02:00
Abdellatif Ait boudad
c8e05e39ed feature #15452 [Translator] [Xliff] Add support for target attributes. (marcosdsanchez)
This PR was merged into the 2.8 branch.

Discussion
----------

[Translator] [Xliff] Add support for target attributes.

The previous implementation ignored attributes in target nodes in xliff files
so they were lost when you loaded and then dumped the same file. This change
should fix that problem.

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

Commits
-------

b913695 Add support for target attributes.
2015-08-14 08:47:35 +00:00
Fabien Potencier
f79c48718c minor #15536 [DoctrineBridge][Form] Add old tests to legacy group (giosh94mhz)
This PR was merged into the 2.7 branch.

Discussion
----------

[DoctrineBridge][Form] Add old tests to legacy group

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

@fabpot this are the minor fixes required after merging PR  #15251. You are already managed the duplicated class during merge, so only some `@group legacy` annotation were missing.

Commits
-------

724a54b [DoctrineBridge][Form] Add old tests to legacy group
2015-08-13 14:44:06 +02:00
Giorgio Premi
724a54b461 [DoctrineBridge][Form] Add old tests to legacy group 2015-08-13 11:54:16 +02:00
Christian Raue
f4a785bfb3 fixed a namespace in the upgrade file 2015-08-12 19:27:52 +02:00
Fabien Potencier
f1d588512f bug #15515 [Console] Fixed warning when command alias is longer than command name (dosten)
This PR was merged into the 2.7 branch.

Discussion
----------

[Console] Fixed warning when command alias is longer than command name

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

Commits
-------

ecfe944 Fixed warning when command alias is longer than command name
2015-08-12 13:21:35 +02:00
Fabien Potencier
d3a1cb1837 bug #15251 [DoctrineBridge][Form] Fix IdReader when indexing by primary foreign key (giosh94mhz)
This PR was merged into the 2.7 branch.

Discussion
----------

[DoctrineBridge][Form] Fix IdReader when indexing by primary foreign key

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

Port to Symfony 2.7 of PR #14372 . The `IdReader` class can now resolve association and determine the real id value.

There is still room for improvement, though. Since I've added a `new IdReader` in the constructor, it is better to declare `IdReader` as `final` just to be safe.

PS: sorry to keep you waiting, @webmozart . When merging both commit don't forget to add the `@deprecated` annotation, and that `SingleAssociationToIntIdEntity.php` is duplicated.

Commits
-------

799d0e0 [DoctrineBridge][Form] Fix IdReader when indexing by primary foreign key
2015-08-12 11:59:37 +02:00
Fabien Potencier
e8948671a1 Merge branch '2.3' into 2.7
* 2.3:
  Implement the support of timezone objects in the stub IntlDateFormatter
  [DoctrineBridge][Form] Fix EntityChoiceList when indexing by primary foreign key
2015-08-12 11:55:25 +02:00
Fabien Potencier
d6d93dd50a bug #14372 [DoctrineBridge][Form] fix EntityChoiceList when indexing by primary foreign key (giosh94mhz)
This PR was merged into the 2.3 branch.

Discussion
----------

[DoctrineBridge][Form] fix EntityChoiceList when indexing by primary foreign key

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

I've found a bug while using the 'entity' FormType.

Doctrine allow the definition of primary keys which are foreign key of other entities. In this scenario, the `EntityChoiceList` instance check if:
  * the entity has a id composed by a single column and
  * eventually, the column is an integer

When this happens, it use the primary key as "choices indices", but since is an entity it fails in many places, where it expects integer.

The easy solution is to check whether the single-column id is not an association. Anyway, I've fixed it the RightWay™ :), and now it resolve the entity reference to the actual column type, and restart the logic. Code speaks better then words.

Commits
-------

fe4246a [DoctrineBridge][Form] Fix EntityChoiceList when indexing by primary foreign key
2015-08-12 10:05:25 +02:00
Fabien Potencier
b450c8481a bug #15514 removed _self usage when not needed (fabpot)
This PR was merged into the 2.7 branch.

Discussion
----------

removed _self usage when not needed

| 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

As those calls are macros, there are already imported via the `from` call, so accessing them directly is not need, nor desired.

Commits
-------

3d0577d removed _self usage when not needed
2015-08-11 22:59:59 +02:00
Diego Saint Esteben
ecfe94465d Fixed warning when command alias is longer than command name 2015-08-11 17:08:57 -03:00
Fabien Potencier
3d0577d1d2 removed _self usage when not needed 2015-08-11 17:34:43 +02:00
Marcos Sánchez
b913695682 Add support for target attributes.
The previous implementation ignored attributes in target nodes in xliff files
so they were lost when you load and then dump the same file. This change
should fix that problem.
2015-08-11 12:01:27 -03:00
Fabien Potencier
0ea11e4639 bug #15489 Implement the support of timezone objects in the stub IntlDateFormatter (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

Implement the support of timezone objects in the stub IntlDateFormatter

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

As of PHP 5.5, the IntlDateFormatter accepts to use DateTimeZone or IntlTimeZone objects as timezone in the constructor (and in the new setTimeZone method) rather than timezone ids.
This is even the proper way to pass a timezone from a DateTime object as DateTimeZone names are not all valid ICU identifiers (and there is a PR on the Twig-extensions repo to use such feature to support things properly: https://github.com/twigphp/Twig-extensions/pull/148).

I'm considering this as a bugfix because it is a mismatch between the stub implementation and the real class.
Note that for simplicity, these objects are accepted on all PHP versions, as reproducing the behavior of older versions is not possible in the stub anyway (triggering a warning and making the instantiating with ``new`` return ``null``). We already have such differences anyway (the ``setTimeZone`` method exists in all PHP versions in the stub)

Commits
-------

2856abe Implement the support of timezone objects in the stub IntlDateFormatter
2015-08-11 14:30:44 +02:00
Christophe Coevoet
2856abe87f Implement the support of timezone objects in the stub IntlDateFormatter
As of PHP 5.5, the IntlDateFormatter accepts to use DateTimeZone or
IntlTimeZone objects as timezone in the constructor (and in the new
setTimeZone method) rather than timezone ids.
This is even the proper way to pass a timezone from a DateTime object as
DateTimeZone names are not all valid ICU identifiers.
2015-08-11 11:41:21 +02:00
Nicolas Grekas
c0ff72802c Merge branch '2.3' into 2.7
* 2.3:
  typofix - https://github.com/vlajos/misspell_fixer
  [Yaml] Nested merge keys
  Add support for variadic arguments in the GetSetNormalizer

Conflicts:
	src/Symfony/Component/Serializer/Normalizer/GetSetMethodNormalizer.php
	src/Symfony/Component/Serializer/Tests/Normalizer/GetSetMethodNormalizerTest.php
	src/Symfony/Component/Validator/Tests/Mapping/ClassMetadataTest.php
	src/Symfony/Component/Yaml/Tests/Fixtures/sfMergeKey.yml
2015-08-11 09:58:34 +02:00
Nicolas Grekas
d82cd8f8d8 minor #15497 typofix - https://github.com/vlajos/misspell_fixer (vlajos)
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes #15497).

Discussion
----------

typofix - https://github.com/vlajos/misspell_fixer

Fix 3 small typos. Original:  #15494

Commits
-------

0692ca9 typofix - https://github.com/vlajos/misspell_fixer
2015-08-11 09:25:44 +02:00
Veres Lajos
0692ca97cd typofix - https://github.com/vlajos/misspell_fixer 2015-08-11 09:25:28 +02:00
Fabien Potencier
b7506dcc4f minor #15501 [DX] make doctrine mappings compiler pass exception message more understandable (dbu)
This PR was merged into the 2.7 branch.

Discussion
----------

[DX] make doctrine mappings compiler pass exception message more understandable

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

Commits
-------

32f92cc make doctrine mappings compiler pass exception message more understandable
2015-08-10 12:10:02 +02:00
David Buchmann
32f92cc37b make doctrine mappings compiler pass exception message more understandable 2015-08-10 12:05:42 +02: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
Fabien Potencier
7f745d72c0 bug #15467 [FrameworkBundle] fix serializer config check (xabbuh)
This PR was merged into the 2.8 branch.

Discussion
----------

[FrameworkBundle] fix serializer config check

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

Commits
-------

060c167 [FrameworkBundle] fix serializer config check
2015-08-08 08:10:39 +02:00
Titouan Galopin
1dda0a615b [Security] Add missing docblock in PreAuthenticatedToken 2015-08-07 09:22:48 +02:00
Nicolas Grekas
7231598b4c bug #15443 [Debug] Enhance DebugClassLoader performance on MacOSX (nicolas-grekas)
This PR was merged into the 2.7 branch.

Discussion
----------

[Debug] Enhance DebugClassLoader performance on MacOSX

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

Commits
-------

af0b8eb [Debug] Enhance DebugClassLoader performance on MacOSX
2015-08-07 08:54:57 +02:00
Nicolas Grekas
17fb7d3bd7 minor #15483 fix debug-ext 003.phpt (glensc)
This PR was submitted for the 2.8 branch but it was merged into the 2.7 branch instead (closes #15483).

Discussion
----------

fix debug-ext 003.phpt

in my environment the filename is filled, not "-"

$ php --version
PHP 5.5.27 (cli) (built: Jul 17 2015 12:32:05)
Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2015 Zend Technologies

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

Commits
-------

18b6964 fix debug-ext 003.phpt
2015-08-07 08:53:47 +02:00