Commit Graph

22690 Commits

Author SHA1 Message Date
Nicolas Grekas
4d275b42da Merge branch '2.7' into 2.8
* 2.7:
  [Finder] Fix recursive filter iterator
  Improve the structure of the Finder testsuite
  [VarDumper] Fix HtmlDumper constructor calling CliDumper's
  [Finder] Handle filtering of recursive iterators and use it to skip looping over excluded directories
  Exclude files based on path before applying the sorting
  fixed composer.json
  [Console] fix phpdoc of DialogHelper
  Allowed extensions to inline compiler passes
2015-09-18 09:20:16 +02:00
Nicolas Grekas
666f523984 Merge branch '2.3' into 2.7
* 2.3:
  [Finder] Fix recursive filter iterator
  Improve the structure of the Finder testsuite

Conflicts:
	src/Symfony/Component/Finder/Iterator/ExcludeDirectoryFilterIterator.php
	src/Symfony/Component/Finder/Tests/FinderTest.php
	src/Symfony/Component/Finder/Tests/Iterator/DateRangeFilterIteratorTest.php
2015-09-18 09:19:55 +02:00
Alexander Schwenn
b5599a5897 [Form] Fix php warning on invalid FormFactory::createBuilder() argument 2015-09-17 23:09:48 +02:00
Abdellatif Ait boudad
327c647be5 feature #15699 [Translator][FileDumper] deprecated format method in favor of formatCatalogue. (aitboudad)
This PR was merged into the 2.8 branch.

Discussion
----------

[Translator][FileDumper] deprecated format method in favor of formatCatalogue.

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

We introduced `formatCatalogue` to allow using options passed to the dump method.

Commits
-------

366879b [Translator][FileDumper] deprecated format method in favor of formatCatalogue.
2015-09-17 17:05:31 +00:00
Nicolas Grekas
89d75af805 bug #15804 [VarDumper] Fix HtmlDumper constructor calling CliDumper's (nicolas-grekas)
This PR was merged into the 2.7 branch.

Discussion
----------

[VarDumper] Fix HtmlDumper constructor calling CliDumper's

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/var-dumper/pull/2#issuecomment-140338205
| License       | MIT
| Doc PR        | -

Commits
-------

4c7bb9c [VarDumper] Fix HtmlDumper constructor calling CliDumper's
2015-09-17 14:16:46 +02:00
Nicolas Grekas
4a9676b5a2 minor #15824 [Finder] Fix recursive filter iterator (nicolas-grekas)
This PR was merged into the 2.3 branch.

Discussion
----------

[Finder] Fix recursive filter iterator

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

#15802 was broken because the filters where not propagated to children iterators. This fixes the issue and adds a test case for this situation. The RecursiveIterator implementation is moved from FilterIterator to ExcludeDirectoryFilterIterator. Doing so on other filters is possible but would be a new feature that is not required for fixing the performance issue we had previously.

Commits
-------

cf3019b [Finder] Fix recursive filter iterator
2015-09-17 14:15:24 +02:00
Nicolas Grekas
cf3019bc5a [Finder] Fix recursive filter iterator 2015-09-17 10:48:13 +02:00
Martin Hasoň
184d4f2df0 [WebProfilerBundle] Added collapsed sidebar on small screens 2015-09-17 10:17:00 +02:00
Tobias Schultze
a7b7f5479e [EventDispatcher] skip one lazy loading call 2015-09-17 03:42:05 +02:00
Tobias Schultze
ec59953f4c [EventDispatcher] fix memory leak in a getListeners 2015-09-17 03:14:14 +02:00
Abdellatif Ait boudad
366879ba83 [Translator][FileDumper] deprecated format method in favor of formatCatalogue. 2015-09-16 14:54:16 +00:00
Abdellatif Ait boudad
7b358a144a feature #15717 [Translator][Loader] added XLIFF 2.0 support. (xphere, aitboudad)
This PR was merged into the 2.8 branch.

Discussion
----------

[Translator][Loader] added XLIFF 2.0 support.

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

Commits
-------

