Commit Graph

22368 Commits

Author SHA1 Message Date
Jose Gonzalez
520bd26642 [Yaml] Fix the parsing of float keys 2015-09-13 18:26:34 +01:00
Fabien Potencier
e2156d7c2c bug #15771 [Console] Ensure the console output is only detected as decorated when both stderr and stdout support colors (Seldaek)
This PR was merged into the 2.3 branch.

Discussion
----------

[Console] Ensure the console output is only detected as decorated when both stderr and stdout support colors

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

This is a simplified version of #13661 which does not create any issues with having two decorators but merely ensures that if either STDERR **or** STDOUT has colors disabled, then both will have decoration disabled. It's not a perfect solution but it's better than having both enabled as this breaks things. And I don't think we can come to a better solution without api changes.

Commits
-------

f3d8444 [Console] Ensure the console output is only detected as decorated when both stderr and stdout support colors
2015-09-13 13:30:23 +02:00
Fabien Potencier
fbba5d95cc feature #15773 Make the exception output visible even in quiet mode, fixes #15680 (Seldaek)
This PR was merged into the 2.8 branch.

Discussion
----------

Make the exception output visible even in quiet mode, fixes #15680

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

This builds upon #15772 and sets the exception output in Application::renderException to use VERBOSITY_QUIET so that exceptions are always visible. IMO it's a good change but I can see that it is potentially controversial.

Commits
-------

e9ee8f5 Make the exception output visible even in quiet mode, fixes #15680
2015-09-13 13:29:07 +02:00
Fabien Potencier
209f1fcc27 feature #15772 Convert Output::write's type to an options arg where verbosity can be passed in as well (Seldaek)
This PR was merged into the 2.8 branch.

Discussion
----------

Convert Output::write's type to an options arg where verbosity can be passed in as well

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

Commits
-------

749fba5 Convert Output::write's type to an options arg where verbosity can be passed in as well
2015-09-13 13:27:52 +02:00
Jordi Boggiano
e9ee8f559d Make the exception output visible even in quiet mode, fixes #15680 2015-09-12 23:39:36 +01:00
Jordi Boggiano
749fba54f9 Convert Output::write's type to an options arg where verbosity can be passed in as well 2015-09-12 23:35:49 +01:00
Jordi Boggiano
f3d844434b [Console] Ensure the console output is only detected as decorated when both stderr and stdout support colors 2015-09-12 19:38:39 +01:00
Fabien Potencier
a9555fb98f minor #15767 [Validator] mark test as legacy (TomasVotruba)
This PR was merged into the 2.8 branch.

Discussion
----------

[Validator] mark test as legacy

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

Ref https://github.com/symfony/symfony/pull/15708#discussion_r39246000

Failing test are hhvm binaries: https://travis-ci.org/symfony/symfony/jobs/79951993#L530

Commits
-------

cf18a99 [Validator] mark test as legacy
2015-09-12 12:03:37 +02:00
Tomas Votruba
cf18a997fb [Validator] mark test as legacy 2015-09-12 10:46:41 +02:00
Fabien Potencier
238531fea1 bug #15750 Add tests to the recently added exceptions thrown from YamlFileLoaders (jakzal)
This PR was merged into the 2.3 branch.

Discussion
----------

Add tests to the recently added exceptions thrown from YamlFileLoaders

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

* use the `Symfony\Component\DependencyInjection\Exception\InvalidArgumentException` in the DI component
* add tests

Commits
-------

93e418f Improve exception messages.
2015-09-11 17:27:18 +02:00
Fabien Potencier
bee5c61093 bug #15763 [HttpKernel] fix DumpDataCollector compat with Twig 2.0 (nicolas-grekas)
This PR was merged into the 2.7 branch.

Discussion
----------

[HttpKernel] fix DumpDataCollector compat with Twig 2.0

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

See https://github.com/twigphp/Twig/pull/1813

Commits
-------

92e50a3 [HttpKernel] fix DumpDataCollector compat with Twig 2.0
2015-09-11 15:10:24 +02:00
Nicolas Grekas
92e50a3b14 [HttpKernel] fix DumpDataCollector compat with Twig 2.0 2015-09-11 14:32:48 +02:00
Abdellatif Ait boudad
f29dd93d5c feature #15756 [Translation] added option json_options to JsonFileDumper. (gepo)
This PR was merged into the 2.8 branch.

