Commit Graph

20979 Commits

Author SHA1 Message Date
Fabien Potencier
49cbf1c7d1 minor #14097 [2.3] Static Code Analysis for Components (kalessil)
This PR was squashed before being merged into the 2.3 branch (closes #14097).

Discussion
----------

[2.3] Static Code Analysis for Components

| 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

Static Code Analysis with Php Inspections (EA Extended), no functional changes:
- array_keys/array_values usage as foreach array
- foreach value by reference - added unsets to keep scope clear
- strstr usage as strpos fixed
- array_push miss-use resolved

Commits
-------

78cc93c [2.3] Static Code Analysis for Components
2015-04-15 16:34:30 +02:00
Vladimir Reznichenko
78cc93c3b2 [2.3] Static Code Analysis for Components 2015-04-15 16:34:28 +02:00
Nicolas Grekas
92e33e482f [WebProfilerBundle] Fix resiliency to exceptions thrown by the url generator 2015-04-15 09:58:17 +02:00
Christian Flothmann
5d7a4f99f7 [Translation] LoggingTranslator simplifications 2015-04-15 00:06:07 +02:00
Christian Flothmann
f36803eb00 [EventDispatcher] make listeners removable from an executed listener 2015-04-14 22:43:17 +02:00
Christian Flothmann
d66d75dddc [Translation] DataCollectorTranslator clarifications 2015-04-14 20:42:21 +02:00
Abdellatif Ait boudad
cbffabff37 bug #14315 [Translation] Revert inlining fallback catalogues as it might cause inconsistent results when a cache is used (mpdude)
This PR was merged into the 2.7 branch.

Discussion
----------

[Translation] Revert inlining fallback catalogues as it might cause inconsistent results when a cache is used

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

The results from `getCatalogue()` are inconsistent when we're in production *and* a cache comes into play.

This is due to the changes in 6eb5e7395c, where the fallback catalogues will be *merged* into the primary catalogue when it is written to the cache.

Strictly speaking, this is a BC break because it behaved differently before.

I am not sure what the relevance of this might be in practice.

However, it may cause headaches because
* The result changes only in the second+ try (when the cache is warm); a priori you cannot tell whether you're going to see this
* The catalogue is clearly not what the loader provided
* You have no chance of telling whether the message was originally available in the catalogue or not
* Generally, for every message you retrieve from the catalogue, you have no way of telling which locale it actually comes from (it need not be from the catalogue's locale, and the catalogue does not provide fallback catalogues either)

Regarding the last point, you usually don't care when using the `Translator`. Its purpose is to get the "best" translation available. However, when you bother to explicitly retrieve the catalogue, chances are your intentions are different.

Commits
-------

12a183a Revert inlining the fallback messages in production that was added in 6eb5e7395c
2015-04-14 09:32:15 +01:00
Abdellatif Ait boudad
04b8e4e77e [Translation][fixed test] refresh cache when resources are no longer fresh. 2015-04-14 08:53:08 +01:00
Fabien Potencier
85a494c12d bug #14129 [FrameworkBundle] Fixed server:start --router relative path issue #14124 (abulford)
This PR was squashed before being merged into the 2.6 branch (closes #14129).

Discussion
----------

[FrameworkBundle] Fixed server:start --router relative path issue #14124

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

This ensures that a relative path can be used to specify the router script, and that if the router script cannot be found an error is reported and the command fails.

The file path for the router script is now determined and checked prior to the child process being forked, which seems cleaner.  The same change could be made in ServerRunCommand.php, or possibly in the ServerCommand base class; to keep the scope small, though, this wasn't done as part of this bug fix.

Commits
-------

0c1b9ba [FrameworkBundle] Fixed server:start --router relative path issue #14124
2015-04-13 17:33:55 +02:00
abulford
0c1b9bacd8 [FrameworkBundle] Fixed server:start --router relative path issue #14124 2015-04-13 17:33:51 +02:00
Christian Flothmann
71d84e66e4 [FrameworkBundle] improve usage of Table helper
Use the `Table` helper if present in favor of the deprecated
`TableHelper` class.
2015-04-13 17:21:02 +02:00
Matthias Pigulla
12a183a983 Revert inlining the fallback messages in production that was added in 6eb5e7395c
Also add a test that shows where this would cause inconsistent behaviour of the getFallbackCatalogue() method.
2015-04-13 13:42:58 +02:00
Baptiste Dupuch
c3eecb591d Add better phpdoc message for getListeners method of the EventDispatcher 2015-04-13 12:57:04 +02:00
Abdellatif Ait boudad
9b4f00c7ab [2.7][Translation][change log] added DataCollectorTranslator. 2015-04-12 23:10:02 +01:00
Fabien Potencier
5d428b7091 minor #14324 [Validator] Added missing Simplified Chinese (zh_CN) translations (foxwoods)
This PR was merged into the 2.3 branch.

Discussion
----------

[Validator] Added missing Simplified Chinese (zh_CN) translations

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

Added the missing Mandarin Chinese translations.

Commits
-------

c0f0258 [Validator] Added missing Simplified Chinese (zh_CN) translations
2015-04-12 20:28:23 +02:00
Jingyu Wang
c0f0258c56 [Validator] Added missing Simplified Chinese (zh_CN) translations 2015-04-12 10:14:47 +08:00
Tobias Schultze
e00f037472 minor #14323 Use PSR-4 everywhere instead of PSR-0 (Tobion, Seldaek)
This PR was merged into the 2.7 branch.

Discussion
----------

Use PSR-4 everywhere instead of PSR-0

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

Rebased and updated #12466

Commits
-------

8072213 adjust phpdoc for class not found handler
e2bbf07 add phpunit bridge to psr4
60d4994 Tweak classmap paths
cc17234 Add two more components to psr-4
17f61af Add psr-4 support to the ClassNotFoundFatalErrorHandler
4e85901 Use PSR-4 everywhere instead of PSR-0
2015-04-12 00:30:26 +02:00
Tobias Schultze
8072213afe adjust phpdoc for class not found handler 2015-04-12 00:21:29 +02:00
Tobias Schultze
e2bbf074b5 add phpunit bridge to psr4 2015-04-11 23:43:46 +02:00
Jordi Boggiano
60d4994e70 Tweak classmap paths 2015-04-11 23:38:34 +02:00
Jordi Boggiano
cc17234464 Add two more components to psr-4 2015-04-11 23:38:34 +02:00
Jordi Boggiano
17f61afe08 Add psr-4 support to the ClassNotFoundFatalErrorHandler 2015-04-11 23:38:33 +02:00
Tobias Schultze
4e85901380 Use PSR-4 everywhere instead of PSR-0 2015-04-11 23:38:32 +02:00
Joshua Thijssen
6150c3a72b Removed duplicated toRegex() code 2015-04-11 21:29:31 +02:00
Fabien Potencier
37611405e5 bug #14313 [HttpKernel] fixed a regression when no exception listeners are registered (fabpot)
This PR was merged into the 2.7 branch.

Discussion
----------

[HttpKernel] fixed a regression when no exception listeners are registered

| 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 fixes a regression in 2.7. When no exception listeners are registered, the original exception should not be wrapped by the exception management layer of HttpKernel.

Commits
-------

27930fb [HttpKernel] fixed a regression when no exception listeners are registered
2015-04-11 10:42:37 +02:00
Fabien Potencier
27930fb626 [HttpKernel] fixed a regression when no exception listeners are registered 2015-04-11 10:15:54 +02:00
Fabien Potencier
bab6db59b5 Merge branch '2.6' into 2.7
* 2.6:
  renamed some confusing tests
  [2.3] Fix @link annotations
  [2.6] Fix @link annotations
  Fix javascript
  [2.3][Translation] test refresh cache when resources File change.
  [Translator] Cache does not take fallback locales into consideration

Conflicts:
	src/Symfony/Bundle/FrameworkBundle/Tests/Translation/TranslatorTest.php
	src/Symfony/Component/Form/Extension/HttpFoundation/EventListener/BindRequestListener.php
	src/Symfony/Component/HttpKernel/Tests/HttpKernelTest.php
	src/Symfony/Component/Validator/ValidatorInterface.php
2015-04-11 09:21:47 +02:00
Fabien Potencier
234cebd087 Merge branch '2.3' into 2.6
* 2.3:
  renamed some confusing tests
  [2.3] Fix @link annotations
  Fix javascript
  [2.3][Translation] test refresh cache when resources File change.
  [Translator] Cache does not take fallback locales into consideration

Conflicts:
	src/Symfony/Bundle/FrameworkBundle/Tests/Translation/TranslatorTest.php
	src/Symfony/Bundle/FrameworkBundle/Translation/Translator.php
2015-04-11 09:16:15 +02:00
Fabien Potencier
8b7148fbec minor #14312 renamed some confusing tests (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

renamed some confusing tests

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

Commits
-------

a8e4c43 renamed some confusing tests
2015-04-11 08:59:48 +02:00
Fabien Potencier
a8e4c43080 renamed some confusing tests 2015-04-11 08:39:49 +02:00
Fabien Potencier
984220508b minor #14308 [2.7] For @link annotations (nicolas-grekas)
This PR was merged into the 2.7 branch.

Discussion
----------

[2.7] For @link annotations

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

It would be great if PHP CS Fixer could enforce this.

Commits
-------

07cb92f [2.7] For @link annotations
2015-04-11 07:17:57 +02:00
Fabien Potencier
624be35038 minor #14309 [2.6] Fix @link annotations (nicolas-grekas)
This PR was merged into the 2.6 branch.

Discussion
----------

[2.6] Fix @link annotations

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

It would be great if PHP CS Fixer could enforce this.

Commits
-------

fb077a2 [2.6] Fix @link annotations
2015-04-11 07:17:31 +02:00
Fabien Potencier
08f4d29c72 minor #14310 [2.3] Fix @link annotations (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] Fix @link annotations

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

It would be great if PHP CS Fixer could enforce this.

Commits
-------

c1983ca [2.3] Fix @link annotations
2015-04-11 07:16:37 +02:00
Tobias Schultze
e4385083cb minor #14311 propel/propel1 is now useless (DavidPrevot)
This PR was merged into the 2.7 branch.

Discussion
----------

propel/propel1 is now useless

Since Propel bridge has been removed, no need to require it anymore for
development.

Commits
-------

bea4be0 propel/propel1 is now useless
2015-04-11 02:48:23 +02:00
David Prévot
bea4be00ea propel/propel1 is now useless
Since Propel bridge has been removed, no need to require it anymore for
development.
2015-04-10 17:34:32 -04:00
Fabien Potencier
7a71741875 bumped Symfony version to 2.7.0 2015-04-10 22:45:42 +02:00
Fabien Potencier
07379d1d80 updated VERSION for 2.7.0-BETA1 2015-04-10 21:52:02 +02:00
Fabien Potencier
6944fb122d updated CHANGELOG for 2.7.0-BETA1 2015-04-10 21:51:44 +02:00
Nicolas Grekas
c1983cad4d [2.3] Fix @link annotations 2015-04-10 20:54:05 +02:00
Nicolas Grekas
07cb92f003 [2.7] For @link annotations 2015-04-10 20:53:33 +02:00
Nicolas Grekas
fb077a2748 [2.6] Fix @link annotations 2015-04-10 20:22:21 +02:00
Fabien Potencier
c764a84a27 minor #14299 [2.3] Fix javascript (SpacePossum)
This PR was merged into the 2.3 branch.

Discussion
----------

[2.3] Fix javascript

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

Remove dead code and add missing semicolons.

Commits
-------

df76126 Fix javascript
2015-04-10 17:35:17 +02:00
Fabien Potencier
8115b0b977 minor #14303 [Config][cache factory] check type of callback argument. (aitboudad)
This PR was merged into the 2.7 branch.

Discussion
----------

[Config][cache factory] check type of callback argument.

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

/cc @mpdude

Commits
-------

11f798c [Config][cache factory] check type of callback argument.
2015-04-10 17:34:19 +02:00
Fabien Potencier
0ea25a9515 bug #14286 [WebProfiler] Added deprecation message and original color back (WouterJ)
This PR was merged into the 2.7 branch.

Discussion
----------

[WebProfiler] Added deprecation message and original color back

For some reason, the deprecation message and its original yellow color were removed. This means that you don't know the error (without a stack, you would just see an empty bar) and they aren't easy to find anymore in a long list of logs (yeah, the filter can be used...).

**Before**
![sf-logger-deprecation-before](https://cloud.githubusercontent.com/assets/749025/7062927/4094d5d4-dea2-11e4-80e2-c13a02d6d748.png)

**After**
![sf-logger-deprecation-after](https://cloud.githubusercontent.com/assets/749025/7062930/475fc2b6-dea2-11e4-978f-0f18262f283c.png)

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

Commits
-------

773df8c Added deprecation message and original color back
2015-04-10 17:32:48 +02:00
Fabien Potencier
6c721658e7 bug #14283 [2.7][Console] Count the $messages array instead of $message (barryvdh)
This PR was squashed before being merged into the 2.7 branch (closes #14283).

Discussion
----------

[2.7][Console] Count the $messages array instead of $message

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

I think you mean $messages instead of $message. With this patch, the number of messages is correctly counted.

Commits
-------

95aa167 [2.7][Console] Count the  array instead of
2015-04-10 17:31:32 +02:00
Barry vd. Heuvel
95aa167d7c [2.7][Console] Count the array instead of 2015-04-10 17:31:30 +02:00
Abdellatif Ait boudad
11f798cf41 [Config][cache factory] check type of callback argument. 2015-04-10 14:54:53 +01:00
Fabien Potencier
1e121e619c minor #14295 removed 3.0 constraints from 2.7 composer files (fabpot)
This PR was merged into the 2.7 branch.

Discussion
----------

removed 3.0 constraints from 2.7 composer files

| 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

Those 3.0 constraints will be kept in the new 2.8.

Commits
-------

5503804 removed 3.0 constraints from 2.7 composer files
2015-04-10 10:51:45 +02:00
Fabien Potencier
b8f2a6b901 feature #14229 [WebProfilerBundle] AJAX links (romqin)
This PR was submitted for the 2.6 branch but it was merged into the 2.7 branch instead (closes #14229).

Discussion
----------

[WebProfilerBundle] AJAX links

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

It is considered as a new feature ? If yes, should I make it on 2.7 ?

Add a link on GET requests:
![capture d ecran 2015-04-06 a 11 47 33](https://cloud.githubusercontent.com/assets/334432/7002965/1ff200fa-dc53-11e4-96de-664572f72b57.png)

Commits
-------

b9062a0 add link on GET requests
2015-04-10 10:50:44 +02:00
Romain Gautier
b9062a0c87 add link on GET requests 2015-04-10 10:50:43 +02:00