Commit Graph

14221 Commits

Author SHA1 Message Date
Fabien Potencier
8b3b54d5a6 minor #13218 [TwigBundle] added missing @deprecated tags (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[TwigBundle] added missing @deprecated tags

The `Symfony\Bundle\TwigBundle\Extension\ActionsExtension` class has been deprecated in Symfony 2.2 but we forgot to deprecate the related classes.

Commits
-------

82f8a79 [TwigBundle] added missing @deprecated tags
2015-01-03 16:12:56 +01:00
Fabien Potencier
503d2de64a minor #13206 [2.3] Cleanup deprecations (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] Cleanup deprecations

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

Commits
-------

d649bef [2.3] Remove useless tests skips
1d68ad3 [2.3] Cleanup deprecations
2015-01-03 15:49:25 +01:00
Fabien Potencier
efa1436ba3 minor #13204 [2.3] [ClassLoader] removes deprecated classes from documentation. (hhamon)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] [ClassLoader] removes deprecated classes from documentation.

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

Commits
-------

57bd898 [ClassLoader] removes deprecated classes from documentation.
2015-01-03 15:17:52 +01:00
Fabien Potencier
82f8a795fe [TwigBundle] added missing @deprecated tags 2015-01-03 14:39:19 +01:00
Fabien Potencier
6de747e2ec minor #13211 [Security] fixed wrong phpdoc (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[Security] fixed wrong phpdoc

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

Commits
-------

064062d [Security] fixed wrong phpdoc
2015-01-03 14:33:53 +01:00
Nicolas Grekas
d649befa67 [2.3] Remove useless tests skips 2015-01-03 14:14:51 +01:00
Hugo Hamon
57bd898198 [ClassLoader] removes deprecated classes from documentation. 2015-01-03 14:04:11 +01:00
Fabien Potencier
36e05e9bf4 minor #13212 [Yaml] Update README.md (xelaris)
This PR was merged into the 2.3 branch.

Discussion
----------

[Yaml] Update README.md

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

The ability to pass file names to Yaml::parse() was deprecated in 2.2 and will be removed in 3.0. So show an up-to-date example.

Commits
-------

bab98f0 [Yaml] Update README.md
2015-01-03 13:39:27 +01:00
wusuopu
75df4a6c50 [HttpFoundation] Fix an issue caused by php's Bug #66606. 2015-01-03 12:11:27 +01:00
Alexander Schwenn
bab98f00f9 [Yaml] Update README.md
The ability to pass file names to Yaml::parse() was deprecated in 2.2 and will be removed in 3.0. So show an up-to-date example.
2015-01-03 11:53:56 +01:00
Joshua Thijssen
24a287f492 Don't add Accept-Range header on unsafe HTTP requests 2015-01-03 11:53:03 +01:00
Artiom
ad0d93baf4 simplify hasScheme method
... and correct the mistake in docblock
2015-01-03 11:51:37 +01:00
Fabien Potencier
ec38936fbf adapted previous commit for 2.3 2015-01-03 11:25:34 +01:00
blanchonvincent
119b0917dc [Security] Don't send remember cookie for sub request 2015-01-03 11:24:57 +01:00
Fabien Potencier
064062dff3 [Security] fixed wrong phpdoc 2015-01-03 11:04:03 +01:00
nyro
29b217cf21 [HttpKernel] Fix UriSigner::check when _hash is not at the end of the uri 2015-01-03 11:03:21 +01:00
Nicolas Grekas
1d68ad3265 [2.3] Cleanup deprecations 2015-01-03 10:22:29 +01:00
Mikael Pajunen
75d0d593e3 Use PHPUnit ini_set wrapper in tests
PHPUnit ini_set wrapper is now used in tests to automatically reset
ini settings after the test is run. This avoids possible side effects
and test skipping.

Native ini_set is still used in DefaultCsrfProviderTest, but its
tests are run in isolation.
2015-01-02 18:15:09 +02:00
Mikael Pajunen
99ff8a6de4 [Process] Added a test skip check for Windows
The test FindProcessInOpenBasedir fails similarly to
FindWithOpenBaseDir on Windows.
2015-01-02 18:15:08 +02:00
Mikael Pajunen
5a14941a6f [Process] Removed unused variable assignment 2015-01-02 17:27:11 +02:00
Hugo Hamon
b83da8f742 Fixes various phpdoc and coding standards. 2015-01-02 09:58:20 +01:00
Bailey Parker
3c608ebc29 Fixes Issue #13184 - incremental output getters now return empty strings 2015-01-02 09:08:40 +01:00
Saro0h
5a121df42b Updated copyright to 2015 2015-01-01 13:56:52 +01:00
Fabien Potencier
f438eae402 minor #13147 [2.3] for consistency, use value of DIRECTORY_SEPARATOR to detect Windows (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] for consistency, use value of DIRECTORY_SEPARATOR to detect Windows

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

This commit unifies the detection of Windows builds across the Symfony
codebase.

Commits
-------

20a427d use value of DIRECTORY_SEPARATOR to detect Windows
2014-12-30 14:27:52 +01:00
Jakub Zalas
ae1061564e [Form] Remove a redundant test.
This is exactly the same as testValidateTokenOnSubmitIfRootAndCompoundUsesTypeClassAsIntentionIfEmptyFormName().
2014-12-30 12:20:04 +00:00
Jakub Zalas
57070a2247 [Form] Set a child type to text if added to the form without a type.
This copies the behaviour of the FormBuilder::create() to the Form::add().
2014-12-30 11:40:10 +00:00
Christian Flothmann
20a427de7c use value of DIRECTORY_SEPARATOR to detect Windows
This commit unifies the detection of Windows builds across the Symfony
codebase.
2014-12-30 12:17:23 +01:00
Fabien Potencier
844741a192 minor #13165 Fix the implementation of deprecated Locale classes (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

Fix the implementation of deprecated Locale classes

| 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

The ICU component does not exist anymore, but the BC layer was still referencing it.

Commits
-------

eb0637f Fix the implementation of deprecated Locale classes
2014-12-30 09:48:31 +01:00
Joshua Thijssen
f239920342 Updated generateSql tool 2014-12-30 09:47:24 +01:00
Fabien Potencier
be979330f8 minor #13162 Fix phpdoc and coding standards (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

Fix phpdoc and coding standards

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

This removes the unused use statements which were not catched by PHP-CS-Fixer because of string occurences. It also fixes some invalid phpdoc (scalar is not recognized as a valid type for instance).

This is complementary to https://github.com/symfony/symfony/pull/13134

Commits
-------

8cc3f6a Fix phpdoc and coding standards
2014-12-30 09:33:34 +01:00
Fabien Potencier
e0a8441f21 minor #13161 Remove usages of deprecated constants (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

Remove usages of deprecated constants

| 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

This removes the usage of deprecated constants in our code.

I'm applying this in 2.3 to make merging branches easier. This is especially needed for 2.7 because of deprecation warnings added in #13060 (warnings are triggered in this PR because of these usages)

Commits
-------

6c00c22 Remove usages of deprecated constants
2014-12-30 09:31:19 +01:00
Fabien Potencier
803c916111 minor #13159 Update functional tests to use the PSR NullLogger (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

Update functional tests to use the PSR NullLogger

| 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

This avoids using the deprecated NullLogger in tests.

I'm applying this in 2.3 to make merging branches easier. This is especially needed for 2.7 because of deprecation warnings added in #13060 (tests are failing in this PR currently because of that)

Commits
-------

30cff26 Update functional tests to use the PSR NullLogger
2014-12-30 09:28:51 +01:00
Christophe Coevoet
eb0637f675 Fix the implementation of deprecated Locale classes
The ICU component does not exist anymore.
2014-12-30 09:06:31 +01:00
Christophe Coevoet
8cc3f6aad4 Fix phpdoc and coding standards
This removes the unused use statements which were not catched by
PHP-CS-Fixer because of string occurences. It also fixes some invalid
phpdoc (scalar is not recognized as a valid type for instance).
2014-12-29 23:41:34 +01:00
Christophe Coevoet
e6fa0ea4e1 Replace usages of the deprecated TypeTestCase by the new one 2014-12-29 22:21:04 +01:00
Christophe Coevoet
6c00c226c2 Remove usages of deprecated constants 2014-12-29 22:18:50 +01:00
Christophe Coevoet
30cff2605e Update functional tests to use the PSR NullLogger
This avoids using the deprecated NullLogger in tests.
2014-12-29 21:47:13 +01:00
Fabien Potencier
0469ea82b1 bug #13145 [DomCrawler] Fix behaviour with <base> tag (dkop, WouterJ)
This PR was merged into the 2.3 branch.

Discussion
----------

[DomCrawler] Fix behaviour with <base> tag

Finishes https://github.com/symfony/symfony/issues/12283

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

Commits
-------

91447e8 Make fabbot happy
1d35e48 Clean up testing
61f22d7 [DomCrawler] fixed bug #12143
2014-12-29 11:43:29 +01:00
WouterJ
91447e881a Make fabbot happy 2014-12-29 11:04:02 +01:00
WouterJ
1d35e48755 Clean up testing 2014-12-29 11:03:52 +01:00
Fabien Potencier
459b8b6f92 minor #13144 No global state for isolated tests and other fixes (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

No global state for isolated tests and other fixes

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

By default, phpunit preserves global state for isolated processes. This made the tests break on my laptop.
Other tweaks included.
In branch 2.5, `src/Symfony/Component/Security/Csrf/Tests/TokenStorage/NativeSessionTokenStorageTest.php` also misses the `@preserveGlobalState disabled` annotation. Please add it when merging

Commits
-------

750f3a6 No global state for isolated tests and other fixes
2014-12-29 11:01:53 +01:00
Nicolas Grekas
750f3a62f7 No global state for isolated tests and other fixes 2014-12-29 10:34:09 +01:00
Fabien Potencier
4cc4e8a257 bug #13141 [TwigBundle] Moved the setting of the default escaping strategy from the Twig engine to the Twig environment (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[TwigBundle] Moved the setting of the default escaping strategy from the Twig engine to the Twig environment

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

The default escaping strategy was set on the Twig Engine and not the Twig Environment. That's a problem under some circumstances (like what #11773 describes), but it's also much better to set everything on the Twig  Environment directly.

Commits
-------

91b24e8 [TwigBundle] Moved the setting of the default escaping strategy from the Twig engine to the Twig environment
2014-12-29 09:40:20 +01:00
Fabien Potencier
91b24e8f92 [TwigBundle] Moved the setting of the default escaping strategy from the Twig engine to the Twig environment 2014-12-29 09:39:08 +01:00
Fabien Potencier
55feca6958 bug #13114 [HttpFoundation] fixed error when an IP in the X-Forwarded-For HTTP head... (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpFoundation] fixed error when an IP in the X-Forwarded-For HTTP head...

| 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

On symfony.com, we have errors related to IP addresses in the `X-Forwarded-For` HTTP header that have a port. If that happens (I have no ideas what is doing that), the page crashes with an error like `inet_pton(): Unrecognized address 187.65.229.211:63479` (which comes from IpUtils::checkIpv6()). This fixes the root cause by removing the port.

#12572 is solving the consequence and I propose to also merge it.

Commits
-------

60ad382 [HttpFoundation] fixed error when an IP in the X-Forwarded-For HTTP header contains a port
2014-12-29 09:20:51 +01:00
Neime
1da0ba4150 [Debug] fix checkip6 2014-12-29 09:16:16 +01:00
Fabien Potencier
60ad382684 [HttpFoundation] fixed error when an IP in the X-Forwarded-For HTTP header contains a port 2014-12-29 09:12:40 +01:00
Jakub Zalas
55f0d9ed0b Update the note about origins of the CssSelector component.
The last rewrite is based on the cssselect which is no longer part of lxml, but was extracted as an independent library.
2014-12-26 23:33:10 +01:00
Jakub Zalas
1997b12f51 Use the correct cssselect library name in docblocks.
The original python library is called cssselect, not cssselector.
2014-12-26 23:22:03 +01:00
Fabien Potencier
1c039ce18d minor #13115 [HttpFoundation] removed wrong HTTP header (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpFoundation] removed wrong HTTP header

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

Commits
-------

73dddac [HttpFoundation] removed wrong HTTP header
2014-12-26 10:45:06 +01:00
Nicolas Grekas
d9053d9b55 [TwigBridge] fix form requirement 2014-12-25 23:41:41 +01:00
Fabien Potencier
37724f01a5 minor #13104 [CssSelector] added the license of the Python library we ported to PHP (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[CssSelector] added the license of the Python library we ported to PHP

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

Commits
-------

fa36b98 [CssSelector] added the license of the Python library we ported to PHP
2014-12-25 20:43:18 +01:00
Fabien Potencier
73dddac4e0 [HttpFoundation] removed wrong HTTP header 2014-12-25 20:39:31 +01:00
Fabien Potencier
fa36b98141 [CssSelector] added the license of the Python library we ported to PHP 2014-12-24 16:07:20 +01:00
Fabien Potencier
8135727102 [SecurityBundle] avoid unneeded work 2014-12-24 16:04:14 +01:00
Fabien Potencier
9ea3f6ac2f minor #13063 [2.3] [Bridge] [Propel] minor improvements to the Propel bridge. (hhamon)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] [Bridge] [Propel] minor improvements to the Propel bridge.

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

Commits
-------

6d9d460 [Bridge] [Propel] minor improvements to the Propel bridge.
2014-12-24 06:49:41 +01:00
Fabien Potencier
cad7f0e99c bug #13075 [Config] fix error handler restoration in test (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[Config] fix error handler restoration in test

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

Commits
-------

266afeb [Config] fix error handler restoration in test
2014-12-23 18:31:59 +01:00
Fabien Potencier
e2762f69c5 bug #13081 [FrameworkBundle] forward error reporting level to insulated Client (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] forward error reporting level to insulated Client

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

Especially if deprecation notices are silenced on the main php instance, we should also silence them in the insulated Client

Commits
-------