Discussion
----------

[Translation] added option json_options to JsonFileDumper.

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

Replaces #14750

Commits
-------

bfdc354 [Translation] added option flags to JsonFileDumper. It's passed to json_encode function second argument.
2015-09-11 11:34:42 +00:00
Gennady Telegin
bfdc35439b [Translation] added option flags to JsonFileDumper.
It's passed to json_encode function second argument.
2015-09-11 09:07:49 +00:00
Jakub Zalas
93e418f48e Improve exception messages. 2015-09-11 08:57:18 +01:00
Nicolas Grekas
f8fa136652 Hot fix 2015-09-10 20:17:51 +02:00
Nicolas Grekas
8bc6df3731 minor #15754 [HttpKernel] Fix RequestStack argument position and deprecated behavior (nicolas-grekas)
This PR was merged into the 2.8 branch.

Discussion
----------

[HttpKernel] Fix RequestStack argument position and deprecated behavior

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

Commits
-------

51b6d74 [HttpKernel] Fix RequestStack argument position and deprecated behavior
2015-09-10 19:22:54 +02:00
Fabien Potencier
d8a801a70a bug #15718 Fix that two DirectoryResources with different patterns would be deduplicated (mpdude)
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes #15718).

Discussion
----------

Fix that two DirectoryResources with different patterns would be deduplicated

| 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

ResourceInterface::__toString is mainly important because in various places, array_uniqe() is called to perform a de-duplication of resources and will use the string representation for objects.

Thus, we need to take care that if DirectoryResources apply different patterns they must be kept after array_unique calls.

Commits
-------

2b36ac5 Fix that two DirectoryResources with different patterns would be deduplicated
2015-09-10 14:19:00 +02:00
Matthias Pigulla
2b36ac5a61 Fix that two DirectoryResources with different patterns would be deduplicated
ResourceInterface::__toString is mainly important because in various places, array_uniqe() is called to perform a de-duplication of resources and will use the string representation for objects.