0c24d55 [Translation][Dumper] added XLIFF 2.0 support.
7af4fc7 [XLIFF 2.0] added support for target attributes.
ace6042 apply some fixes.
ce540ae update changelog.
ff5d6a3 [Translation][Loader] added XLIFF 2.0 support.
2015-09-16 14:51:54 +00:00
Richard Quadling
bca67712d0 Update Process.php
Stop autoruns when shelling on Windows.

Original PR was on https://github.com/symfony/Process/pull/9#issuecomment-140721398.
2015-09-16 14:19:29 +01:00
Abdellatif Ait boudad
ac7591f505 [WebProfilerBundle] added btn-link. 2015-09-16 12:52:37 +00:00
Fabien Potencier
f3b6ffc85a minor #15812 [WebProfilerBundle] bug #15811 use of twig deprecated sameas test (ctrl-f5)
This PR was merged into the 2.8 branch.

Discussion
----------

[WebProfilerBundle] bug #15811 use of twig deprecated sameas test

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

Commits
-------

534c5db bug #15811 use of twig deprecated sameas test
2015-09-16 13:14:26 +02:00
Nicky De Maeyer
534c5db3a3 bug #15811 use of twig deprecated sameas test 2015-09-16 11:31:47 +02:00
Fabien Potencier
4f9a411389 minor #15808 Improve the structure of the Finder testsuite (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

Improve the structure of the Finder testsuite

| 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

Testing against different adapters is now handled by multiple subclasses of a common test case rather than using data providers. This allows tests to be marked as skipped for unsupported adapters instead of making them disappear from the testsuite.
This will also make it much easier to mark tests for the find-based adapters as legacy ones when deprecating them.
This correspond to changes done by @nicolas-grekas in https://github.com/symfony/symfony/pull/15805, backported to 2.3 and with the data providers removed (his PR was keeping data providers for the adapter but making it return a single adapter all the time, hence the much bigger diff in my PR).
All tests in AbstractFinderTest are just moved from the FinderTest (they are all the tests running against multiple adapters). FinderTest itself runs the PhpAdapter (as this is the logic we want to keep in the finder in 3.0). I also tried to have a PhpFinderTest and keeping FinderTest only with the extra tests, but this would make things harder to merge branches between 2.8 and 3.0 in the future (once we remove other adapter tests) as we could simply keep the AbstractFinderTest in 3.0 for now to ease merging PRs adding new tests for bug fixes.

Commits
-------

20f2d03 Improve the structure of the Finder testsuite
2015-09-16 11:14:30 +02:00
Christophe Coevoet
20f2d03d2e Improve the structure of the Finder testsuite
Testing against different adapters is now handled by multiple subclasses
of a common test case rather than using data providers. This allows
tests to be marked as skipped for unsupported adapters instead of making
them disappear from the testsuite.
2015-09-16 09:54:32 +02:00
Tobias Schultze
0a5807bf47 minor #15809 Remove minimum width for web profiler content view (jbafford)
This PR was merged into the 2.8 branch.

Discussion
----------

Remove minimum width for web profiler content view

| 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 min-width on the Web Profiler's content view, to allow for narrower browser windows to render all content without a horizontal scroll bar. I've checked all of the profiler pages, and none of them seem adversely affected by this. (In some cases, certain content winds up being taller because there's less horizontal space, but that's entirely expected and reasonable).

Commits
-------

62dc014 Remove minimum width for web profiler content view
2015-09-16 01:59:41 +02:00
John Bafford
62dc0147bf Remove minimum width for web profiler content view 2015-09-15 16:21:23 -04:00
Christophe Coevoet
e66bf64da7 Remove duplication of the handling of regex filters in the Finder 2015-09-15 16:03:47 +02:00
Nicolas Grekas
4c7bb9cd14 [VarDumper] Fix HtmlDumper constructor calling CliDumper's 2015-09-15 14:30:50 +02:00
Fabien Potencier
c67e8b26b3 Merge branch '2.3' into 2.7
* 2.3:
  [Finder] Handle filtering of recursive iterators and use it to skip looping over excluded directories
  Exclude files based on path before applying the sorting
  [Console] fix phpdoc of DialogHelper