d82e062 [FrameworkBundle] forward error reporting level to insulated Client
2014-12-23 09:09:12 +01:00
Nicolas Grekas
d82e062d17 [FrameworkBundle] forward error reporting level to insulated Client 2014-12-23 08:41:15 +01:00
Graham Campbell
83c15db887 [2.3] CS And DocBlock Fixes 2014-12-22 16:58:09 +01:00
Nicolas Grekas
266afeb161 [Config] fix error handler restoration in test 2014-12-22 10:02:19 +01:00
Hugo Hamon
6d9d460ebb [Bridge] [Propel] minor improvements to the Propel bridge. 2014-12-21 17:25:02 +01:00
Fabien Potencier
ff52a9f928 minor #13054 [2.3] CS Fixes (GrahamCampbell)
This PR was squashed before being merged into the 2.3 branch (closes #13054).

Discussion
----------

[2.3] CS Fixes

| 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

##### This pull request provides some cs fixes.

Commits
-------

b521c20 [2.3] CS Fixes
2014-12-21 15:56:19 +01:00
Graham Campbell
b521c200a8 [2.3] CS Fixes 2014-12-21 15:56:12 +01:00
Saro0h
2ca438deb6 [FrameworkBundle] Fixed Translation loader and update translation command. 2014-12-21 12:33:47 +01:00
Hugo Hamon
cdc5c5bb11 [Console] remove « use » statement for PHP built-in exception classes. 2014-12-21 11:19:40 +01:00
Fabien Potencier
c9acca7381 minor #13049 [2.3] [SecurityBundle] adds unit tests suite for SecurityDataCollector class. (hhamon)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] [SecurityBundle] adds unit tests suite for SecurityDataCollector class.

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

Commits
-------

85f72f4 [SecurityBundle] adds unit tests suite for SecurityDataCollector class.
2014-12-21 09:19:38 +01:00
Hugo Hamon
85f72f4037 [SecurityBundle] adds unit tests suite for SecurityDataCollector class. 2014-12-20 22:33:13 +01:00
Fabien Potencier
405b881d86 minor #12964 [PropertyAccess] Added test to verify #5775 is fixed (aboks)
This PR was merged into the 2.3 branch.

Discussion
----------

[PropertyAccess] Added test to verify #5775 is fixed

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

Added regression test to verify #5775 has been fixed some time ago, so that it can be closed.

Commits
-------

45651c6 [PropertyAccess] Added test to verify #5775 is fixed
2014-12-20 16:49:05 +01:00
Fabien Potencier
1bb837e476 minor #13050 [Config] fixes broken unit test on ArrayNode class. (hhamon)
This PR was merged into the 2.3 branch.

Discussion
----------

[Config] fixes broken unit test on ArrayNode class.

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

Commits
-------

a7ee58a [Config] fixes broken unit test on ArrayNode class.
2014-12-20 13:59:28 +01:00
Fabien Potencier
6712a4ab30 minor #13051 [Config] adds missing « use » statement for InvalidTypeException type hint in documentation. (hhamon)
This PR was merged into the 2.3 branch.

Discussion
----------

[Config] adds missing « use » statement for InvalidTypeException type hint in documentation.

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

Commits
-------

e855424 [Config] adds missing « use » statement for InvalidTypeException type hint in documentation.
2014-12-20 13:58:29 +01:00
Hugo Hamon
e855424768 [Config] adds missing « use » statement for InvalidTypeException type hint in documentation. 2014-12-20 13:26:26 +01:00
Hugo Hamon
a7ee58a95a [Config] fixes broken unit test on ArrayNode class. 2014-12-20 13:23:01 +01:00
Fabien Potencier
901d1de344 bug #13048 [Security] Delete old session on auth strategy migrate (xelaris)
This PR was merged into the 2.3 branch.

Discussion
----------

[Security] Delete old session on auth strategy migrate

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

As identified by @austinh in #13026 there are two sessions after authentication, since the previous session is migrated to a new one by ``session_regenerate_id``. This PR ensures the old session is been deleted immediately on migration.
I can't see any drawbacks, but if the change would break BC, another approach would be to add a new strategy like ``switch`` to enable instant deletion of the old session.

Commits
-------

5dd11e6 [Security] Delete old session on auth strategy migrate
2014-12-20 13:20:33 +01:00
Fabien Potencier
c5b906918d fixed CS 2014-12-20 12:33:01 +01:00
Fabien Potencier
b1ee67fb67 minor #13036 [Config] Very minor grammar fix in error message (WouterJ)
This PR was merged into the 2.3 branch.

Discussion
----------

[Config] Very minor grammar fix in error message

It's just a tiny detail, but I found it important enough to submit a fix.

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

Commits
-------

1c65f36 Very minor grammar fix in error message
2014-12-20 12:32:34 +01:00
Fabien Potencier
3bfa40513f minor #13033 [Tests] Silenced all deprecations in tests for 2.3 (saro0h)
This PR was merged into the 2.3 branch.

Discussion
----------

[Tests] Silenced all deprecations in tests for 2.3

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

Also removed src/Symfony/Component/Security/Core/Tests/Validator/Constraints/UserPasswordValidatorTest.php as it was not running at all.

Commits
-------

ef4ae63 [Tests] Silenced all deprecations in tests for 2.3
2014-12-20 10:04:46 +01:00
Alexander Schwenn
5dd11e67a4 [Security] Delete old session on auth strategy migrate 2014-12-20 02:42:01 +01:00
Christian Flothmann
cb351a6c1a update required minimum TwigBridge version
To be able to use `Twig_SimpleFunction` in `AssetsExtension`, Twig has
to be present in version 1.12 or higher. The TwigBridge only enforces
this Twig version as of version 2.3.10.
2014-12-19 16:27:51 +01:00
Wouter J
1c65f36254 Very minor grammar fix in error message 2014-12-19 12:33:33 +01:00
sarah khalil
ef4ae63e8a [Tests] Silenced all deprecations in tests for 2.3 2014-12-18 20:00:19 +01:00
Dariusz Rumiński
9bbf803a5c BinaryFileResponse - add missing newline 2014-12-18 00:15:53 +01:00
Fabien Potencier
980c124c99 fixed CS 2014-12-17 22:41:08 +01:00
Fabien Potencier
aace2c6ee5 bug #12999 [FrameworkBundle] fix cache:clear command (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] fix cache:clear command

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

Reading comment on #12893 stating that using absolute paths works around the pb, I tried using realpath(),
and it works!
Pending work on #12955 can be done quietly now.

Commits
-------

a14153a [FrameworkBundle] fix cache:clear command
2014-12-17 22:38:55 +01:00
Daniel Wehner
c6bcf05287 add a limit and a test to FlattenExceptionTest. 2014-12-17 22:36:26 +01:00
Fabien Potencier
3a35beca0b minor #13011 CS: There should be no empty lines following phpdocs (keradus)
This PR was merged into the 2.3 branch.

Discussion
----------

CS: There should be no empty lines following phpdocs

Commits
-------

143f900 CS: There should be no empty lines following phpdocs
2014-12-17 07:25:30 +01:00
Dariusz Rumiński
143f900a52 CS: There should be no empty lines following phpdocs 2014-12-16 23:59:16 +01:00
Nicolas Grekas
a14153a4fd [FrameworkBundle] fix cache:clear command 2014-12-16 12:29:05 +01:00
Fabien Potencier
dbfe5caf1c minor #12985 [HttpFoundation] Fix return phpdoc (Koc)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpFoundation] Fix return phpdoc

| Q             | A
| ------------- | ---
| Bug fix?      | tiny (for IDE autocompletion)
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

What about using `self` or `static` keyword for this?

Commits
-------

9af2d81 Fix return phpdoc
2014-12-16 05:04:11 +01:00
Fabien Potencier
5c54b69323 minor #12993 [2.3] Docblocks should not be followed by a blank line (GrahamCampbell)
This PR was squashed before being merged into the 2.3 branch (closes #12993).

Discussion
----------

[2.3] Docblocks should not be followed by a blank line

| 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

There should be no blank line(s) between phpdocs that document properties, interfaces, classes, functions, or traits. This pull request was a test run of a new php-cs-fixer: https://github.com/FriendsOfPHP/PHP-CS-Fixer/pull/864.

Commits
-------

4e7ba1b [2.3] Docblocks should not be followed by a blank line
2014-12-16 05:02:47 +01:00
Graham Campbell
4e7ba1bd72 [2.3] Docblocks should not be followed by a blank line 2014-12-16 05:02:46 +01:00
Konstantin.Myakshin
9af2d8113e Fix return phpdoc 2014-12-15 14:01:09 +02:00
Nicolas Grekas
25fef27753 Test components using their lowest possible deps 2014-12-15 11:45:17 +01:00
thewilkybarkid
b49fa129bd Make the container considered non-fresh if the environment parameters are changed 2014-12-13 16:43:22 +00:00
Arnout Boks
45651c6e54 [PropertyAccess] Added test to verify #5775 is fixed 2014-12-12 23:14:04 +01:00
Christian Flothmann
697ce4d794 remove short array syntax
The short array syntax was introduced in PHP 5.4 and therefore leads
to failing tests when executed in PHP 5.3 environments.
2014-12-12 19:44:55 +01:00
Tobias Schultze
b9d3c92ca9 fix session restart on PHP 5.3
this also removes some useless code
2014-12-12 18:30:52 +01:00
blanchonvincent
c3c904d01f [SecurityBundle] Firewall providers building - code cleaning 2014-12-12 08:32:08 +01:00
Fabien Potencier
b0ab6878ed minor #12917 [2.3] [Security] Fixed The AuthenticationProviderInterface Alignment (GrahamCampbell)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] [Security] Fixed The AuthenticationProviderInterface Alignment

| 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

##### This pull request fixes the AuthenticationProviderInterface alignment.

Everything was indented by one too many spaces.

Commits
-------

1270327 Fixed the AuthenticationProviderInterface alignment
2014-12-12 08:20:57 +01:00
Fabien Potencier
122e117264 bug #12761 [Filesystem] symlink use RealPath instead LinkTarget (aitboudad)
This PR was squashed before being merged into the 2.3 branch (closes #12761).

Discussion
----------

[Filesystem] symlink use RealPath instead LinkTarget

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

Commits
-------

a8b8d33 [Filesystem] symlink use RealPath instead LinkTarget
2014-12-12 08:08:40 +01:00
Abdellatif Ait boudad
a8b8d33e94 [Filesystem] symlink use RealPath instead LinkTarget 2014-12-12 08:08:37 +01:00
Fabien Potencier
bfdf04b9e9 minor #12776 [2.3] Fixed the proxy-manager version constraint (GrahamCampbell)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] Fixed the proxy-manager version constraint

| 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

##### This pull request fixes the `ocramius/proxy-manager` version constraint in the 2.3 branch.

`"~0.3.1"` is far cleaner than `">=0.3.1,<0.4-dev"`, and does the same thing.

Commits
-------

ed6c50f Fixed the proxy-manager version constraint
2014-12-12 08:04:42 +01:00
Fabien Potencier
c87a661e83 minor #12529 [2.3] Remove possible call_user_func() (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] Remove possible call_user_func()

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

Merging this in 2.3 enhances performance a bit, but more importantly will ease future merges into 3.0.

Commits
-------

fad7aba [2.3] Remove possible call_user_func()
2014-12-11 19:57:00 +01:00
Fabien Potencier
6043544a37 bug #12855 [DependencyInjection] Perf php dumper (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[DependencyInjection] Perf php dumper

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

This PR came up after this comment to reduce the number of calls to dirname():
https://github.com/symfony/symfony/pull/12784#issuecomment-65619179

Commits
-------

375f83e Revert "[DependencyInjection] backport perf optim"
fcd8ff9 [DependencyInjection] perf optim: call dirname() at most 5x
c11535b [DependencyInjection] backport perf optim
2014-12-11 19:39:10 +01:00
Nicolas Grekas
375f83ece4 Revert "[DependencyInjection] backport perf optim"
This reverts commit c11535bd6b.

Conflicts:
	src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services1-1.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services1.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services10.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services12.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services8.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services9.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services9_compiled.php
2014-12-11 19:19:56 +01:00
Hugo Hamon
123e054087 [WebProfilerBundle] replaced pattern to path attribute in routes definitions. 2014-12-10 08:57:07 +01:00
Graham Campbell
1270327d83 Fixed the AuthenticationProviderInterface alignment 2014-12-09 12:18:23 +00:00
Graham Campbell
ed6c50f4fd Fixed the proxy-manager version constraint 2014-12-09 11:07:51 +00:00
Abdellatif Ait boudad
055129c1c2 [FrameworkBundle][Template name] avoid error message for the shortcut notation. 2014-12-08 10:32:45 +00:00
Fabien Potencier
f031154fa7 bug #12858 [ClassLoader] Fix undefined index in ClassCollectionLoader (szicsu)
This PR was merged into the 2.3 branch.

Discussion
----------

[ClassLoader] Fix undefined index in ClassCollectionLoader

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

Commits
-------

cfdb925 [ClassLoader] Fix undefined index in ClassCollectionLoader
2014-12-07 19:38:12 +01:00
Fabien Potencier
9f76f1c10f minor #12887 [2.3] CS Fixes: fix phpdoc's alignment (keradus)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] CS Fixes: fix phpdoc's alignment

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

Fix phpdoc's alignment

Commits
-------

f588610 fix phpdoc's alignment
2014-12-07 19:28:24 +01:00
Dariusz Rumiński
f588610722 fix phpdoc's alignment 2014-12-07 19:24:30 +01:00
Jeroen Thora
9a0d5c3e2e Minor phpcs fixes 2014-12-07 18:50:06 +01:00
Tatsuya Tsuruoka
11014c271f [Console][Table] Fix cell padding with multi-byte
When the `TableHelper` dealing with East Asian text, it renders wrong
widths. This fixes that problem.
2014-12-05 17:50:33 +09:00
Szijarto Tamas
cfdb925c47 [ClassLoader] Fix undefined index in ClassCollectionLoader 2014-12-04 22:06:34 +01:00
Nicolas Grekas
fcd8ff9b67 [DependencyInjection] perf optim: call dirname() at most 5x 2014-12-04 19:27:52 +01:00
Nicolas Grekas
c11535bd6b [DependencyInjection] backport perf optim
Conflicts:
	src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services11.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services19.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services9.php
	src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services9_compiled.php
2014-12-04 17:53:10 +01:00
Graham Campbell
b034b08506 [2.3] More cs fixes 2014-12-04 06:06:17 +01:00
Graham Campbell
0e4f0e7c9e Removed unused imports 2014-12-03 20:18:13 +00:00
Graham Campbell
0fc3369b35 CS fixes 2014-12-03 20:10:26 +00:00
Fabien Potencier
9b24d184c2 bumped Symfony version to 2.3.24 2014-12-03 15:07:19 +01:00
Fabien Potencier
daf150374d updated VERSION for 2.3.23 2014-12-03 13:04:45 +01:00
Fabien Potencier
be81a1d11b minor #12772 PSR-2 Fixes (GrahamCampbell)
This PR was merged into the 2.3 branch.

Discussion
----------

PSR-2 Fixes

| 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

##### This pull request brings symfony 2.3 back inline with PSR-2.

Commits
-------

eda746b PSR-2 fixes
2014-12-02 21:00:13 +01:00
Reinier Kip
b1222624b2 Configure firewall's kernel exception listener with configured entry point or a default entry point 2014-12-02 20:53:05 +01:00
Graham Campbell
eda746bad5 PSR-2 fixes 2014-12-02 19:42:47 +00:00
Fabien Potencier
b604b0ae75 bug #12784 [DependencyInjection] make paths relative to __DIR__ in the generated container (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[DependencyInjection] make paths relative to __DIR__ in the generated container

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #6484, #3079, partially #9238, #10894, #10999
| License       | MIT
| Doc PR        | n/a

This is an alternative approach to #10999 for removing absolute paths from the generated container:
instead of trying to fix the container file after it has been dumped, telling to the PhpDumper where its output will be written allows it to replace parts of strings by an equivalent value based on `__DIR__`.
This should be safe, thus the PR is on 2.3.

Commits
-------

edd7057 [DependencyInjection] make paths relative to __DIR__ in the generated container
2014-12-02 13:16:33 +01:00
Nicolas Grekas
edd705716a [DependencyInjection] make paths relative to __DIR__ in the generated container 2014-12-02 11:32:16 +01:00
Fabien Potencier
9e0dff5a91 minor #12781 Fixed the symfony/config version constraint (GrahamCampbell)
This PR was merged into the 2.3 branch.

Discussion
----------

Fixed the symfony/config version constraint

| 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

##### This pull request fixes the `symfony/config` version constraint in the proxy manager bridge.

Before this pull, composer was only allowing `v2.3.0` to be downloaded. This surely was not the intention. I've updated the version constraint from `"2.3"` to `"~2.3"` thus allowing all 2.x versions that are equal to or greater than `v2.3.0`.

Commits
-------

ec14f0f Fixed the symfony/config version constraint
2014-11-30 18:00:27 +01:00
Fabien Potencier
c68ff54aac minor #12774 Docblock Fixes (GrahamCampbell)
This PR was merged into the 2.3 branch.

Discussion
----------

Docblock Fixes

| 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

##### This pull request fixes the docblock alignment as requested in #12760.

It was also necessary for me to ensure the `@return` annotations were correctly separated in order to accurately align the `@param` annotations.

Commits
-------

443307e Docblock fixes
2014-11-30 17:59:09 +01:00
Fabien Potencier
b4a8655020 minor #12777 Tweaked the password-compat version constraint (GrahamCampbell)
This PR was merged into the 2.3 branch.

Discussion
----------

Tweaked the password-compat version constraint

| 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

##### This pull request tweaks the `"ircmaxell/password-compat` version constraint in the 2.3 branch.

I've updated the version constraint to `"~1.0"` match the way we require all "stable" releases. Note that this version constraint is technically different, but I consider it safe still.

Commits
-------

f703e56 Tweaked the password-compat version constraint
2014-11-30 17:56:53 +01:00
Graham Campbell
0f8547af4b Fixed the syntax of a composer.json file 2014-11-30 15:11:35 +00:00
Graham Campbell
ec14f0f007 Fixed the symfony/config version constraint
Fixes the symfony/config version constraint in the proxy manager bridge
2014-11-30 15:06:19 +00:00
Graham Campbell
f703e5661a Tweaked the password-compat version constraint 2014-11-30 14:39:13 +00:00
Graham Campbell
443307edc1 Docblock fixes 2014-11-30 13:33:44 +00:00
Fabien Potencier
6945a2a15a bug #12716 [ClassLoader] define constant only if it wasn't defined before (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[ClassLoader] define constant only if it wasn't defined before

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

Commits
-------

388229b define constant only if it wasn't defined before
2014-11-29 13:55:31 +01:00
Christian Flothmann
388229b55c define constant only if it wasn't defined before 2014-11-29 13:36:20 +01:00
Fabien Potencier
2c4d0ca6ff minor #12638 [Hackday][2.3] Fixed typos (pborreli)
This PR was merged into the 2.3 branch.

Discussion
----------

[Hackday][2.3] Fixed typos

Commits
-------

7a67e8c Fixed typos
2014-11-29 12:52:41 +01:00
alfonso
28b07bad90 Fix incorrect spanish translation 2014-11-29 12:13:56 +01:00
Pascal Borreli
7a67e8c444 Fixed typos 2014-11-29 11:42:24 +01:00
Nicolas Grekas
1ed7606c32 [Debug] fix error message on double exception 2014-11-28 10:40:13 +01:00
Fabien Potencier
819280fbbc bug #12550 [FrameworkBundle] backport #12489 (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] backport #12489

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

Commits
-------

556eff1 backport #12489
2014-11-28 10:32:58 +01:00
Fabien Potencier
4f05279edd minor #12565 Rename Symfony2 to Symfony (romainneutron)
This PR was merged into the 2.3 branch.

Discussion
----------

Rename Symfony2 to Symfony

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

Replaces #12563

Commits
-------

0a76b7e Rename Symfony2 to Symfony
2014-11-28 10:25:39 +01:00
Daniel Wehner
a18b6d17e3 Fix initialized() with aliased services 2014-11-25 12:27:34 +01:00
Romain Neutron
0a76b7e9fc Rename Symfony2 to Symfony 2014-11-24 15:09:11 +01:00
Christian Flothmann
556eff1b54 backport #12489 2014-11-23 20:08:57 +01:00
Christian Flothmann
3039935997 reformat code as suggested by @fabpot 2014-11-21 17:05:54 +01:00
Korvin Szanto
ad6422304b Fix typo 2014-11-21 17:05:54 +01:00
Korvin Szanto
41627138de Make \Request::get more performant. 2014-11-21 17:05:54 +01:00
Nicolas Grekas
fad7aba3ba [2.3] Remove possible call_user_func() 2014-11-21 10:26:02 +01:00
Strate
76273bf459 [FrameworkBundle] cache:clear command fills *.php.meta files with wrong data 2014-11-21 08:48:44 +01:00
Fabien Potencier
580de75249 bumped Symfony version to 2.3.23 2014-11-20 16:30:29 +01:00
Fabien Potencier
2f59c8df55 fixed typo 2014-11-20 14:51:29 +01:00
Fabien Potencier
ace20d4885 updated VERSION for 2.3.22 2014-11-20 14:28:56 +01:00
Fabien Potencier
30bde8961e bug #12525 [Bundle][FrameworkBundle] be smarter when guessing the document root (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Bundle][FrameworkBundle] be smarter when guessing the document root

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

Commits
-------

e28f5b8 be smarter when guessing the document root
2014-11-20 13:10:35 +01:00
Reinier Kip
92c8dfb5e6 [SecurityBundle] Authentication entry point is only registered with firewall exception listener, not with authentication listeners 2014-11-20 11:06:52 +01:00
Christian Flothmann
e28f5b8356 be smarter when guessing the document root 2014-11-20 10:40:57 +01:00
Fabien Potencier
b9425f0bc6 minor #12496 [Form] Add doc for FormEvents (GromNaN)
This PR was merged into the 2.3 branch.

Discussion
----------

[Form] Add doc for FormEvents

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

Provide the same level of phpdoc for form events than we have for other event classes.

http://api.symfony.com/2.3/Symfony/Component/HttpKernel/KernelEvents.html
http://api.symfony.com/2.3/Symfony/Component/Form/FormEvents.html

Commits
-------

656d45f [Form] Add doc for FormEvents
2014-11-19 09:31:55 +01:00
Farhad Safarov
7f7b700234 Azerbaijani locale 2014-11-19 07:31:32 +01:00
gerryvdm
ba8d93705c Fixed grammar error in docblock 2014-11-18 14:50:21 +01:00
Fabien Potencier
77f115eacf minor #12497 compare version using PHP_VERSION_ID (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

compare version using PHP_VERSION_ID

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

To let opcode caches optimize cached code, the `PHP_VERSION_ID`
constant is used to detect the current PHP version instead of calling
`version_compare()` with `PHP_VERSION`.

Commits
-------

367ed3c compare version using PHP_VERSION_ID
2014-11-17 21:54:27 +01:00
Martin Hasoň
0bd19aa491 [Bridge/Propel1] Changed deps to accepts all upcoming propel1 versions 2014-11-17 21:30:08 +01:00
Christian Flothmann
367ed3ce85 compare version using PHP_VERSION_ID
To let opcode caches optimize cached code, the `PHP_VERSION_ID`
constant is used to detect the current PHP version instead of calling
`version_compare()` with `PHP_VERSION`.
2014-11-17 17:27:42 +01:00
Jerome TAMARELLE
656d45f06a [Form] Add doc for FormEvents 2014-11-17 14:54:58 +01:00
Denis Kop
61f22d7ffb [DomCrawler] fixed bug #12143 2014-11-17 14:25:43 +03:00
Fabien Potencier
8d18c98de0 minor #12372 [Yaml] don't override internal PHP constants (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Yaml] don't override internal PHP constants

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

Commits
-------

376cc03 don't override internal PHP constants
2014-11-16 19:04:21 +01:00
Christian Flothmann
376cc0332d don't override internal PHP constants 2014-11-16 18:59:41 +01:00
Eric J. Duran
16c1b6669d Update filesystem readme.md to include exists method 2014-11-16 18:27:15 +01:00
Daniel Wehner
ace9a22101 Add machine readable events 2014-11-16 18:21:02 +01:00
Michael H. Arieli
918b16b16c [Translations] Added missing Hebrew language trans-unit sources 2014-11-12 09:10:13 +01:00
Warnar Boekkooi
7816a98204 [DependencyInjection] inlined factory not referenced 2014-11-12 08:52:52 +01:00
Yosmany Garcia
5321741ab5 Fixed case for empty folder 2014-11-08 14:35:51 -05:00
Christian Flothmann
8fc3e03a0e TwigExtractor tests require the Finder component 2014-11-03 16:33:47 +01:00
Fabien Potencier
a08fda5e5c added missing files 2014-11-03 00:30:21 +01:00
Fabien Potencier
8d2c2964bb minor #12168 [HttpFoundation] CSRF warning docs on Request::enableHttpMethodParameterOverride() (Kristof Van Cauwenbergh)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpFoundation] CSRF warning docs on Request::enableHttpMethodParameterOverride()

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

Since I wanted to understand this issue I did some research and altered the comment block. Is this a clear enough explanation or does it need more?

Commits
-------

deb70ab CSRF warning docs on Request::enableHttpMethodParameterOverride()
2014-11-02 02:30:13 +01:00
Fabien Potencier
b7f8f4eab7 bug #12370 [Yaml] improve error message for multiple documents (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Yaml] improve error message for multiple documents

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

The YAML parser doesn't support multiple documents. This pull requests
improves the error message when the parser detects multiple YAML
documents.

see also #11840

Commits
-------

c77fdcb improve error message for multiple documents
2014-11-02 02:10:02 +01:00
Fabien Potencier
f3ad406599 minor #12377 Translation debug improve error reporting (mrthehud, fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

Translation debug improve error reporting

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

Indicate which file was being parsed if an exception is thrown while running translation:debug

When running the translation:debug command, if a template contains invalid twig markup,
an exception is thrown. This patch rethrows a new exception that includes the filename
being parsed in the message to aid debugging.

Commits
-------

97a8f7e [TwigBundle] added a test
b1bffc0 Indicate which file was being parsed if an exception is thrown while running translation:debug
2014-11-02 02:05:26 +01:00
Fabien Potencier
ec82e32b13 bug #12170 [Form] fix form handling with OPTIONS request method (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[Form] fix form handling with OPTIONS request method

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

The OPTIONS request is just handled as any other request method. And accoring to the spec, an options request can also contain a request body like a POST. This only applied when using the deprecated form processing with `$form->submit($request)`. The change also makes the handling consistent with the `handleRequest` behavior via https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Form/Extension/HttpFoundation/HttpFoundationRequestHandler.php

Commits
-------

28eabd8 [Form] fix form handling with unconventional request methods like OPTIONS
2014-11-02 02:03:36 +01:00
Fabien Potencier
97a8f7e395 [TwigBundle] added a test 2014-11-02 01:56:08 +01:00
James Hudson
b1bffc0516 Indicate which file was being parsed if an exception is thrown while running translation:debug
When running the translation:debug command, if a template contains invalid twig markup,
an exception is thrown. This patch rethrows a new exception that includes the filename
being parsed in the message to aid debuging.
2014-11-02 01:45:12 +01:00
Fabien Potencier
9ea4296028 bug #12235 [Validator] Fixed Regex::getHtmlPattern() to work with complex and negated patterns (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Validator] Fixed Regex::getHtmlPattern() to work with complex and negated patterns

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

According to my own testing, this should fix the generation of HTML patterns when `Regex::$match` is set to false. Additionally, patterns containing pipes (or statements) are fixed. See the test cases for examples.

Commits
-------

bf006f5 [Validator] Fixed Regex::getHtmlPattern() to work with complex and negated patterns
2014-11-02 01:32:54 +01:00
Fabien Potencier
eb4b20f471 bug #12326 [Session] remove invalid hack in session regenerate (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[Session] remove invalid hack in session regenerate

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

The original issue #7380 was just caused because the developer missed to save the session before doing the redirect. That's all. Such mistakes won't happen anymore with #12341

This reverts #8270 and following. Also it makes absolutely no sense to do this only for the `files` save handler which creates huge inconsistencies. All save handlers are affected and it's more a documentation thing.

Commits
-------

703d906 [Session] remove invalid workaround in session regenerate
2014-11-02 01:24:31 +01:00
Fabien Potencier
9c1e4686eb bug #12341 [Kernel] ensure session is saved before sending response (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[Kernel] ensure session is saved before sending response

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

Saves the session, in case it is still open, before sending the response.

This ensures several things in case the developer did not save the session explicitly:

- If a session save handler without locking is used, it ensures the data is available
on the next request, e.g. after a redirect. PHPs auto-save at script end via
session_register_shutdown is executed after fastcgi_finish_request. So in this case
the data could be missing the next request because it might not be saved the moment
the new request is processed.

- A locking save handler (e.g. the native 'files') circumvents concurrency problems like
the one above. By saving the session before long-running things in the terminate event,
we ensure the session is not blocked longer than needed.

- When regenerating the session ID no locking is involved in PHPs session design. See
https://bugs.php.net/bug.php?id=61470 for a discussion. So in this case, the session must
be saved anyway before sending the headers with the new session ID. Otherwise session
data could get lost again for concurrent requests with the new ID. One result could be
that you get logged out after just logging in.

This listener should be executed as one of the last listeners, so that previous listeners
can still operate on the open session. This prevents the overhead of restarting it.
Listeners after closing the session can still work with the session as usual because
 Symfonys session implementation starts the session on demand. So writing to it after
it is saved will just restart it.

Commits
-------

b7bfef0 [Kernel] ensure session is saved before sending response
2014-11-02 01:22:14 +01:00
Geert De Deckere
32001a44a1 [ClassLoader] Cast $useIncludePath property to boolean 2014-11-02 01:04:15 +01:00
Geert De Deckere
35791fd0af [HttpFoundation] Minor spelling fix in PHPDocs 2014-11-02 01:01:55 +01:00
Christian Flothmann
c77fdcb2dc improve error message for multiple documents
The YAML parser doesn't support multiple documents. This pull requests
improves the error message when the parser detects multiple YAML
documents.
2014-11-01 13:21:10 +01:00
Fabien Potencier
97bb22c48c minor #12206 [Config] fix filelocator with empty name (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[Config] fix filelocator with empty name

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

fix filelocator with empty name + phpdoc in config component

Commits
-------

63b8c07 [DependencyInjection] use inheritdoc for loaders
ddd2fe2 [Config] fix filelocator with empty name
2014-10-30 17:06:22 +01:00
Tobias Schultze
703d906758 [Session] remove invalid workaround in session regenerate
The original issue #7380 was just caused because the developer missed to save the session before doing the redirect. That's all. This reverts #8270 and following.
2014-10-30 15:59:22 +01:00
Tobias Schultze
b7bfef07be [Kernel] ensure session is saved before sending response 2014-10-30 15:44:48 +01:00
Tobias Schultze
fd88de79ff [Routing] serialize the compiled route to speed things up
This also makes the CompiledRoute implement Serializable in order to:
1. make the serialization format shorter
2. have no null bytes in there, which the native serializer add for private properties, and thus would complicate saving in databases etc.
3. We should add to our symfony BC promise, that only classes that implement Serializable are ensured to be deserializable correctly with serialized representations of the class in previous symfony versions.
2014-10-27 15:27:32 +01:00
Fabien Potencier
20e7cf12ba minor #12293 Remove aligned '=>' and '=' (disquedur)
This PR was squashed before being merged into the 2.3 branch (closes #12293).

Discussion
----------

Remove aligned '=>' and '='

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | [https://github.com/symfony/symfony/issues/12284]
| License       | MIT

Could you said to me if i should make an other PR for 2.5 branch.

Commits
-------

51312d3 Remove aligned '=>' and '='
2014-10-26 08:31:56 +01:00
Disquedur
51312d31cc Remove aligned '=>' and '=' 2014-10-26 08:30:58 +01:00
Karoly Negyesi
acbde502bf Break infinite loop while resolving aliases 2014-10-26 08:26:27 +01:00
Fabien Potencier
6a62318894 bug #12313 [Security][listener] change priority of switchuser (aitboudad)
This PR was merged into the 2.3 branch.

Discussion
----------

[Security][listener] change priority of switchuser

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

Hi,
I have the following users:
  - Manager: Allowed to access to (/admin) and has a role ROLE_ALLOWED_TO_SWITCH
  - Partner: Allowed to access to (/partner)

When I attempt to switch to partner user I get "Access denied", well I think the switchuser listener must be registred before access listener.

Commits
-------

5f8047d [Security][listener] change priority of switchuser
2014-10-24 19:47:28 +02:00
Abdellatif AitBoudad
5f8047d242 [Security][listener] change priority of switchuser 2014-10-24 14:38:29 +01:00
Christophe Coevoet
7b6d115a27 Improved the phpdoc for security token classes 2014-10-24 11:21:28 +02:00
Fabien Potencier
016b0a9ad2 bumped Symfony version to 2.3.22 2014-10-24 08:50:18 +02:00
Fabien Potencier
0a6e90e091 updated VERSION for 2.3.21 2014-10-24 07:54:08 +02:00
Christian Flothmann
2ac5c86e37 enforce memcached version to be 2.1.0
The signature of the `Memcached::get()` method changed with 2.2.0.
Therefore, tests fail in Symfony when mocking `Memcached` in the
`MemcachedSessionHandlerTest` of the HttpFoundation component (see
also php-memcached-dev/php-memcached#126 and
https://bugs.php.net/bug.php?id=66331).
2014-10-23 15:11:04 +02:00
Bernhard Schussek
91fde699aa minor #12242 [Form] no need to add the url listener when it does not do anything (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[Form] no need to add the url listener when it does not do anything

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

In line with #11696

Commits
-------

7aea1c9 [Form] no need to add the url listener when it does not do anything
2014-10-20 12:59:59 +02:00
Bernhard Schussek
bf006f5202 [Validator] Fixed Regex::getHtmlPattern() to work with complex and negated patterns 2014-10-20 12:47:44 +02:00
Christian Flothmann
264c37ab96 [FrameworkBundle] improve server:run feedback
In #12253, improved feedback was added to the `server:run` command
instructing the user how to terminate the built-in web server. This
is hereby backported to the `2.3` branch.
2014-10-19 20:55:06 +02:00
Fabien Potencier
8487ef2c0c minor #12230 [Security] Lithuanian security translations (tadcka)
This PR was merged into the 2.3 branch.

Discussion
----------

[Security] Lithuanian security translations

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

Commits
-------

2e573f1 Lithuanian security translations
2014-10-17 11:15:13 +02:00
Tobias Schultze
7aea1c9808 [Form] no need to add the url listener when it does not do anything 2014-10-17 01:39:03 +02:00
Stepan Anchugov
0af6467757 [Form] Fix #11694 - Enforce options value type check in some form types 2014-10-16 11:06:53 +02:00
Bernhard Schussek
85d464a010 [Validator] Fixed: The state of the XML/YAML loaders was changed even if an exception was thrown upon loading 2014-10-16 11:01:14 +02:00
Tadas Gliaubicas
2e573f1c81 Lithuanian security translations 2014-10-15 16:10:58 +03:00
Tobias Schultze
63b8c07e5b [DependencyInjection] use inheritdoc for loaders 2014-10-13 21:10:53 +02:00
Tobias Schultze
ddd2fe2032 [Config] fix filelocator with empty name 2014-10-13 20:50:59 +02:00
Nikita Gusakov
5a6677d216 [Router] Cleanup 2014-10-13 14:38:27 +02:00
Fabien Potencier
2ad0642c1b bug #12209 [FrameworkBundle] Fixed ide links (hason)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] Fixed ide links

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

Commits
-------

baf5f47 [FrameworkBundle] Fixed ide links
2014-10-13 14:25:14 +02:00
Martin Hasoň
baf5f47dbc [FrameworkBundle] Fixed ide links 2014-10-11 00:07:52 +02:00
Wouter J
ac696b835e Add missing argument 2014-10-11 00:07:13 +02:00
Fabien Potencier
fb31e47949 minor #12193 [TwigBundle] remove unused email placeholder from error page (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[TwigBundle] remove unused email placeholder from error page

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

remove unused email placeholder from error page

Commits
-------

a64bd03 [TwigBundle] remove unused email placeholder from error page
2014-10-10 18:57:08 +02:00
Fabien Potencier
e38ceff231 bug #12197 [TwigBundle] do not pass a template reference to twig (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[TwigBundle] do not pass a template reference to twig

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

twig does not know about template references and only expects a string.
this commit also fixes that name parsing and locating was called twice for nonexistent templates.

Commits
-------

7fe33e3 [TwigBundle] do not pass a template reference to twig
2014-10-10 18:51:35 +02:00
Tobias Schultze
7fe33e3b1d [TwigBundle] do not pass a template reference to twig
twig does not know about template references and only expects a string.
this commit also fixes that name parsing and locating was called twice for nonexistent templates
2014-10-10 01:37:49 +02:00
Tobias Schultze
b97acd99f1 [TwigBundle] show correct fallback exception template in debug mode 2014-10-10 01:08:09 +02:00
Tobias Schultze
a64bd039b9 [TwigBundle] remove unused email placeholder from error page 2014-10-09 22:00:23 +02:00
Fabien Potencier
60d006df43 minor #12192 use meta charset in layouts without legacy http-equiv (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

use meta charset in layouts without legacy http-equiv

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

`<meta charset="UTF-8" />` is now the recommended approach

Commits
-------

96e7b01 use meta charset in layouts without legacy http-equiv
2014-10-09 19:34:46 +02:00
Tobias Schultze
96e7b01602 use meta charset in layouts without legacy http-equiv 2014-10-09 18:42:17 +02:00
Tobias Schultze
676c4a0253 [Routing] add tests for RequestContext 2014-10-09 17:28:58 +02:00
Tobias Schultze
f61607f5cb [Routing] fix inconsistencies in RequestContext 2014-10-09 17:27:10 +02:00
Christian Flothmann
38e9623ca4 don't raise warnings when exception is thrown
`array_map()` raises a warning when an exception is thrown inside the
callback (see https://bugs.php.net/bug.php?id=55416). To avoid these
warnings, `selectorToXPath()` is applied inside the loop.
2014-10-09 14:30:02 +02:00
Tobias Schultze
28eabd84f8 [Form] fix form handling with unconventional request methods like OPTIONS 2014-10-08 20:31:39 +02:00
Kristof Van Cauwenbergh
deb70aba15 CSRF warning docs on Request::enableHttpMethodParameterOverride()
[HttpFoundation] fixed the docs so that it gives some explanation about how you are vulnerable to CSRF when you enable the httpMethodeParameterOverride
2014-10-07 16:13:01 +02:00
Ala Eddine Khefifi
cd966c6826 [FrameworkBundle] minor fix
A small fix in the "parse" function of the "ControllerNameParser" Controller.
We should use "!==" instead of "!=" since it's better and faster in this 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
2014-10-05 15:47:08 +02:00
MightyBranch
fb0e685286 [Console] add a dot 2014-10-05 15:45:10 +02:00
Tobias Schultze
4e45a39cc0 [Form] remove unnecessary call 2014-10-05 05:13:10 +02:00
Fabien Potencier
0e7694e5e9 Merge branch 'pull/12053' into 2.3
* pull/12053:
  [Doc] Use Markdown syntax highlighting

Conflicts:
	src/Symfony/Component/Finder/README.md
2014-10-01 07:39:06 +02:00
Laurent Ghirardotti
638ce847b3 [Doc] Use Markdown syntax highlighting 2014-10-01 07:38:33 +02:00
Fabien Potencier
03f3dec065 [Finder] tweaked docs 2014-10-01 07:36:12 +02:00
Yannick Warnier
b2219cf150 [Finder] Add info about possibilities offered by SplFileInfo 2014-10-01 07:33:40 +02:00
Fabien Potencier
d002f1744a minor #12088 fix components tests (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

fix components tests

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

Since #12006, the `ContainerBuilder` contains the `addExpressionLanguageProvider()` method which references a class from the ExpressionLanguage component. By default, the PHPUnit mock API tries to mock all methods of the class being doubled. Since the ExpressionLanguage component is not required to run the tests, creating the mock objects fails when the mock API fails to mock the `addExpressionLanguageProvider()` method.

Commits
-------

2f2a732 fix components tests
2014-10-01 07:29:49 +02:00
Christian Flothmann
2f2a732807 fix components tests
Since #12006, the `ContainerBuilder` contains the
`addExpressionLanguageProvider()` method which references a class from
the ExpressionLanguage component. By default, the PHPUnit mock API
tries to mock all methods of the class being doubled. Since the
ExpressionLanguage component is not required to run the tests,
creating the mock objects fails when the mock API fails to mock
the `addExpressionLanguageProvider()` method.
2014-10-01 00:07:12 +02:00
Bernhard Schussek
b45ebef229 [Intl] FIxed failing test 2014-09-30 23:25:54 +02:00
Bernhard Schussek
65a8b9fc93 [Intl] Generated the data for ICU version 54-rc 2014-09-30 23:21:31 +02:00
Bernhard Schussek
1ce0f875be bug #11920 [Intl] Integrated ICU data into Intl component #1 (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Intl] Integrated ICU data into Intl component #1

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

This PR is an alternative implementation to #11884. It depends on ~~#11906~~ and ~~#11907~~ being merged first (~~these are included in the diff until after a merge+rebase~~ merged+rebased now).

With this PR, the ICU component becomes obsolete. The ICU data is bundled with Intl in two different formats: JSON and the binary ICU resource bundle format (version 2) readable by PHP's `\ResourceBundle` class. For a performance comparison between the two, see my [benchmark](/webmozart/json-res-benchmark).

~~The data is contained in two zip files: json.zip (2.6MB) and rb-v2.zip (3.8MB). The handler~~

```php
\Symfony\Component\Intl\Composer\ScriptHandler::decompressData()
```

~~needs to be added as Composer hook and decompresses the data after install/update.~~

The data is included as text/binary now. Git takes care of the compression.

Before this PR can be merged, I would like to find out what the performance difference between the two formats is in real applications. For that, I need benchmarks from some real-life applications which use ICU data - e.g. in forms (language drop-downs, country selectors etc.) - for both the JSON and the binary data. You can force either format to be used by hard-coding the return value of `Intl::detectDataFormat()` to `Intl::JSON` and `Intl::RB_V2` respectively. I'll also try to create some more realistic benchmarks.

If JSON is not significantly slower/takes up significantly more memory than the binary format, we can drop the binary format altogether.

Commits
-------

be819c1 [Intl] Integrated ICU data into Intl component
2014-09-30 23:20:37 +02:00
Nicolas Grekas
e3dacbd08c [EventDispatcher] fix doc bloc on EventDispatcherInterface 2014-09-30 09:22:23 +02:00
Michael J
ab5aaab414 [Validator] Update validators.zh_CN.xlf, fix translation error 2014-09-29 08:58:14 +02:00
Fabien Potencier
6beca0a945 bumped Symfony version to 2.3.21 2014-09-28 18:55:34 +02:00
Fabien Potencier
5ef0ea8414 updated VERSION for 2.3.20 2014-09-28 18:24:47 +02:00
Fabien Potencier
98b2db5a1d [SecurityBundle] fixed tests when used in standalone 2014-09-27 21:29:57 +02:00
Alex Bakhturin
f1ae970a4e Make Doctrine's dependency injection test less fragile.
[Doctrine][DependencyInjection] The test checks that a few items are ordered according to the value of their 'priority' attribute. However, a few of the items have the same value of this attribute. RegisterEventListenersAndSubscribersPass doesn't use a stable sorting, yet the test asserts that items that are 'equal' shall go in the original order. Modified so that the order of the original items is not checked.
2014-09-27 09:50:52 +02:00
Bernhard Schussek
be819c162f [Intl] Integrated ICU data into Intl component 2014-09-26 16:16:55 +02:00
Alex Bakhturin
10f9135f63 [Finder] [Iterator] Make the tests less fragile 2014-09-26 06:59:53 +02:00
Eric GELOEN
ea4ae74011 [Form][DateTime] Propagate invalid_message & invalid_message parameters to date & time sub widgets 2014-09-25 15:00:50 +02:00
Fabien Potencier
87123f6e1d minor #12015 [Validator] Simplified testing of violations (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Validator] Simplified testing of violations

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

I simplified the assertion of violations in preparation of a replacement PR for #7276.

Commits
-------

8e5537b [Validator] Simplified testing of violations
2014-09-25 11:38:09 +02:00
Bernhard Schussek
6cbc862e19 [Form] Removed constructor argument from FormTypeHttpFoundationExtension for forward compatibility with 2.5 2014-09-25 11:29:33 +02:00
Bernhard Schussek
8e5537b8a5 [Validator] Simplified testing of violations 2014-09-25 11:17:44 +02:00
Fabien Potencier
d671406ae5 minor #12017 [Validator] Fixed StaticMethodLoaderTest to actually test something (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Validator] Fixed StaticMethodLoaderTest to actually test something

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

This test is not testing anything, except for whether PHP throws a strict standards error when invalid code is loaded.

I disabled error reporting for this test, so that the actual functionality (ignoring static+abstract functions) is tested.

Commits
-------

1b1303a [Validator] Fixed StaticMethodLoaderTest to actually test something
2014-09-25 09:03:01 +02:00
Fabien Potencier
45ac2c4522 minor #12026 [FrameworkBundle] output failed matched path for clarification (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] output failed matched path for clarification

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

Because cygwin resolves the path behind the scenes, it is otherwise very unclear what path is actually used for matching.

Commits
-------

8d13af7 [FrameworkBundle] output failed matched path for clarification
2014-09-25 08:43:41 +02:00
Tobias Schultze
83f556f0f9 remove obsolete test file 2014-09-25 02:08:46 +03:00
Tobias Schultze
8d13af77db [FrameworkBundle] output failed matched path for clarification 2014-09-25 01:57:27 +03:00
Mathieu Morlon
a38d1cd8bf bug #10242 Missing checkPreAuth from RememberMeAuthenticationProvider 2014-09-24 17:03:18 +02:00
Bernhard Schussek
1b1303a8d8 [Validator] Fixed StaticMethodLoaderTest to actually test something 2014-09-24 16:07:14 +02:00
Fabien Potencier
bc8ee6f497 bug #12004 [Form] Fixed ValidatorTypeGuesser to guess properties without constraints not to be required (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Form] Fixed ValidatorTypeGuesser to guess properties without constraints not to be required

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

Consider the following entity:

```php
class Author
{
    /**
     * @Assert\NotBlank
     */
    private $name;

    private $age;
}
```

Right now, the "required" HTML attribute is set for both fields (since the default value of the "required" option is true). IMO this is wrong.

With this fix, the ValidatorTypeGuesser guesses `false` for the "required" option unless a NotNull/NotBlank constraint is present.

Commits
-------

fd77b09 [Form] Fixed ValidatorTypeGuesser to guess properties without constraints not to be required
2014-09-24 14:19:03 +02:00
Bernhard Schussek
fd77b09fba [Form] Fixed ValidatorTypeGuesser to guess properties without constraints not to be required 2014-09-24 14:11:43 +02:00
Vyacheslav Salakhutdinov
24c5ba4df3 Use request format from request in twig ExceptionController 2014-09-24 09:29:50 +02:00
Fabien Potencier
6ad5d31dd8 bug #11924 [Form] Moved POST_MAX_SIZE validation from FormValidator to request handler (rpg600, webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Form] Moved POST_MAX_SIZE validation from FormValidator to request handler

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

Commits
-------

759ae1a [Form] Moved POST_MAX_SIZE validation from FormValidator to request handler
4780210 [Form] Add a form error if post_max_size has been reached.
2014-09-24 08:12:14 +02:00
Bernhard Schussek
759ae1a7a1 [Form] Moved POST_MAX_SIZE validation from FormValidator to request handler 2014-09-23 14:27:03 +02:00
Fabien Potencier
c3feed6df2 minor #11504 [WebProfilerBundle] turbolinks compatibility (DraCzris)
This PR was merged into the 2.3 branch.

Discussion
----------

[WebProfilerBundle] turbolinks compatibility

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

Fix profiler when using turbolinks. (Without this, profiler is rendered without assets)

Commits
-------

c65b4c7 [WebProfilerBundle] turbolinks compatibility
2014-09-23 12:52:48 +02:00
rpg600
47802105d3 [Form] Add a form error if post_max_size has been reached. 2014-09-23 12:20:25 +02:00
Sergey Kolodyazhnyy
42ec76e9d0 Response::isNotModified returns true when If-Modified-Since is later than Last-Modified 2014-09-23 12:19:50 +02:00
Fabien Potencier
e47e4fa56d bug #11989 [Finder][Urgent] Remove asterisk and question mark from folder name in test to prevent windows file system issues. (Adam)
This PR was merged into the 2.3 branch.

Discussion
----------

[Finder][Urgent] Remove asterisk and question mark from folder name in test to prevent windows file system issues.

Bugfix: Yes
Fixed tickets: #11984 , #11985
Related tickets: #11970

Commit #11970 prevented Symphony from being checked out via windows due to invalid characters in a folder name within the tests.

The issue was reported in #11984  and was attempted to be fixed in #11985 but wasn't due to still including the question mark.

Please accept this ASAP as it entirely breaks any composer that relies on it.

Commits
-------

5fbb278 Avoid question mark and asterisk in folder names to prevent windows filesystem issues.
2014-09-23 07:24:00 +02:00
Yevgen Kovalienia
36998bb629 typo fixed in AbstractProcessTest (getoutput() => getOutput()) 2014-09-23 07:16:08 +02:00
Fabien Potencier
3a3fb05cdf bug #11908 [Translation] [Config] Clear libxml errors after parsing xliff file (pulzarraider)
This PR was merged into the 2.3 branch.

Discussion
----------

[Translation] [Config] Clear libxml errors after parsing xliff file

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

If libxml_use_internal_errors is set to `true` before parsing xliff file, the libxml errors are not cleared correctly. An error `Validation failed: no DTD found !` occurs in libxml errors after parsing and it's available outside the xliff parser (can break other functionality that use `libxml_get_errors` function).

Commits
-------

fab61ef [Translation] [Config] Clear libxml errors after parsing XML file
2014-09-23 07:15:05 +02:00
Adam
5fbb278b7a Avoid question mark and asterisk in folder names to prevent windows filesystem issues.
A previous commit introduced a folder with a question mark and an asterisk which are invalid NTFS folder name characters and prevented checkout on those systems.
2014-09-23 03:52:24 +00:00
Andrej Hudec
fab61effaf [Translation] [Config] Clear libxml errors after parsing XML file 2014-09-22 20:11:23 +02:00
Fabien Potencier
4ac8adde5d minor #11340 [2.3] Add missing development dependencies (romainneutron)
This PR was squashed before being merged into the 2.3 branch (closes #11340).

Discussion
----------

[2.3] Add missing development dependencies

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

I've also added a run of the test suite in every component scope.

Commits
-------

3b02af9 [2.3] Add missing development dependencies
2014-09-22 17:12:11 +02:00
Romain Neutron
3b02af9f79 [2.3] Add missing development dependencies 2014-09-22 17:11:59 +02:00
Fabien Potencier
902efb8a84 bug #11937 [HttpKernel] Make sure HttpCache is a trusted proxy (thewilkybarkid)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpKernel] Make sure HttpCache is a trusted proxy

| Q             | A
| ------------- | ---
| Bug fix?      | yes (of sorts)
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #9292
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/pull/4239

Fixes #9292 by adding `127.0.0.1` as a trusted proxy when using `HttpCache` (assuming it hasn't been already).

Commits
-------

ca65362 Make sure HttpCache is a trusted proxy
2014-09-22 15:44:41 +02:00
znerol
37dc57bda2 Fix @return docs on HttpCache::restoreResponseBody() 2014-09-22 15:25:52 +02:00
Fabien Potencier
677aefbbaa bug #11970 [Finder] Escape location for regex searches (ymc-dabe)
This PR was squashed before being merged into the 2.3 branch (closes #11970).

Discussion
----------

[Finder] Escape location for regex searches

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

If the location to start searching in contains a regex special char
like + or ? and the path restriction is a regular expresion with a start
limitation. No results will be found wtih at least GnuFindAdapter - e.g.:
```
use Symfony\Component\Finder\Finder;
use Symfony\Component\Finder\Adapter;

mkdir('/tmp/reg+ex/dir/subdir', 0777, true);

$finder = Finder::create()
    ->removeAdapters()
    ->addAdapter(new Adapter\GnuFindAdapter());
$finder->in('/tmp/reg+ex')->path('/^dir/');

print count($finder)."\n";
```

Expected result: 2
Actual result is: 0

This pull request consists of:
* a new test checking for this bug (0e81086a49425d0e12cff4f479fabeb97e9ed757)
* the actual fix (6595b6b2b71afc57ef08686b4584713c0e4e48ed)
* changes to comply with the coding standard (7f199c5b53b3c1f38b36dcc286d3b20ae877425b)

## How to reproduce
### Fastest way
1. Move or copy your local symfony clone into a location containing special regex chars:
  * `mv symfony symfony+regex`
2. Run tests in there
  * `cd symfony+regex && phpunit`

> Result: Some tests in the finder component will fail.

### Alternative: A new clone
1. Clone symfony in a directory containing at least one regex special char
  * `git clone https://github.com/symfony/symfony.git /tmp/symfony+regexchar`
2. As usual get composer, install dependencies and get phpunit
  * You might simply want to follow [this guide](http://symfony.com/doc/current/contributing/code/tests.html)
3. Run tests in there
   * `cd /tmp/symfony+regexchar && phpunit`

> Result: Some tests in the finder component will fail.

### Alternative: Apply the new test
1. Apply commit a29d1207ced2949c918357cf271200523960caef to your symfony clone
2. Run tests

> Result: The new test will fail.

Commits
-------

b63926b [Finder] Escape location for regex searches
2014-09-22 14:44:11 +02:00
Daniel Beyer
b63926b246 [Finder] Escape location for regex searches 2014-09-22 14:44:08 +02:00
Fabien Potencier
369aebf431 fixed CS 2014-09-22 10:32:35 +02:00
Fabien Potencier
f5d4515200 minor #11966 [HttpFoundation] fixed some volatile tests (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpFoundation] fixed some volatile tests

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

Commits
-------

00c1b75 [Process] fixed some volatile tests
974bf01 [HttpKernel] fixed a volatile test
6020c43 [HttpFoundation] fixed some volatile tests
2014-09-21 09:12:05 +02:00
Fabien Potencier
00c1b759cd [Process] fixed some volatile tests 2014-09-20 10:00:00 +02:00
Fabien Potencier
974bf01eb3 [HttpKernel] fixed a volatile test 2014-09-20 09:56:12 +02:00
Fabien Potencier
6020c43191 [HttpFoundation] fixed some volatile tests 2014-09-20 09:53:54 +02:00
nervo
e1eb788d2f Use getPathname() instead of string casting to get BinaryFileReponse file path 2014-09-17 13:01:47 +02:00
thewilkybarkid
ca65362b9b Make sure HttpCache is a trusted proxy 2014-09-16 19:36:21 +01:00
Steffen Roßkamp
c207d1dde2 [Form] Fix PHPDoc for builder setData methods
The underlying data variable is typed as mixed whereas the methods
paramers where typed as array.
2014-09-16 11:11:47 +02:00
Fabien Potencier
d853c0d43b minor #11820 [Security] Uniform AccessDecisionManager decide behaviour (mTorres)
This PR was merged into the 2.3 branch.

Discussion
----------

[Security] Uniform AccessDecisionManager decide behaviour

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

This PR uniforms the way the 3 decision policies (affirmative, consensus, unanimous) are handled in the Security\Core\Authoritzation\AccessDecisionManager.php

See #10170

Commits
-------

938ae4b [Security] Added more tests
2014-09-16 08:36:20 +02:00
Fabien Potencier
4fd0cf3927 fixed CS 2014-09-16 07:12:27 +02:00
Fabien Potencier
036726cf62 bug #11513 [Translation] made XliffFileDumper support CDATA sections. (hhamon)
This PR was merged into the 2.3 branch.

Discussion
----------

[Translation] made XliffFileDumper support CDATA sections.

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

Commits
-------

9926845 [Translation] made XliffFileDumper support CDATA sections.
2014-09-16 07:11:43 +02:00
Bernhard Schussek
f776e0c3d2 bug #11907 [Intl] Improved bundle reader implementations (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Intl] Improved bundle reader implementations

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

This PR extracts bundle reader improvements from #9206.

The code is internal and used for resource bundle generation only, so I did not care about BC too much.

Commits
-------

c3cce5c [Intl] Improved bundle reader implementations
2014-09-15 22:32:55 +02:00
Bernhard Schussek
c3cce5c694 [Intl] Improved bundle reader implementations 2014-09-15 22:29:25 +02:00
Thierry Marianne
908101413f [Console] guarded against invalid aliases 2014-09-15 21:15:42 +02:00
Fabien Potencier
f12890c0db bug #11799 [YAML] fix handling of empty sequence items (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[YAML] fix handling of empty sequence items

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

When a line contains only a dash it cannot safely be assumed that it contains a nested list or an embedded mapping. If the next line starts with a dash at the same indentation, the current line's item is to be treated as `null`.

Commits
-------

fc85435 fix handling of empty sequence items
2014-09-15 20:23:23 +02:00
Bernhard Schussek
d35fd52b7a bug #11906 [Intl] Fixed a few bugs in TextBundleWriter (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Intl] Fixed a few bugs in TextBundleWriter

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

See the included test cases for more information. This code was extracted from #9206.

Commits
-------

7b4a35a [Intl] Fixed a few bugs in TextBundleWriter
2014-09-15 20:17:36 +02:00
Fabien Potencier
15aec880ab fixed typo 2014-09-15 20:08:07 +02:00
1emming
59505714b3 [HttpFoundation] Request - URI - comment improvements 2014-09-15 20:07:32 +02:00
Marc Torres
938ae4bf0d [Security] Added more tests 2014-09-15 19:24:27 +02:00
Bernhard Schussek
ba218540b1 bug #11459 [Form][Validator] All index items after children are to be considered grand-children when resolving ViolationPath (Andrew Moore)
This PR was merged into the 2.3 branch.

Discussion
----------

[Form][Validator] All index items after children are to be considered grand-children when resolving ViolationPath

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | unsure, see note below
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #11458
| License       | MIT
| Doc PR        | -

#### Possible BC Break
The old behavior had unit test cases specifically testing the case of a grand-children form. However, this behavior is not documented anywhere and the fix seems to have no adverse effects on form validation. `Symfony\Component\Form\FormInterface` implements `ArrayAccess`, therefore, semantically speaking, `children[direct_child].children[grand_children]` and `children[direct_child][grand_children]` are equivalent. `offsetGet` is expected to fetch an element from `children`. I do not see why both were not considered equivalent when resolving the ViolationPath.

This commit will indeed change how some errors are mapped. However since the old mapping is (in my opinion) a bug...

Commits
-------

c64a75f [Form][Validator] All index items after children are to be considered grand-children when resolving ViolationPath (fixes #11458)
2014-09-15 19:17:27 +02:00
Bernhard Schussek
cee0ff8d64 bug #11715 [Form] FormBuilder::getIterator() now deals with resolved children (issei-m)
This PR was merged into the 2.3 branch.

Discussion
----------

[Form] FormBuilder::getIterator() now deals with resolved children

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

I think FormBuilder::getIterator() should resolve children before makes an iterator because it seems to be used in same purpose with FormBuilder::all().
What do you think?

Commits
-------

0deb505 [Form] FormBuilder::getIterator() now deals with resolved children
2014-09-15 17:17:27 +02:00
Fabien Potencier
2351513da2 bug #11892 [SwiftmailerBridge] Bump allowed versions of swiftmailer (ymc-dabe)
This PR was merged into the 2.3 branch.

Discussion
----------

[SwiftmailerBridge] Bump allowed versions of swiftmailer

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes (but SwiftmailerBridge itself does not contain any tests)
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Current version of Swiftmailer is 5.2.1, while (previously to this commit)
the version installed by composer was 5.0.3.

This is rather important, since 5.2.1 closes a security issue that 5.0.3 is
vulnarable to (https://github.com/swiftmailer/swiftmailer/issues/494).

Commits
-------

a5e3fc9 [SwiftmailerBridge] Bump allowed versions of swiftmailer
2014-09-13 11:36:39 +02:00
Fabien Potencier
fcbbe90646 bug #11918 [DependencyInjection] remove service parameter type from XSD (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[DependencyInjection] remove `service` parameter type from XSD

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

Referencing a service in a parameter doesn't work and will lead to an error when the configuration is loaded (see symfony/symfony-docs#4211).

Commits
-------

7333c2d remove `service` parameter type from XSD
2014-09-13 11:36:04 +02:00
Christian Flothmann
7333c2d1cb remove service parameter type from XSD
Referencing a service in a parameter doesn't work and will lead to an
error when the configuration is loaded.
2014-09-13 09:57:08 +02:00
Bernhard Schussek
ef5bdb2afa minor #11913 [Intl] Updated icu.ini up to ICU 53 (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Intl] Updated icu.ini up to ICU 53

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

Extracted from #9206.

Commits
-------

260e2fe [Intl] Updated icu.ini up to ICU 53
2014-09-12 15:41:47 +02:00
Bernhard Schussek
9052efc499 [Intl] Added exception handler to command line scripts 2014-09-12 15:40:41 +02:00
Bernhard Schussek
7b4a35a844 [Intl] Fixed a few bugs in TextBundleWriter 2014-09-12 13:27:08 +02:00
Bernhard Schussek
260e2fe172 [Intl] Updated icu.ini up to ICU 53 2014-09-12 13:10:21 +02:00
Bernhard Schussek
2349839738 bug #11905 [Intl] Removed non-working $fallback argument from ArrayAccessibleResourceBundle (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Intl] Removed non-working $fallback argument from ArrayAccessibleResourceBundle

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

The code in question didn't actually work. This was extracted from #9206.

Commits
-------

5feda5e [Intl] Removed non-working $fallback argument from ArrayAccessibleResourceBundle
2014-09-12 12:39:43 +02:00
Bernhard Schussek
5feda5e9a6 [Intl] Removed non-working $fallback argument from ArrayAccessibleResourceBundle 2014-09-11 18:28:58 +02:00
Jérémy JOURDIN
ee75af0c89 Use separated function to resolve command and related arguments 2014-09-11 18:27:13 +02:00
Daniel Beyer
a5e3fc9e8a [SwiftmailerBridge] Bump allowed versions of swiftmailer
Current version of Swiftmailer is 5.2.1, while (previously to this commit)
the version installed by composer was 5.0.3.

This is rather important, since 5.2.1 closes a security issue that 5.0.3 is
vulnarable to (https://github.com/swiftmailer/swiftmailer/issues/494).
2014-09-10 18:06:23 +02:00
Fabien Potencier
a45e3da3e4 minor #11822 [Security] Use hash_equals for constant-time string comparison (again) (dunglas)
This PR was merged into the 2.3 branch.

Discussion
----------

[Security] Use hash_equals for constant-time string comparison (again)

| 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

Use the `hash_equals` function (introduced in PHP 5.6) for timing attack safe string comparison when available.

Add in the DocBlock that length will leak (https://github.com/symfony/symfony/pull/11797#issuecomment-53990712).

Commits
-------

3071557 [Security] Add more tests for StringUtils::equals
03bd74b [Security] Use hash_equals for constant-time string comparison
2014-09-10 15:18:42 +02:00
Fabien Potencier
d4e056c877 bug #11374 [DI] Added safeguards against invalid config in the YamlFileLoader (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

[DI] Added safeguards against invalid config in the YamlFileLoader

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

Exceptions explaining the mistake are better than fatal errors or weird notices appearing when trying to deal with such invalid data.

The XML file loader is not affected by this because the data are validated with the XSD before being processed

Commits
-------

5183501 [DI] Added safeguards against invalid config in the YamlFileLoader
2014-09-10 15:14:47 +02:00
flack
1fe8e31514 [FrameworkBundle] Remove invalid markup 2014-09-10 15:06:13 +02:00
Bernhard Schussek
7fd5e8b201 [Intl] Added "internal" tag to all classes under Symfony\Component\Intl\ResourceBundle
We didn't have this tag yet when this component was first written. The code in that
namespace is only used for resource bundle generation and was never meant for public
use.
2014-09-09 16:20:39 +02:00
Fabien Potencier
91fb103a70 minor #11844 [FrameworkBundle] improve handling router script paths (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] improve handling router script paths

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

The `server:run` command switches the working directory before starting the built-in web server. Therefore, the path to a custom router script had to be specified based on the document root path and not based on the user's working directory.

Another option is to update the documentation (as started in symfony/symfony-docs#4194). Though I think the current behaviour is a bug. The intended behaviour can be derived from the command's help message:

> ```
If you have custom docroot directory layout, you can specify your own
 router script using --router option:

>   ./app/console server:run --router=app/config/router.php
```

As you can see, the path is specified based on the current working directory.

Commits
-------

0a16cf2 improve handling router script paths
2014-09-08 20:50:54 +02:00
Milos Colakovic
1421449991 Remove routes for removed WebProfiler actions
The import/export functionality was moved to commands in f38536ab79, but the routes were not removed.
2014-09-06 18:09:54 +02:00
Morgan Auchede
131abd816f [Security] Fix usage of unexistent method in DoctrineAclCache. 2014-09-05 15:11:41 +02:00
Fabien Potencier
cfe60a4a47 bug #11850 [YAML] properly mask escape sequences in quoted strings (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[YAML] properly mask escape sequences in quoted strings

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

Commits
-------

a7d0cf2 properly mask escape sequences in quoted strings
2014-09-05 12:07:58 +02:00
Fabien Potencier
8897e58670 bug #11856 [FrameworkBundle] backport more error information from 2.6 to 2.3 (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] backport more error information from 2.6 to 2.3

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

Commits
-------

87449e0 backport more error information from 2.6 to 2.3
2014-09-05 10:46:07 +02:00
Christian Flothmann
87449e04f2 backport more error information from 2.6 to 2.3
The commit on master was:

server:run command: provide more error information

The server:run command didn't provide many information when the executed
command exited unexpectedly. Now, the process' exit code is passed through
and an error message is displayed.
2014-09-05 10:17:01 +02:00
Fabien Potencier
7e5ec59fc8 minor #11845 [HttpKernel] Escape ESI url in generated response (Jérémy Derussé)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpKernel] Escape ESI url in generated response

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

If a template with an `<esi>` tag  is configured with an URL containing a `'` (in  `src` or `alt`) ; the HttpCache will generate invalide php code.

It's not a security issue, given the template and the `<esi>` tag is written by the developper, but, as the character quote is allowed in URL (https://tools.ietf.org/html/rfc3986) it coud be a potential bug.

Commits
-------

b044c45 Escape parameter on generated response
2014-09-05 09:35:40 +02:00
Kévin Dunglas
3071557ec8 [Security] Add more tests for StringUtils::equals 2014-09-04 23:39:11 +02:00
Kévin Dunglas
03bd74bdea [Security] Use hash_equals for constant-time string comparison 2014-09-04 23:37:08 +02:00
Christian Flothmann
a7d0cf2070 properly mask escape sequences in quoted strings 2014-09-04 22:00:25 +02:00
Fabien Potencier
80536d012d bug #11843 [Yaml] improve error message when detecting unquoted asterisks (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Yaml] improve error message when detecting unquoted asterisks

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

Asterisks in unquoted strings are used in YAML to reference variables. Before Symfony 2.3.19, Symfony 2.4.9 and Symfony 2.5.4, unquoted asterisks in inlined YAML code were treated as regular strings. This was fixed for the inline parser in #11677. However, an unquoted * character now led to an error message like this:

```
PHP Warning:  array_key_exists(): The first argument should be either a string or an integer in vendor/symfony/symfony/src/Symfony/Component/Yaml/Inline.php on line 409

  [Symfony\Component\Yaml\Exception\ParseException]
  Reference "" does not exist at line 171 (near "- { foo: * }").
```

Commits
-------

854e07b improve error when detecting unquoted asterisks
2014-09-04 11:57:59 +02:00
Jérémy Derussé
b044c45679 Escape parameter on generated response 2014-09-03 22:47:06 +02:00
Christian Flothmann
0a16cf2102 improve handling router script paths
The `server:run` command switches the working directory before
starting the built-in web server. Therefore, the path to a custom
router script had to be specified based on the document root path
and not based on the user's working directory.
2014-09-03 22:34:28 +02:00
Christian Flothmann
854e07b1de improve error when detecting unquoted asterisks
Asterisks in unquoted strings are used in YAML to reference
variables. Before Symfony 2.3.19, Symfony 2.4.9 and Symfony 2.5.4,
unquoted asterisks in inlined YAML code were treated as regular
strings. This was fixed for the inline parser in #11677. However, an
unquoted * character now led to an error message like this:

```
PHP Warning:  array_key_exists(): The first argument should be either a string or an integer in vendor/symfony/symfony/src/Symfony/Component/Yaml/Inline.php on line 409

  [Symfony\Component\Yaml\Exception\ParseException]
  Reference "" does not exist at line 171 (near "- { foo: * }").
```
2014-09-03 21:08:43 +02:00
Fabien Potencier
1033dc59cd bumped Symfony version to 2.3.20 2014-09-03 14:50:59 +02:00
Fabien Potencier
1fc0575804 updated VERSION for 2.3.19 2014-09-03 11:45:27 +02:00
Fabien Potencier
23eb033abb [HttpKernel] fixed internal fragment handling 2014-09-03 10:09:50 +02:00
Fabien Potencier
b60b5d4b24 security #11832 n/a (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

n/a

n/a

Commits
-------

f38536a [WebProfiler] replaced the import/export feature from the web interface to a CLI tool
2014-09-03 09:40:30 +02:00
Fabien Potencier
439c5a3357 security #11831 n/a (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

n/a

n/a

Commits
-------

654b1f2 Forced all fragment uris to be signed, even for ESI
2014-09-03 09:40:02 +02:00
Fabien Potencier
c558b159fe security #11830 n/a (aitboudad, Jérémy Derussé)
This PR was merged into the 2.3 branch.

Discussion
----------

n/a

n/a

Commits
-------

9e1bc22 Add tests and more assertions
101a3b7 [FrameworkBundle][Translator] Validate locales.
2014-09-03 09:39:11 +02:00
Fabien Potencier
e30bb17b7e security #11829 n/a (damz, fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

n/a

n/a

Commits
-------

3b4046e [HttpFoundation] added some missing tests
cefe237 fix parsing of Authorization header
2014-09-03 09:38:23 +02:00
Fabien Potencier
0aaabbfe8b security #11828 n/a (nicolas-grekas, larowlan)
This PR was merged into the 2.3 branch.

Discussion
----------

n/a

n/a

Commits
-------

1ee96a8 Test examples from Drupal SA-CORE-2014-003
5506ee8 Fix potential DoS when parsing HOST
2014-09-03 09:37:21 +02:00
Fabien Potencier
f38536ab79 [WebProfiler] replaced the import/export feature from the web interface to a CLI tool 2014-09-02 15:08:29 +02:00
Christophe Coevoet
654b1f281e Forced all fragment uris to be signed, even for ESI 2014-09-02 09:39:57 +02:00
Christophe Coevoet
5183501e0b [DI] Added safeguards against invalid config in the YamlFileLoader
Exceptions explaining the mistake are better than fatal errors or weird
notices appearing when trying to deal with such invalid data.
Closes #11333
2014-09-02 09:31:18 +02:00
Jérémy Derussé
9e1bc22388 Add tests and more assertions 2014-09-02 09:12:49 +02:00
Abdellatif Ait boudad
101a3b7b50 [FrameworkBundle][Translator] Validate locales. 2014-09-02 09:12:49 +02:00
Fabien Potencier
3b4046e894 [HttpFoundation] added some missing tests 2014-09-01 23:16:21 +02:00
DQNEO
05f5860c56 [HttpFoundation] Improve string values in test codes 2014-09-01 13:58:07 +02:00
Fabien Potencier
32f1143e60 minor #11814 [Security] fixing typo in a comment (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Security] fixing typo in a comment

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

As reported [here](https://github.com/symfony/symfony/pull/11574/files#r16934052).

Commits
-------

faefd66 fixing typo in a comment
2014-09-01 13:45:45 +02:00
DQNEO
42841e845b fix comment: not fourth but sixth argument 2014-09-01 13:44:28 +02:00
Christian Flothmann
faefd66b10 fixing typo in a comment 2014-09-01 09:40:12 +02:00
Fabien Potencier
62bc2c4cf5 [FrameworkBundle] fixed CS 2014-08-31 06:17:40 +02:00
Michael Tibben
a8a40fcb9e [FrameworkBundle] PhpExtractor bugfix and improvements 2014-08-31 06:14:42 +02:00
1emming
8a47b62bd3 [Finder] Fix findertest readability 2014-08-31 06:03:32 +02:00
Fabien Potencier
b5d0501860 minor #11574 [Security] Made optimization on constant-time algorithm removing modulus operator (yosmanyga)
This PR was merged into the 2.3 branch.

Discussion
----------

[Security] Made optimization on constant-time algorithm removing modulus operator

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

This fix improves the constant-time algorithm used to compare strings, as it removes the `%` operator inside the loop.

Commits
-------

000bd0d Made optimization deprecating modulus operator
2014-08-31 05:48:56 +02:00
Damian Sromek
c056a9c426 [Filesystem] Add FTP stream wrapper context option to enable overwrite (override) 2014-08-31 05:30:23 +02:00
Miliooo
0010fba8b1 [HttpKernel] add use statement for phpdoc 2014-08-30 09:46:13 +02:00
Christian Flothmann
fc85435915 fix handling of empty sequence items
When a line contains only a dash it cannot safely be assumed that
it contains a nested list or an embedded mapping. If the next line
starts with a dash at the same indentation, the current line's item
is to be treated as `null`.
2014-08-29 15:58:19 +02:00
Fabien Potencier
c730fc6f77 bug #11788 [Yaml] fixed mapping keys containing a quoted # (hvt, fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[Yaml] fixed mapping keys containing a quoted #

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

Commits
-------

110f999 [Yaml] fixed mapping keys containing a quoted #
8ba3b28 Added fixture to test parsing of hash keys ending with a space and #
2014-08-29 11:22:54 +02:00
Christophe Coevoet
37f2c3dabd bug #11160 [DoctrineBridge] Abstract Doctrine Subscribers with tags (merk)
This PR was merged into the 2.3 branch.

Discussion
----------

[DoctrineBridge] Abstract Doctrine Subscribers with tags

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

I've hit a problem with some doctrine listeners, built by decorating an abstract definition.

I want the abstract definition to hold the tag, however because the RegisterEventListenersAndSubscribersPass runs before abstract definitions are removed, they get added as method calls to the EventManager definition, which once the abstract service is removed, we end up with a method call that breaks the container.

I don't know if this is the best approach, it might be better not to return abstract services when calling `findTaggedServiceIds` instead?

Commits
-------

cbcf513 Disallow abstract definitions from doctrine event listener registration
2014-08-28 21:58:08 +02:00
Fabien Potencier
8605c42441 [ClassLoader] simplified phpdoc 2014-08-28 16:35:12 +02:00
Fabien Potencier
f7769b52f1 bug #11768 [ClassLoader] Add a __call() method to XcacheClassLoader (tstoeckler)
This PR was squashed before being merged into the 2.3 branch (closes #11768).

Discussion
----------

[ClassLoader] Add a __call() method to XcacheClassLoader

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

Commits
-------

dd0d6af [ClassLoader] Add a __call() method to XcacheClassLoader
2014-08-28 16:33:47 +02:00
Tobias Stöckler
dd0d6afc21 [ClassLoader] Add a __call() method to XcacheClassLoader 2014-08-28 16:33:42 +02:00
Christian Flothmann
24d2c9a5f0 fix some minor typos in tests 2014-08-28 11:02:24 +02:00
Fabien Potencier
110f999d05 [Yaml] fixed mapping keys containing a quoted # 2014-08-28 03:42:35 +02:00
Harm van Tilborg
8ba3b289fe Added fixture to test parsing of hash keys ending with a space and # 2014-08-28 03:41:39 +02:00
Fabien Potencier
bb97903684 bug #11726 [Filesystem Component] mkdir race condition fix #11626 (kcassam)
This PR was squashed before being merged into the 2.3 branch (closes #11726).

Discussion
----------

[Filesystem Component] mkdir race condition fix #11626

[Filesystem Component] Fix mkdir race condition

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

Commits
-------

0483452 [Filesystem Component] mkdir race condition fix #11626
2014-08-27 14:38:41 +02:00
Ka
04834521f1 [Filesystem Component] mkdir race condition fix #11626 2014-08-27 14:38:33 +02:00
Fabien Potencier
8990ac691c bug #11677 [YAML] resolve variables in inlined YAML (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[YAML] resolve variables in inlined YAML

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

#11569 does not resolve variables in inline YAML.

Commits
-------

45a5863 [YAML] resolve variables in inlined YAML
2014-08-27 14:37:38 +02:00
Fabien Potencier
7510d0648e [Validator] reverted permissions change on translation files 2014-08-27 10:38:16 +02:00
Warnar Boekkooi
e992f8e3d1 Fixed Factory services not within the ServiceReferenceGraph. 2014-08-27 10:32:18 +02:00
Fabien Potencier
3cb9d7af35 bug #11778 [Validator] Fixed wrong translations for Collection constraints (samicemalone)
This PR was merged into the 2.3 branch.

Discussion
----------

[Validator] Fixed wrong translations for Collection constraints

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

The error messages for a missing field and an unexpected field did not match the Constraint class.

Commits
-------

808de2b [Validator] Fixed wrong translation keys/messages for Collection constraint. The error messages for a missing field and an unexpected field did not match the Contraint class
2014-08-27 10:28:50 +02:00
Johnson Page
b9a237c00b [CssSelector] Fix URL to SimonSapin/cssselect repo 2014-08-27 10:24:06 +02:00
Sam Malone
808de2b284 [Validator] Fixed wrong translation keys/messages for Collection constraint. The error messages for a missing field and an unexpected field did not match the Contraint class 2014-08-27 03:57:26 +01:00
Jakub Kulhan
39c4cc387d [DependencyInjection] fix @return anno created by PhpDumper 2014-08-26 15:05:12 +02:00
Christophe Coevoet
b591404bee Fixed the phpdoc of the VoterInterface 2014-08-25 10:05:09 +02:00
Damien Tournoud
cefe237c6f fix parsing of Authorization header 2014-08-22 18:41:26 +02:00
Christophe Coevoet
0233da8fd7 bug #11711 [DoctrineBridge] Fix empty parameter logging in the dbal logger (jakzal)
This PR was squashed before being merged into the 2.3 branch (closes #11711).

Discussion
----------

[DoctrineBridge] Fix empty parameter logging in the dbal logger

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

Commits
-------

ef23f02 [DoctrineBridge] Fix empty parameter logging in the dbal logger
2014-08-22 12:30:02 +02:00
Jakub Zalas
ef23f02415 [DoctrineBridge] Fix empty parameter logging in the dbal logger 2014-08-22 12:29:51 +02:00
Lee Rowlands
1ee96a8b1b Test examples from Drupal SA-CORE-2014-003 2014-08-22 11:57:03 +02:00
Nicolas Grekas
5506ee8f66 Fix potential DoS when parsing HOST 2014-08-22 11:56:47 +02:00
Christophe Coevoet
b96e7f9707 bug #11692 [DomCrawler] check for the correct field type (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[DomCrawler] check for the correct field type

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

HTML allow to define different form fields with the same name. Imagine the following form:

```html
    <html>
        <body>
            <form action="/">
                <input type="hidden" name="option" value="default">
                <input type="radio" name="option" value="A">
                <input type="radio" name="option" value="B">
                <input type="hidden" name="settings[1]" value="0">
                <input type="checkbox" name="settings[1]" value="1" id="setting-1">
                <button>klickme</button>
            </form>
        </body>
    </html>
```

Since the `FormFieldRegistry` can only handle one field per name, the hidden field option is registered first before the radio field with the same name is evaluated. Thus, the `FormFieldRegistry` returns an `InputFormField` instance on which the `addChoices()` method can not be called.

Commits
-------

169b397 check for the correct field type
2014-08-21 02:21:59 +02:00
Issei.M
0deb505e64 [Form] FormBuilder::getIterator() now deals with resolved children 2014-08-20 19:06:28 +09:00
Tobias Schultze
f262b01c5f bug #11672 [Routing] fix handling of nullable XML attributes (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Routing] fix handling of nullable XML attributes

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

As @Tobion pointed out in #11394, ``true`` and ``1`` are valid values in boolean XML attributes. The XmlFileLoader didn't handle ``1`` values properly.

Commits
-------

7b4d4b6 fix handling of nullable XML attributes
2014-08-20 10:56:18 +02:00
Christophe Coevoet
00aedfc150 bug #11624 [DomCrawler] fix the axes handling in a bc way (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[DomCrawler] fix the axes handling in a bc way

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

The previous fix in #11548 for handling XPath axes was not backward compatible. In previous Symfony versions the Crawler handled nodes by holding a "fake root node". This must be taken into account when evaluating (relativizing) XPath expressions.

Commits
-------

d26040f [DomCrawler] fix the axes handling in a bc way
2014-08-19 12:43:37 +02:00
Nek (Maxime Veber)
31d48ab91f Fixed #11675 ValueToDuplicatesTransformer accept "0" value
Fixed wrong return null syntax

Added transformation to null on empty arrays

Removed useless statement in condition and switched to yoda condition
2014-08-19 11:05:04 +02:00
Bernhard Schussek
5440ed5c38 [Validators] Fixed failing tests requiring ICU 52.1 which are skipped otherwise 2014-08-19 10:50:01 +02:00
Bernhard Schussek
f825f5d1c3 minor #11615 [Validator] return empty metadata collection if none do exist (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Validator] return empty metadata collection if none do exist

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | [The reference to the documentation PR if any]

Backport of #11614 for Symfony 2.3 and 2.4.

Commits
-------

f5bc18d return empty metadata collection if none do exist
2014-08-19 10:48:01 +02:00
Christian Flothmann
169b3978ae check for the correct field type
HTML allow to define different form fields with the same name.
Imagine the following form:

    <html>
        <body>
            <form action="/">
                <input type="hidden" name="option" value="default">
                <input type="radio" name="option" value="A">
                <input type="radio" name="option" value="B">
                <input type="hidden" name="settings[1]" value="0">
                <input type="checkbox" name="settings[1]" value="1" id="setting-1">
                <button>klickme</button>
            </form>
        </body>
    </html>

Since the `FormFieldRegistry` can only handle one field per name, the
hidden field option is registered first before the radio field with
the same name is evaluated. Thus, the `FormFieldRegistry` returns an
`InputFormField` instance on which the `addChoices()` method can not
be called.
2014-08-18 17:01:30 +02:00
Christian Flothmann
45a5863508 [YAML] resolve variables in inlined YAML 2014-08-18 16:09:32 +02:00
Seb Koelen
2d5ab91fe4 add missing options 2014-08-18 10:59:14 +02:00
Christian Flothmann
7b4d4b63eb fix handling of nullable XML attributes
As @Tobion pointed out in #11394, true and 1 are valid values in
boolean XML attributes. The XmlFileLoader didn't handle 1 values
properly.
2014-08-15 11:05:55 +02:00
Nicolas Grekas
65862c9947 minor #11667 [HttpFoundation] revert #11510, moved to 2.6 (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpFoundation] revert #11510, moved to 2.6

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

This reverts PR #11510 from 2.3.

Commits
-------

fb120c7 revert #11510, moved to 2.6
2014-08-14 17:05:58 +02:00
Nicolas Grekas
a8b13a2999 bug #11529 [WebProfilerBundle] Fixed double height of canvas (hason)
This PR was merged into the 2.3 branch.

Discussion
----------

[WebProfilerBundle] Fixed double height of canvas

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

Commits
-------

c689186 [WebProfilerBundle] Fixed double height of canvas
2014-08-14 16:41:09 +02:00
Bernhard Schussek
87a47eadc9 [Validator] Backported constraint validator tests from 2.5 2014-08-14 15:44:06 +02:00
Yosmany Garcia
000bd0d863 Made optimization deprecating modulus operator 2014-08-14 12:15:45 +00:00
Nicolas Grekas
fb120c7827 revert #11510, moved to 2.6 2014-08-14 10:11:24 +02:00
Benjamin Laugueux
65220e77b4 Fix toolbar vertical alignment. 2014-08-13 21:39:42 +02:00
Nicolas Grekas
6b9ce52a11 bug #11559 [Validator] Convert objects to string in comparison validators (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Validator] Convert objects to string in comparison validators

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

In the [latest merge from 2.3 into 2.4](/symfony/symfony/commit/3bed1b7988e94a897a64c6a2ad3bf70bde9005c1), the changes from 6cf5e0812e in 2.4 got lost. This PR brings back these changes and backports them to 2.3.

The change is BC, because the former value `true` of the `$prettyDateTime` will be cast to `1`, which corresponds to the `PRETTY_DATE` format constant.

Commits
-------

273671e [Validator] Convert objects to string in comparison validators. Reapplies 6cf5e0812e
2014-08-13 21:13:32 +02:00
Nicolas Grekas
4f098dc5a4 feature #11510 [HttpFoundation] MongoDbSessionHandler supports auto expiry via configurable expiry_field (catchamonkey)
This PR was squashed before being merged into the 2.3 branch (closes #11510).

Discussion
----------

[HttpFoundation] MongoDbSessionHandler supports auto expiry via configurable expiry_field

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

ToDo

 * [x] Fix Tests

Looking for feedback on this early PR.

This adds a config option that disables the PHP GC method call from doing anything,
It also means that the write method sets up the auto expiring index.

Ref: #11508

Commits
-------

b56b740 [HttpFoundation] MongoDbSessionHandler supports auto expiry via configurable expiry_field
2014-08-13 21:10:05 +02:00
Chris Sedlmayr
b56b740940 [HttpFoundation] MongoDbSessionHandler supports auto expiry via configurable expiry_field 2014-08-13 21:06:50 +02:00
Nicolas Grekas
511b20d837 bug #11408 [HttpFoundation] Update QUERY_STRING when overrideGlobals (yguedidi)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpFoundation] Update QUERY_STRING when overrideGlobals

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

Commits
-------

777666f [HttpFoundation] Update QUERY_STRING when overrideGlobals
2014-08-13 21:04:07 +02:00
Christian Flothmann
8a2b423b53 [FrameworkBundle] add missing attribute to XSD
The hinclude_default_template configuration option couldn't have been
set in XML configurations since it wasn't defined in the XML schema
definition.
2014-08-10 15:07:49 +02:00
Benjamin Laugueux
f1ea987f35 Allow basic auth in url.
Improve regex. Add tests.
2014-08-09 12:41:29 +02:00
Fabien Potencier
7b3bd56f77 minor #11603 remove volatile tests (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

remove volatile tests

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

Commits
-------

24fb66d remove volatile tests
2014-08-09 12:40:05 +02:00
Fabien Potencier
5b1d913174 bug #11609 [Console] fixed style creation when providing an unknown tag option (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

[Console] fixed style creation when providing an unknown tag option

| 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 formatting a string, the console ignore style it cannot parse. But if a string looks like an option (`<setting=value>`) for instance, instead of displaying the text as is, it currently throws an exception.

Commits
-------

8814920 [Console] fixed style creation when providing an unknown tag option
2014-08-09 12:37:57 +02:00
Pablo Godel
be03b7552a fix typos and syntax in Profiler controller method comments 2014-08-09 12:37:11 +02:00
Christian Flothmann
d26040f356 [DomCrawler] fix the axes handling in a bc way
The previous fix in #11548 for handling XPath axes was not backward
compatible. In previous Symfony versions the Crawler handled nodes
by holding a "fake root node". This must be taken into account when
evaluating (relativizing) XPath expressions.
2014-08-09 11:40:56 +02:00
Morgan Auchede
696b978742 [HttpKernel] added an analyze of environment parameters for built-in server. 2014-08-08 17:50:03 +02:00
Christian Flothmann
f5bc18d648 return empty metadata collection if none do exist
The PropertyMetadataContainerInterface defines that the method
getPropertyMetadata() has to return an empty collection if no
metadata have been configured for the given property. Though, its
implementation in the ClassMetadata class didn't check for
existence of such metadata. This behavior led to unexpected PHP
notices when validating a property or a property value of a property
without any configured constraints (only affects the new 2.5 API).
Additionally, the getMemberMetadatas() didn't check for existing
array keys as well which has also been fixed.
2014-08-08 11:23:54 +02:00
Christian Flothmann
24fb66ddf3 remove volatile tests
Some tests relying on timings and external network resources were not
reliable and occasionally made builds on Travis fail.
2014-08-08 10:12:23 +02:00
Fabien Potencier
88149209ae [Console] fixed style creation when providing an unknown tag option 2014-08-07 17:55:24 +02:00
Fabien Potencier
56a75179d1 minor #11565 [Process] Added process synchronization to the incremental output tests (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Process] Added process synchronization to the incremental output tests

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

The tests currently fail from time to time if the executing machine is under
heavy load. This leads to false negatives on Travis CI.

A side effect of the change is that the tests are much faster now.

Commits
-------

6dd3946 [Process] Added process synchronization to the incremental output tests
2014-08-07 15:08:01 +02:00
Gordon Franke
c70a226121 change command to which available under most unix systems
agree i will change it which is available under suse, ubuntu, debian, fedora, bsd
2014-08-07 14:55:21 +02:00
Gordon Franke
85e77b14f7 add way to test command under windows 2014-08-07 09:02:32 +02:00
Gordon Franke
4fa9288fda fix shell command injection 2014-08-07 09:01:16 +02:00
Issei.M
e77022ba6d [Form] allowed CallbackTransformer to use callable 2014-08-06 15:53:52 +02:00
Bernhard Schussek
6dd3946a7e [Process] Added process synchronization to the incremental output tests
The tests currently fail from time to time if the executing machine is under
heavy load. This leads to false negatives on Travis CI.

A side effect of the change is that the tests are much faster now.
2014-08-06 15:45:25 +02:00
Peter Kruithof
5ecc449898 Fixed relative redirects for ambiguous paths 2014-08-05 09:20:55 +02:00
Walther Lalk
39973de230 [BrowserKit] Fix browser kit redirect with ports 2014-08-05 09:17:23 +02:00
Fabien Potencier
e76561dbc0 bug #11545 [Bundle][FrameworkBundle] built-in server: exit when docroot does not exist (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Bundle][FrameworkBundle] built-in server: exit when docroot does not exist

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

When the server:run command is run with an invalid document root
directory (for example, when being in the app directory and not
changing the document root to ../web/), the command crashes on Windows
with a 267 exit code. On Linux, the server starts but just publishes
internal server errors.

Commits
-------

f143254 built-in server: exit when docroot does not exist
2014-08-05 09:12:57 +02:00
Emanuele Iannone
16bd88e61f [TwigBridge] [Form] Fixed some extra empty spaces 2014-08-05 09:07:37 +02:00
Fabien Potencier
1ba7c72b09 minor #11550 [Form] fix whitespace in Twig form template (craue)
This PR was merged into the 2.3 branch.

Discussion
----------

[Form] fix whitespace in Twig form template

| Q             | A
| ------------- | ---
| Bug fix?      | kind of (after updating from 2.3.17 to 2.3.18, some of my tests were broken because of this)
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | they should, let's see what Travis has to say...
| Fixed tickets | --
| License       | MIT
| Doc PR        | --

This fixes some whitespace rendering.

after merging #11386:
```html
<input type="text" id="myfield" name="myfield"     value="blah" />
```

before merging #11386 and with this PR again:
```html
<input type="text" id="myfield" name="myfield" value="blah" />
```

Commits
-------

8504d02 fixed whitespace in Twig form template
2014-08-05 09:06:43 +02:00
Seb Koelen
9b550d6324 Plural fix 2014-08-05 09:05:24 +02:00
Fabien Potencier
59d6912b40 bug #11558 [DependencyInjection] Fixed missing 'factory-class' attribute in XmlDumper output (kerdany)
This PR was merged into the 2.3 branch.

Discussion
----------

[DependencyInjection] Fixed missing 'factory-class' attribute in XmlDumper output

| 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

Problem: XmlDumper doesn't write 'factory-class' XML attribute for definitions on which setFactoryClass() was called.

Impact: Container[Builder] to throws an exception when the relevant service is being requested/initiated after loading the dumped XML.
`Uncaught Exception Symfony\Component\DependencyInjection\Exception\RuntimeException: "Cannot create service "xxx" from factory method without a factory service or factory class." at /<path>/<to>//DependencyInjection/ContainerBuilder.php`

Solution: Made XmlDumper write the 'factory-class' attribute, and updated the relevant test fixture.

Another related problem, is that XMLFileLoader doesn't complain if the 'factory-class' attribute is missing for a 'service' elements that include 'factory-method' attribute, resulting in an ill-configured Definition object in the ContainerBuilder. I'll post an issue/ticket, and probably send another PR for that.

Commits
-------

18e3e6f [DependencyInjection] fixed missing 'factory-class' attribute in XmlDumper output
2014-08-05 09:04:05 +02:00
Bernhard Schussek
273671ec59 [Validator] Convert objects to string in comparison validators. Reapplies 6cf5e0812e 2014-08-04 12:43:57 +02:00
Fabien Potencier
99ee01d482 removed some .gitattributes that should have been removed a lot time ago 2014-08-04 12:32:26 +02:00
moldcraft
0c6f750c1e Fix incorrect romanian plural translations 2014-08-04 11:02:01 +02:00
Hany el-Kerdany
18e3e6fe20 [DependencyInjection] fixed missing 'factory-class' attribute in XmlDumper output
Symfony\Component\DependencyInjection\Dumper\XmlDumper didn't write 'factory-class' XML attribute for definitions on which setFactoryClass() was called.

This caused the Container[Builder] to throw an exception when the relevant service is being requested/initiated after loading the dumped XML:

`Uncaught Exception Symfony\Component\DependencyInjection\Exception\RuntimeException: "Cannot create service "xxx" from factory method without a factory service or factory class." at /<path>/<to>/vendor/symfony/dependency-injection/Symfony/Component/DependencyInjection/ContainerBuilder.php`

Fixed the problem, and updated the relevant test fixture.
2014-08-04 10:10:46 +03:00
Fabien Potencier
9ac2234eb8 bug #11548 [Component][DomCrawler] fix axes handling in Crawler::filterXPath() (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Component][DomCrawler] fix axes handling in Crawler::filterXPath()

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

Due to some limitations in the ``relativize()`` method, it was not possible to use XPath axes other than ``descendant`` or ``descendant-or-self`` in the ``filterXPath()`` method of the ``Crawler`` class. This commit adds support for the ``ancestor``, ``ancestor-or-self``, ``attribute``, ``child``, ``following``, ``following-sibling``, ``parent``, ``preceding``, ``preceding-sibling`` and ``self`` axes.

The only axis missing after this is the ``namespace`` axis. Filtering for namespace nodes returns ``DOMNameSpaceNode`` instances which can't be passed to the ``add()`` method.

Commits
-------

8dc322b fix axes handling in Crawler::filterXPath()
2014-08-03 08:32:28 +02:00
Christian Raue
8504d02c51 fixed whitespace in Twig form template 2014-08-02 16:06:49 +02:00
Christian Flothmann
8dc322be34 fix axes handling in Crawler::filterXPath()
Due to some limitations in the relativize() method, it was not
possible to use XPath axes other than descendant or descendant-or-self
in the filterXPath() method of the Crawler class. This commit adds
support for the ancestor, ancestor-or-self, attribute, child,
following, following-sibling, parent, preceding, preceding-sibling and
self axes.
2014-08-02 10:47:58 +02:00
Fabien Potencier
abf2edf81a minor #11483 fix some docblocks (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

fix some docblocks

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

Commits
-------

1775da5 fix some docblocks
2014-08-02 09:53:48 +02:00
Hugo Hamon
9926845cf3 [Translation] made XliffFileDumper support CDATA sections. 2014-08-02 09:13:43 +02:00
Christian Flothmann
f143254220 built-in server: exit when docroot does not exist
When the server:run command is run with an invalid document root
directory (for example, when being in the app directory and not
changing the document root to ../web/), the command crashes on Windows
with a 267 exit code. On Linux, the server starts but just publishes
internal server errors.
2014-08-02 09:12:28 +02:00
Christian Flothmann
1775da5925 fix some docblocks 2014-08-02 08:27:27 +02:00
sun
440322effc Fixed self-reference in 'service_container' service breaks garbage collection (and clone). 2014-08-02 08:06:01 +02:00
Jakub Zalas
e40f24f0a9 [Process] Fix tests when pcntl is not available. 2014-08-01 11:51:55 +01:00
Fabien Potencier
a292a489c5 minor #11537 Make builds green again (jakzal)
This PR was merged into the 2.3 branch.

Discussion
----------

Make builds green again

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

This PR rolls back changes made to the fixture and generated files in e9022adaef (#11512).

Commits
-------

88b4e70 [DependencyInjection] Roll back changes made to generated files.
f89811d [Console] Roll back changes made to fixture files.
2014-08-01 08:16:34 +02:00
Fabien Potencier
73ddf39ffc bug #11428 [Serializer] properly handle null data when denormalizing (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Serializer] properly handle null data when denormalizing

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

Commits
-------

123fc62 properly handle null data when denormalizing
2014-08-01 08:14:57 +02:00
Jakub Zalas
88b4e7008d [DependencyInjection] Roll back changes made to generated files.
Original change was made in e9022adaef.
2014-07-31 22:03:37 +01:00
Jakub Zalas
f89811d8d1 [Console] Roll back changes made to fixture files.
Original change was made in e9022adaef.
2014-07-31 21:49:10 +01:00
Martin Hasoň
c689186674 [WebProfilerBundle] Fixed double height of canvas 2014-07-31 16:08:09 +02:00
Bernhard Schussek
7d7b5c724f bug #10687 [Validator] Fixed string conversion in constraint violations (eagleoneraptor, webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Validator] Fixed string conversion in constraint violations

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

Commits
-------

32ae95b [Validator] Added more detailed inline documentation
08ea6d3 [Validator] Removed information from the violation output if the value is an array, object or resource
d6a783f [Validator] Renamed valueToString() to formatValue(); added missing formatValue() calls
71897d7 [Validator] Fixed CS
cea4155 [Validator] Fixed date-to-string conversion tests to match ICU 51
5aa7e6d [Validator] Added "{{ value }}" parameters where they were missing
f329552 [Validator] Simplified and explained the LuhnValidator
bff09f2 [Validator] Simplified IssnValidator
224e70f [Validator] Fixed and simplified IsbnValidator
fd58870 [Validator] Simplified IBAN validation algorithm
97243bc [Validator] Fixed value-to-string conversion in constraint violations
75e8815 [Validator] Fix constraint violation message parameterization
2014-07-30 14:38:50 +02:00
Bernhard Schussek
32ae95bdda [Validator] Added more detailed inline documentation 2014-07-30 14:36:14 +02:00
Bernhard Schussek
08ea6d3621 [Validator] Removed information from the violation output if the value is an array, object or resource
This was decided in the discussion of #10687.
2014-07-30 14:36:07 +02:00
Yassine Guedidi
777666fac1 [HttpFoundation] Update QUERY_STRING when overrideGlobals 2014-07-30 12:14:11 +02:00
Fabien Potencier
71edf38d59 partially reverted previous commit 2014-07-29 20:14:16 +02:00
Fabien Potencier
e9022adaef fixed CS 2014-07-29 20:09:11 +02:00
Tomáš Polívka
c65b4c7d2d [WebProfilerBundle] turbolinks compatibility 2014-07-29 11:52:49 +02:00
g123456789l
d4323951f2 Update validators.eu.xlf
Spelling of 'CSRF' was incorrect
2014-07-28 11:30:47 +02:00
Fabien Potencier
24cd42555c bug #11475 [EventDispatcher] don't count empty listeners (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[EventDispatcher] don't count empty listeners

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

When event listeners for certain events are removed from the event
dispatcher, empty arrays are not being removed. Therefore, counting
on empty arrays leads to wrong results of the hasListeners() method.

Thanks to @mlindenb for discovering this an proposing a solution.

Commits
-------

fdbb04a [EventDispatcher] don't count empty listeners
2014-07-27 10:29:33 +02:00
Fabien Potencier
ff4a37ff24 minor #11484 remove unused imports (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

remove unused imports

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

Commits
-------

9cd059e remove unused imports
2014-07-27 10:26:10 +02:00
Fabien Potencier
0bce1483c1 fixed CS 2014-07-27 10:25:12 +02:00
Christian Flothmann
9cd059ee1f remove unused imports 2014-07-26 20:24:56 +02:00
WouterJ
be04c5000c Unify null comparisons 2014-07-26 11:54:23 +02:00
Christian Flothmann
fdbb04a6ac [EventDispatcher] don't count empty listeners
When event listeners for certain events are removed from the event
dispatcher, empty arrays are not being removed. Therefore, counting
on empty arrays leads to wrong results of the hasListeners() method.
2014-07-25 17:00:14 +02:00
Romain Neutron
5939d34c17 [Process] Fix unit tests in sigchild environment 2014-07-25 10:39:28 +02:00
Christian Flothmann
eb68662360 [Process] fix signal handling in wait()
wait() throws an exception when the process was terminated by a signal.
This should not happen when the termination was requested by calling
either the stop() or the signal() method (for example, inside a callback
which is passed to wait()).
2014-07-25 10:39:21 +02:00
Fabien Potencier
94ffc4fab2 bug #11469 [BrowserKit] Fixed server HTTP_HOST port uri conversion (bcremer, fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

 [BrowserKit] Fixed server HTTP_HOST port uri conversion

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

See #11356

Commits
-------

103fd88 [BrowserKit] refactor code and fix unquoted regex
f401ab9 Fixed server HTTP_HOST port uri conversion
2014-07-25 08:30:34 +02:00
Fabien Potencier
103fd88b40 [BrowserKit] refactor code and fix unquoted regex 2014-07-25 07:47:26 +02:00
Benjamin Cremer
f401ab9032 Fixed server HTTP_HOST port uri conversion 2014-07-25 07:41:17 +02:00
Fabien Potencier
045cbc53cc bug #11425 Fix issue described in #11421 (Ben, ben-rosio)
This PR was merged into the 2.3 branch.

Discussion
----------

Fix issue described in #11421

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

This pull request fixes the issue described in #11421.  It also adds a test for the issue.  The issue is present in 2.0 forward, but I decided to fix it on the 2.3 branch so that I could also write a test for it (2.0 had no tests for the Process component, and 2.1 and 2.2 didn't have tests for the `ExecutableFinder` class).

Commits
-------

4cf50e8 Bring code into standard
9f4313c [Process] Add test to verify fix for issue #11421
02eb765 [Process] Fixes issue #11421
2014-07-25 07:28:54 +02:00
Fabien Potencier
f5bfa9bc9e bug #11423 Pass a Scope instance instead of a scope name when cloning a container in the GrahpvizDumper (jakzal)
This PR was merged into the 2.3 branch.

Discussion
----------

Pass a Scope instance instead of a scope name when cloning a container in the GrahpvizDumper

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

Commits
-------

6787669 [DependencyInjection] Pass a Scope instance instead of a scope name.
2014-07-25 07:22:20 +02:00
Christian Flothmann
123fc62652 properly handle null data when denormalizing
If null is passed to denormalize(), no property values can be set on
the denormalized object. Additionally, this fixes passing values to
the denormalized object's constructor if the incoming data is an object.
2014-07-24 20:40:16 +02:00
Grégoire Pineau
c9742efe99 [Translator] Use quote to surround invalid locale 2014-07-24 18:59:28 +02:00
Bernhard Schussek
d6a783f989 [Validator] Renamed valueToString() to formatValue(); added missing formatValue() calls 2014-07-24 16:57:54 +02:00
Bernhard Schussek
71897d7e35 [Validator] Fixed CS 2014-07-24 13:57:51 +02:00
Bernhard Schussek
cea4155d39 [Validator] Fixed date-to-string conversion tests to match ICU 51 2014-07-24 13:57:51 +02:00
Bernhard Schussek
5aa7e6dbe0 [Validator] Added "{{ value }}" parameters where they were missing 2014-07-24 13:57:51 +02:00
Bernhard Schussek
f3295522ef [Validator] Simplified and explained the LuhnValidator 2014-07-24 13:57:51 +02:00
Bernhard Schussek
bff09f210b [Validator] Simplified IssnValidator 2014-07-24 13:57:51 +02:00
Bernhard Schussek
224e70f709 [Validator] Fixed and simplified IsbnValidator 2014-07-24 13:57:51 +02:00
Bernhard Schussek
fd58870ac0 [Validator] Simplified IBAN validation algorithm 2014-07-24 13:57:51 +02:00
Bernhard Schussek
97243bcd02 [Validator] Fixed value-to-string conversion in constraint violations 2014-07-24 13:57:51 +02:00
Damián Nohales
75e8815566 [Validator] Fix constraint violation message parameterization 2014-07-24 13:57:51 +02:00
Andrew Moore
c64a75f7bb [Form][Validator] All index items after children are to be considered grand-children when resolving ViolationPath (fixes #11458) 2014-07-23 23:04:43 -04:00
Fabien Potencier
4dbe0e1c34 bug #11120 [2.3][Process] Reduce I/O load on Windows platform (romainneutron)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3][Process] Reduce I/O load on Windows platform

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

When using file handles, no `stream_select` call is done.
On linux platforms, `stream_select` introduce a sleep as it has 0.2s timeout, there is no such pause on Windows, producing lot's of disk I/Os when reading file handles

Commits
-------

ff0bb01 [Process] Reduce I/O load on Windows platform
2014-07-23 17:11:31 +02:00
Fabien Potencier
797d8141e3 bug #11342 [2.3][Form] Check if IntlDateFormatter constructor returned a valid object before using it (romainneutron)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3][Form] Check if IntlDateFormatter constructor returned a valid object before using it

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

`IntlDateFormatter` constructor [may return false](http://www.php.net/manual/en/intldateformatter.create.php#refsect1-intldateformatter.create-returnvalues). This patches avoids fatal errors in these cases

This PR replaces #11334

Commits
-------

ebf967d [Form] Check if IntlDateFormatter constructor returned a valid object before using it
2014-07-23 16:33:41 +02:00
Jérémy Derussé
537c39b11e Optimize assertLocale regexp 2014-07-22 23:54:07 +02:00
Ben
4cf50e8d30 Bring code into standard 2014-07-20 22:50:55 -06:00
Ben
9f4313cf6f [Process] Add test to verify fix for issue #11421 2014-07-19 17:48:53 -06:00
Ben
02eb765a9c [Process] Fixes issue #11421 2014-07-19 17:29:08 -06:00
Jakub Zalas
678766900b [DependencyInjection] Pass a Scope instance instead of a scope name. 2014-07-19 21:50:43 +01:00
Fabien Potencier
9572918064 bug #11411 [Validator] Backported #11410 to 2.3: Object initializers are called only once per object (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Validator] Backported #11410 to 2.3: Object initializers are called only once per object

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

Before, object initializers were called multiple times if an object was validated in different groups in the same validation run. The initializers, however, are not aware of the current validation group, so calling them more than once does not make sense.

Now, object initializers are called exactly once per validated object.

See #11410

Commits
-------

291cbf9 [Validator] Backported #11410 to 2.3: Object initializers are called only once per object
2014-07-18 11:07:06 +02:00
Bernhard Schussek
291cbf9efa [Validator] Backported #11410 to 2.3: Object initializers are called only once per object 2014-07-18 10:20:25 +02:00
Rafał Muszyński
3176f8bb98 [Translator][FrameworkBundle] Added @ to the list of allowed chars in Translator 2014-07-17 12:20:11 +02:00
Fabien Potencier
91e32f810b bug #11381 [2.3] [Process] Use correct test for empty string in UnixPipes (whs, romainneutron)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] [Process] Use correct test for empty string in UnixPipes

| 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

This PR supersedes #11264 : 2.3 compatibility + Windows compatibility + CS fix

Commits
-------

cec0a45 [Process] Adjust PR #11264, make it Windows compatible and fix CS
9e1ea4a [Process] Use correct test for empty string in UnixPipes
2014-07-16 15:02:06 +02:00
Romain Neutron
cec0a45ff5 [Process] Adjust PR #11264, make it Windows compatible and fix CS 2014-07-16 14:40:06 +02:00
Romain Neutron
d4189350c0 [Process] Fix unit tests on Windows platform 2014-07-16 11:55:07 +02:00
Romain Neutron
ff0bb01a91 [Process] Reduce I/O load on Windows platform 2014-07-16 11:39:41 +02:00
Fabien Potencier
ace5a29867 bumped Symfony version to 2.3.19 2014-07-15 21:58:41 +02:00
Fabien Potencier
75e07e6bde updated VERSION for 2.3.18 2014-07-15 16:20:44 +02:00
Jérémy Derussé
06a80fbdbe Validate locales sets intos translator 2014-07-15 15:44:49 +02:00
Fabien Potencier
06fc97ead8 feature #11367 [HttpFoundation] Fix to prevent magic bytes injection in JSONP responses... (CVE-2014-4671) (Andrew Moore)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpFoundation] Fix to prevent magic bytes injection in JSONP responses... (CVE-2014-4671)

| 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
| CVE Ticket   | [CVE-2014-4671](http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2014-4671)
| See Also | [Rosetta Flash](http://miki.it/blog/2014/7/8/abusing-jsonp-with-rosetta-flash/)

\* Unless you are parsing the response string manually, which you really shouldn't do anyway

**THIS IS A SECURITY FIX AND SHOULD BE MERGED SHORTLY**

This fix prevents attacks vectors where third-party browser plugins depends on ASCII magic bytes in order to execute a plugin. This is currently exploited with Flash using a carefully crafted JSONP response, allowing the execution of random SWF data from a domain with a vulnerable JSONP endpoint.

This security issue is mitigated by adding an empty comment right before the callback parameter. This does not affect the execution of the JSONP callback.

Commits
-------

6af3d05 [HttpFoundation] Fix to prevent magic bytes injection in JSONP responses (Prevents CVE-2014-4671)
2014-07-15 15:35:51 +02:00
Fabien Potencier
3c54659baf minor #11387 [2.3] [Validator] Fix UserPassword validator translation (redstar504)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] [Validator] Fix UserPassword validator translation

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

Fixes the UserPassword translation message only for 2.3 as discussed in symfony/symfony#11383.

Commits
-------

73d50ed Fix UserPassword validator translation
2014-07-15 10:15:42 +02:00
redstar504
73d50edc17 Fix UserPassword validator translation 2014-07-13 22:59:18 -07:00
Christopher Davis
8f9ed3ebb9 Remove Spaceless Blocks from Twig Form Templates
In favor of using Twig's whitespace control operators. See #11277
2014-07-13 13:09:52 -04:00
Manatsawin Hanmongkolchai
9e1ea4aa4b [Process] Use correct test for empty string in UnixPipes 2014-07-12 16:25:05 +02:00
Fabien Potencier
ea45769aab fixed typo 2014-07-11 11:32:34 +02:00
Andrew Moore
6af3d05b85 [HttpFoundation] Fix to prevent magic bytes injection in JSONP responses (Prevents CVE-2014-4671) 2014-07-10 09:27:11 -04:00
Christophe Coevoet
ca69dbba43 minor #11362 [2.3][HttpFoundation] Fix wrong assertion in Response test (stloyd)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3][HttpFoundation] Fix wrong assertion in Response test

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

Commits
-------

3d63f80 [HttpFoundation] Fix wrong assertion in Response test
2014-07-10 11:13:00 +02:00
Luis Cordova
9aa88e4494 added regression test 2014-07-10 10:55:37 +02:00
Matthew Davis
4201d419a2 fix issue #8171 on configuration tree for twig extension -- pairing up with @cordoval 2014-07-10 10:55:33 +02:00
Joseph Bielawski
3d63f801ff [HttpFoundation] Fix wrong assertion in Response test 2014-07-10 09:54:15 +02:00
Joseph Bielawski
a67bc7612e [2.3][Form] Cleanup & fix phpdocs 2014-07-09 12:39:32 +02:00
Fabien Potencier
5955f8edfe fixed CS 2014-07-09 11:04:31 +02:00
Simon Schick
9dbe89dba6 [HttpFoundation] Remove content-related headers if content is empty 2014-07-09 11:03:31 +02:00
Fabien Potencier
cc84d95787 minor #11344 remove defaults from PHPUnit configuration (craue)
This PR was merged into the 2.3 branch.

Discussion
----------

remove defaults from PHPUnit configuration

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

Follow-up to #11329.

Commits
-------

afc4930 removed defaults from PHPUnit configuration
2014-07-08 21:12:37 +02:00
Fabien Potencier
bf72e871f6 bumped Symfony version to 2.3.18 2014-07-08 13:19:32 +02:00