Thus, we need to take care that if DirectoryResources apply different patterns they must be kept after array_unique calls.
2015-09-10 14:18:59 +02:00
Fabien Potencier
cfd8cc24ff minor #15746 Tests fix clockmock (ewgRa)
This PR was squashed before being merged into the 2.3 branch (closes #15746).

Discussion
----------

Tests fix clockmock

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

On my local computer tests for HttpCacheTest not passed, because ClockMock make side effects on another tests (it takes time from _SERVER['REQUEST_TIME'] and for my computer difference with real one time and this time was more than expected by HttpCacheTest, one part of code take time from mock, anothers - from native time function). This PR remove this side effects.

Commits
-------

6b21752 Tests fix clockmock
2015-09-10 13:45:38 +02:00
Evgeniy Sokolov
6b21752285 Tests fix clockmock 2015-09-10 13:45:33 +02:00
Abdellatif Ait boudad
2ae2714dbf bug #15516 [Translator][warmup][fallback locales] fixed missing cache file generation. (aitboudad)
This PR was merged into the 2.7 branch.

Discussion
----------

[Translator][warmup][fallback locales] fixed missing cache file generation.

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

Commits
-------

cade651 [Translator][warmup][fallback locales] fixed missing cache file generation.
2015-09-10 11:41:15 +00:00
Nicolas Grekas
51b6d74557 [HttpKernel] Fix RequestStack argument position and deprecated behavior 2015-09-10 12:52:08 +02:00
Fabien Potencier
6c9f86ba4b bug #14916 [WebProfilerBundle] Added tabindex="-1" to not interfer with normal UX (drAlberT)
This PR was submitted for the 2.7 branch but it was merged into the 2.3 branch instead (closes #14916).

Discussion
----------

[WebProfilerBundle] Added tabindex="-1" to not interfer with normal UX

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

Commits
-------

53cdb1a [WebProfilerBundle] Added tabindex="-1" to not interfer with normal UX
2015-09-10 10:15:18 +02:00
AlberT
53cdb1a420 [WebProfilerBundle] Added tabindex="-1" to not interfer with normal UX 2015-09-10 10:15:17 +02:00
Nicolas Grekas
4b68eb1f3e Merge branch '2.7' into 2.8
* 2.7:
  [Validator] Added Swedish translations
  improve exceptions when parsing malformed files
  Dispatch console.terminate *after* console.exception
2015-09-10 10:08:06 +02:00
Nicolas Grekas
249d130549 Merge branch '2.3' into 2.7
* 2.3:
  [Validator] Added Swedish translations
  improve exceptions when parsing malformed files
  Dispatch console.terminate *after* console.exception

Conflicts:
	src/Symfony/Component/Console/Application.php
	src/Symfony/Component/Console/Tests/ApplicationTest.php
	src/Symfony/Component/Validator/Resources/translations/validators.sv.xlf
2015-09-10 10:05:42 +02:00
Fabien Potencier
1c5a213ec0 minor #15749 missing "YAML" in the exception message. (DavidBadura)
This PR was merged into the 2.3 branch.

Discussion
----------

missing "YAML" in the exception message.

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

Commits
-------

b95b5e2 missing "YAML" in the exception message.
2015-09-10 09:52:27 +02:00
David Badura
b95b5e217f missing "YAML" in the exception message. 2015-09-10 09:43:17 +02:00
Fabien Potencier
d1c51a341d feature #15724 [HttpKernel] Move required RequestStack args as first arguments (nicolas-grekas)
This PR was merged into the 2.8 branch.

Discussion
----------

[HttpKernel] Move required RequestStack args as first arguments

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

Since we planned to make RequestStack required, we have to move it as first arguments.

Commits
-------

84ba05b [HttpKernel] Move required RequestStack args as first arguments
2015-09-10 09:40:22 +02:00
Fabien Potencier
f1c01ed5ac feature #15521 [Debug] Add BufferingLogger for errors that happen before a proper logger is configured (nicolas-grekas)
This PR was merged into the 2.8 branch.

Discussion
----------

[Debug] Add BufferingLogger for errors that happen before a proper logger is configured

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

This allows catching e.g. deprecations that happen during bootstrapping.

Commits
-------

2a9647d [Debug] Add BufferingLogger for errors that happen before a proper logger is configured
2015-09-10 09:37:44 +02:00
Fabien Potencier
37827a2fef bug #15725 Dispatch console.terminate *after* console.exception (Seldaek)
This PR was merged into the 2.3 branch.

Discussion
----------

Dispatch console.terminate *after* console.exception

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

The problem is when using the ConsoleHandler from MonologBridge, TERMINATE closes it and removes the output, so when EXCEPTION fires if you want to log the exception it's too late and you don't get any output. See ed4fb54901/src/Symfony/Bridge/Monolog/Handler/ConsoleHandler.php (L115-L145)

It is my understanding that TERMINATE is always supposed to come last anyway, so it is a bug in any case, but this particular use case is what prompted the discovery.

Commits
-------

7802345 Dispatch console.terminate *after* console.exception
2015-09-10 08:54:37 +02:00
Fabien Potencier
1e27c85a3b bug #15731 improve exceptions when parsing malformed files (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

improve exceptions when parsing malformed files

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

Commits
-------

3849cd8 improve exceptions when parsing malformed files
2015-09-10 08:51:50 +02:00
Fabien Potencier
0383559f95 feature #15709 [WebProfilerBundle] deprecated import/export commands (fabpot)
This PR was merged into the 2.8 branch.

Discussion
----------

[WebProfilerBundle] deprecated import/export commands

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

Commits
-------

943fec9 [HtppKernel] deprecated Profiler::import/export
17e00b9 [WebProfilerBundle] deprecated import/export commands
2015-09-09 23:21:50 +02:00
Fabien Potencier
224b19b4a2 bug #15744 [WebProfilerBundle ] Removes ajax animation in sf-toolbar-block-ajax (oyepez003)
This PR was merged into the 2.8 branch.

Discussion
----------

[WebProfilerBundle ] Removes ajax animation in sf-toolbar-block-ajax

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

The change removes the animation in the "sf-toolbar-block-ajax" when the request state was "ok".

Commits
-------

8497ad7 [WebProfilerBundle ] Removes the ajax animation in | sf-toolbar-block-ajax
2015-09-09 23:18:58 +02:00
Fabien Potencier
943fec97d3 [HtppKernel] deprecated Profiler::import/export 2015-09-09 22:55:09 +02:00
Fabien Potencier
5b404fc283 minor #15713 [Validator] Added Swedish translations (Nyholm)
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes #15713).

Discussion
----------

[Validator] Added Swedish translations

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

This was another easy pick.

Commits
-------

1176d62 [Validator] Added Swedish translations
2015-09-09 22:42:37 +02:00
Tobias Nyholm
1176d6279a [Validator] Added Swedish translations 2015-09-09 22:42:29 +02:00
Omar Yepez
8497ad7ce9 [WebProfilerBundle ] Removes the ajax animation in | sf-toolbar-block-ajax
| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | n/a
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

The change removes the animation in the "sf-toolbar-block-ajax" when the request state was "ok".
2015-09-09 15:09:41 -04:30
Tobias Schultze
14c538eb39 2.8 changes from #15733 2015-09-09 20:09:35 +02:00
Tobias Schultze
3bae5f7aa9 Merge branch '2.7' into 2.8
Conflicts:
	src/Symfony/Component/HttpKernel/Kernel.php
2015-09-09 20:05:45 +02:00
Tobias Schultze
4ecbc7053d Merge branch '2.3' into 2.7
Conflicts:
	src/Symfony/Component/Form/Tests/FormFactoryTest.php
	src/Symfony/Component/HttpKernel/Kernel.php
2015-09-09 20:00:08 +02:00
Tobias Schultze
b38e448f42 fix leftover changes from previous merge 2015-09-09 19:53:06 +02:00
Tobias Schultze
7c3748ce01 minor #15733 fix class use and in phpdoc (ewgRa)
This PR was submitted for the 2.8 branch but it was merged into the 2.7 branch instead (closes #15733).

Discussion
----------

fix class use and in phpdoc

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

Just some fixes from code inspection.

Commits
-------

f0d40c4 fix class use and in phpdoc
2015-09-09 19:43:02 +02:00
Evgeniy Sokolov
f0d40c4559 fix class use and in phpdoc 2015-09-09 19:42:36 +02:00
Tobias Schultze
ac822f9c9b bug #15737 Fix the injection of the container in invokable controllers (stof)
This PR was merged into the 2.7 branch.

Discussion
----------

Fix the injection of the container in invokable controllers

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

https://github.com/symfony/symfony/pull/12022 added the necessary extension point in the ControllerResolver to hook into the instantiation (in 2.6+), but has not updated FrameworkBundle to use it.

I also reused the parent ``createController`` method instead of duplicating its code

Commits
-------

36e09da Fix the injection of the container in invokable controllers
2015-09-09 19:22:38 +02:00
Tobias Schultze
685a1cf6f4 minor #15740 Remove wrong deprecation triggers for forms in the DI extension (stof)
This PR was merged into the 2.8 branch.

Discussion
----------

Remove wrong deprecation triggers for forms in the DI extension

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

When a form type provides a BC layer with old form names (all core types do), the form registry will ask for type extensions registered on the legacy name for BC, and trigger a warning if it finds any.
The DependencyInjectionExtension should not trigger warnings on its own when being asked for such extensions (especially when it has none registered). this means that the extension does not even need to know whether the name is a legacy one or a new one btw.
Core extensions are also registered using the proper extended type rather than legacy names.

Commits
-------

e42adf7 Remove wrong deprecation triggers for forms in the DI extension
2015-09-09 17:55:06 +02:00
Abdellatif Ait boudad
cade651915 [Translator][warmup][fallback locales] fixed missing cache file generation. 2015-09-09 14:57:38 +00:00
Christophe Coevoet
e42adf7818 Remove wrong deprecation triggers for forms in the DI extension
When a form type provides a BC layer with old form names (all core types
do), the form registry will ask for type extensions registered on the
legacy name for BC, and trigger a warning if it finds any.
The DependencyInjectionExtension should not trigger warnings on its own
when being asked for such extensions (especially when it has none
registered).
Core extensions are also registered using the proper extended type
rather than legacy names.
2015-09-09 16:30:53 +02:00
Christophe Coevoet
36e09da4b9 Fix the injection of the container in invokable controllers 2015-09-09 14:19:27 +02:00