2015-09-15 13:37:25 +02:00
Fabien Potencier
150bcc9f64 bug #15802 [Finder] Handle filtering of recursive iterators and use it to skip looping over excluded directories (nicolas-grekas)
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes #15802).

Discussion
----------

[Finder] Handle filtering of recursive iterators and use it to skip looping over excluded directories

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

By implementing RecursiveIterator in FilterIterator, we can make it able to skip children of excluded branches of recursive inner iterators.
We use it immediately for our main target: skip over children of excluded directories in the Finder.
This is a significant performance boost when iterating over big directories, thus the "bugfix" status.

Commits
-------

8c691bd [Finder] Handle filtering of recursive iterators and use it to skip looping over excluded directories
2015-09-15 13:35:07 +02:00
Nicolas Grekas
8c691bd01f [Finder] Handle filtering of recursive iterators and use it to skip looping over excluded directories 2015-09-15 13:35:06 +02:00
Fabien Potencier
af4a6245e7 feature #15743 Validate the extended type for lazy-loaded type extensions (stof)
This PR was merged into the 2.8 branch.

Discussion
----------

Validate the extended type for lazy-loaded type extensions

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | not really
| BC breaks?    | yes, but only for broken setups
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Symfony 2.1 introduced such validation for form types because a mismatch would actually break the logic (the name is accessed again later).
This was not added for type extensions because in such case, ``getExtendedType`` would actually never be used for extensions loaded by the DI extension (this method is only used inside extensions, and the DI extension relies on the service configuration instead). However, having mismatching values there would make debugging much harder, and can hide mistakes (see #15740 for such a mistake being fixed in the core). It also means that it might be hard to fix usage of deprecated APIs as the code might not contain the same extended type than the one used in the fullstack usage.

Commits
-------

8826d39 Validate the extended type for lazy-loaded type extensions
2015-09-15 13:33:15 +02:00
Fabien Potencier
cc2aeb188d feature #15801 [WebProfilerBundle][HttpKernel] removed import/export commands (jakzal)
This PR was merged into the 3.0-dev branch.

Discussion
----------

[WebProfilerBundle][HttpKernel] removed import/export commands

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

Follow up for #15709.

Commits
-------

c1d028e [HttpKernel] removed Profiler::import/export
1672a83 [WebProfilerBundle] removed import/export commands
2015-09-15 13:31:51 +02:00
Christophe Coevoet
8826d39e0f Validate the extended type for lazy-loaded type extensions 2015-09-15 12:07:24 +02:00
Fabien Potencier
306d88a1e3 bug #15803 [Finder] Exclude files based on path before applying the sorting (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

[Finder] Exclude files based on path before applying the sorting

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

Sorting can be slow, so it is best to applied it after all filtering rules are applied instead of using a bigger list and filtering again after that.

This impacts only people using both the sorting and the name filtering (with ``->names()`` or ``notNames()``)

Commits
-------

e5bf0ab Exclude files based on path before applying the sorting
2015-09-15 11:46:38 +02:00
Christophe Coevoet
e5bf0ab877 Exclude files based on path before applying the sorting
Sorting can be slow, so it is best to applied it after all filtering
rules are applied instead of using a bigger list and filtering again
after that.
2015-09-15 11:15:55 +02:00
Jakub Zalas
c1d028e73d [HttpKernel] removed Profiler::import/export 2015-09-15 09:57:39 +01:00
Jakub Zalas
1672a8344a [WebProfilerBundle] removed import/export commands 2015-09-15 09:57:25 +01:00
Fabien Potencier
1abfaba2a5 feature #13761 Automatically process extensions when they implement CompilerPassInterface (WouterJ)
This PR was merged into the 2.7 branch.

Discussion
----------

Automatically process extensions when they implement CompilerPassInterface

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | todo (if people are in favor of this PR)

Compiler passes are very powerfull, but also quite strange to work with. Especially when you just need a very simple compiler pass (like https://github.com/symfony-cmf/RoutingBundle/blob/master/DependencyInjection/Compiler/SetRouterPass.php). For 3 lines of code, you need to tweak your bundle class and create a new class.

When using the DI component standalone, compiler passes are even harder to work with, as DI extensions can't register them. I believe that's why libraries like Behat make their extensions compiler passes by default.

I think it would be very easy to just implement an interface and have a `compile` method for the simple compiler pass stuff. If a bundle needs multiple compiler passes or need compiler passes to be executed at other times in the compile process, a bundle can use the normal compiler passes. But if it's just one simple thing, like replacing a definition or getting services with a specific tag, I think this method will be very usefull.

Commits
-------

6c50013 Allowed extensions to inline compiler passes
2015-09-15 10:30:42 +02:00
Fabien Potencier
47b17ebef4 minor #15791 [Console] fix phpdoc of DialogHelper (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[Console] fix phpdoc of DialogHelper

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

Commits
-------

fd22d8f [Console] fix phpdoc of DialogHelper
2015-09-15 09:14:43 +02:00
Rob Bast
90c2a96936 Default to stderr for console helpers (only merge if #15794 gets merged) 2015-09-14 23:39:58 +02:00
Fabien Potencier
c38326c1cd Merge branch '2.3' into 2.7
* 2.3:
  fixed composer.json
2015-09-14 17:19:11 +02:00
Fabien Potencier
68353a6305 fixed composer.json 2015-09-14 17:18:35 +02:00
Tobias Schultze
fd22d8fa03 [Console] fix phpdoc of DialogHelper 2015-09-14 17:16:40 +02:00
Fabien Potencier
538a71d76f Merge branch '2.8'
* 2.8: (31 commits)
  [DomCrawler] Invalid uri created from forms if base tag present
  [VarDumper] Add caster for OuterIterator objects
  [Console] update param type phpdoc for StreamOutput
  [Console] fix typo in OutputInterface
  Use stderr by default when a specific output is not injected
  fixed bad merge
  [Debug] Fix case mismatch detection
  [HttpKernel] Add entry point to more easily create/configure the DI extension
  [DX] Added a logout link in the security panel of the web debug toolbar
  [HttpKernel] fix broken multiline <esi:remove>
  [DoctrineBridge] Fixed #14840
  [FrameworkBundle] add a suggest for the serializer component
  fixed CS
  removed non-working tests
  [WIP] #15502 Make template shortcuts be usable without Templating component
  Redesigned the Symfony Profiler
  [Yaml] Fix the parsing of float keys
  Make the exception output visible even in quiet mode, fixes #15680
  Convert Output::write's type to an options arg where verbosity can be passed in as well
  [Console] Ensure the console output is only detected as decorated when both stderr and stdout support colors
  ...
2015-09-14 16:15:24 +02:00
Fabien Potencier
6393ec3169 Merge branch '2.7' into 2.8
* 2.7:
  [DomCrawler] Invalid uri created from forms if base tag present
  [Console] update param type phpdoc for StreamOutput
  [Console] fix typo in OutputInterface
  Use stderr by default when a specific output is not injected
  [Debug] Fix case mismatch detection
  [HttpKernel] fix broken multiline <esi:remove>
  [DoctrineBridge] Fixed #14840
  [FrameworkBundle] add a suggest for the serializer component
  [Yaml] Fix the parsing of float keys
  [Console] Ensure the console output is only detected as decorated when both stderr and stdout support colors
  [HttpKernel] fix DumpDataCollector compat with Twig 2.0
  Improve exception messages.
  Fix that two DirectoryResources with different patterns would be deduplicated
  Tests fix clockmock
  [WebProfilerBundle] Added tabindex="-1" to not interfer with normal UX
  missing "YAML" in the exception message.
  [Translator][warmup][fallback locales] fixed missing cache file generation.
  [framework-bundle] Add Test for TranslationUpdateCommand
  Use ObjectManager interface instead of EntityManager
2015-09-14 16:15:17 +02:00
Fabien Potencier
cafd4af7cd Merge branch '2.3' into 2.7
* 2.3:
  [DomCrawler] Invalid uri created from forms if base tag present
  [Console] update param type phpdoc for StreamOutput
  [Console] fix typo in OutputInterface
  [HttpKernel] fix broken multiline <esi:remove>
  [DoctrineBridge] Fixed #14840
  [FrameworkBundle] add a suggest for the serializer component
  [Yaml] Fix the parsing of float keys
  [Console] Ensure the console output is only detected as decorated when both stderr and stdout support colors
  Improve exception messages.
  Fix that two DirectoryResources with different patterns would be deduplicated
  Tests fix clockmock
  [WebProfilerBundle] Added tabindex="-1" to not interfer with normal UX
  missing "YAML" in the exception message.
  [framework-bundle] Add Test for TranslationUpdateCommand
  Use ObjectManager interface instead of EntityManager
2015-09-14 16:14:09 +02:00
Fabien Potencier
6d3f124854 bug #13794 [DomCrawler] Invalid uri created from forms if base tag present (danez)
This PR was squashed before being merged into the 2.3 branch (closes #13794).

Discussion
----------

[DomCrawler] Invalid uri created from forms if base tag present

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

Since #13145 was merged the provided testcase does not work anymore and creates an invalid link

This affects the latest versions of 2.3, 2.5, 2.6 and 2.7

Right now this PR only includes the failing test, as I could no easy find a fix. If someone immediately knows whats the problem, give me a hint please.

Commits
-------

dc57a7a [DomCrawler] Invalid uri created from forms if base tag present
2015-09-14 16:00:14 +02:00
Daniel Tschinder
dc57a7a5a7 [DomCrawler] Invalid uri created from forms if base tag present 2015-09-14 16:00:12 +02:00
Fabien Potencier
9e32be3af5 feature #15787 [VarDumper] Add caster for OuterIterator objects (nicolas-grekas)
This PR was merged into the 2.8 branch.

Discussion
----------

[VarDumper] Add caster for OuterIterator objects

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

Commits
-------

f64b72d [VarDumper] Add caster for OuterIterator objects
2015-09-14 15:29:52 +02:00
Fabien Potencier
eff9a26c76 bug #15728 Use stderr by default when a specific output is not injected (Seldaek)
This PR was merged into the 2.7 branch.

Discussion
----------

Use stderr by default when a specific output is not injected

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

stderr is really the best place to put logs by default, so unless someone explicitly passes something else we should use it, and especially not depend on the log level to decide where to output.

Commits
-------

c28796e Use stderr by default when a specific output is not injected
2015-09-14 15:18:21 +02:00
Fabien Potencier
3cf95ee08a minor #15789 [Console] update param type phpdoc for StreamOutput (Tobion)
This PR was merged into the 2.3 branch.

Discussion
----------

[Console] update param type phpdoc for StreamOutput

Makes it consistent with `getStream()`

| 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

Commits
-------

c036352 [Console] update param type phpdoc for StreamOutput
2015-09-14 15:17:39 +02:00
Fabien Potencier
d87db39aa1 bug #15637 Use ObjectManager interface instead of EntityManager (gnat42)
This PR was merged into the 2.3 branch.

Discussion
----------

Use ObjectManager interface instead of EntityManager

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

If you use the EntityManager Decorator pattern that doctrine provides
then simply specifying a query_builder closure where your decorated
em is used fails as it isn't an instance of Doctrine\ORM\EntityManager.
Testing against the ObjectManager interface fixes the issue.

Commits
-------

1f3ea0f Use ObjectManager interface instead of EntityManager
2015-09-14 15:16:06 +02:00
Nicolas Grekas
f64b72ddf0 [VarDumper] Add caster for OuterIterator objects 2015-09-14 14:30:18 +02:00
Tobias Schultze
c0363524a9 [Console] update param type phpdoc for StreamOutput 2015-09-14 14:22:54 +02:00
Tobias Schultze
50afff1647 [Console] fix typo in OutputInterface 2015-09-14 14:10:47 +02:00