Commit Graph

43222 Commits

Author SHA1 Message Date
Christian Flothmann
bd45789f10 feature #32762 [Form][DX] derive default timezone from reference_date option when possible (yceruto)
This PR was merged into the 4.4 branch.

Discussion
----------

[Form][DX] derive default timezone from reference_date option when possible

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

Currently, when `reference_date` and `model_timezone` are provided but are not the same, we get a validation exception:
9216cb75ac/src/Symfony/Component/Form/Extension/Core/Type/TimeType.php (L48-L50)

But that happen even if the `model_timezone` is `null` !

I propose to relax this behavior by passing the time zone of the configured `reference_date` to this `model_timezone` (by default), thus avoiding annoyances.

Commits
-------

a62feea4ad [DX] derive default timezone from reference_date option when possible
2019-07-29 17:46:21 +02:00
Tobias Schultze
66eb96408b minor #32794 [Lock] Add return type to the new LockFactory (chalasr)
This PR was merged into the 4.4 branch.

Discussion
----------

[Lock] Add return type to the new LockFactory

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

Let's leverage renaming to add a return type.

Commits
-------

489f36daa2 [Lock] Add return type to the new LockFactory
2019-07-29 17:01:46 +02:00
Robin Chalas
489f36daa2 [Lock] Add return type to the new LockFactory 2019-07-29 14:27:17 +02:00
Yonel Ceruto
a62feea4ad [DX] derive default timezone from reference_date option when possible 2019-07-28 17:39:10 -04:00
Fabien Potencier
a29aff0370 bug #32781 [Console] Fix disabling ChoiceQuestion answer trimming (chalasr)
This PR was merged into the 4.4 branch.

Discussion
----------

[Console] Fix disabling ChoiceQuestion answer trimming

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

Commits
-------

44ee0569bb [Console] Fix disabling ChoiceQuestion answer trimming
2019-07-27 19:07:55 +02:00
Robin Chalas
44ee0569bb [Console] Fix disabling ChoiceQuestion answer trimming 2019-07-27 14:53:28 +02:00
Fabien Potencier
119ac78792 minor #32773 [Messenger] fix tests (fabpot)
This PR was merged into the 4.4 branch.

Discussion
----------

[Messenger] fix tests

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

<!--
Replace this notice by a short README for your feature/bugfix. This will help people
understand your PR and can be used as a start for the documentation.

Additionally (see https://symfony.com/roadmap):
 - Bug fixes must be submitted against the lowest maintained branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against branch 4.4.
 - Legacy code removals go to the master branch.
-->

Commits
-------

bba623028e [Messenger] fixed tests
2019-07-27 09:26:28 +02:00
Fabien Potencier
bba623028e [Messenger] fixed tests 2019-07-27 09:15:41 +02:00
Fabien Potencier
a12edecf77 Merge branch '4.3' into 4.4
* 4.3:
  add parameter type declarations to private methods
  add missing changelog entry
  clarify error handler restoring process
  [VarDumper] cs fix
  [DI] fix perf issue with lazy autowire error messages
  Fix pluralizing "season"
2019-07-27 08:43:05 +02:00
Fabien Potencier
3e8eaebe23 Merge branch '4.2' into 4.3
* 4.2:
  add parameter type declarations to private methods
  add missing changelog entry
  clarify error handler restoring process
  [VarDumper] cs fix
2019-07-27 08:42:46 +02:00
Fabien Potencier
826a66228b Merge branch '3.4' into 4.2
* 3.4:
  [VarDumper] cs fix
2019-07-27 08:42:33 +02:00
Fabien Potencier
dd5aa5d447 minor #32772 [FrameworkBundle] Add type-hints on private methods (fabpot)
This PR was merged into the 4.4 branch.

Discussion
----------

[FrameworkBundle] Add type-hints on private methods

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

<!--
Replace this notice by a short README for your feature/bugfix. This will help people
understand your PR and can be used as a start for the documentation.

Additionally (see https://symfony.com/roadmap):
 - Bug fixes must be submitted against the lowest maintained branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against branch 4.4.
 - Legacy code removals go to the master branch.
-->

Commits
-------

da54325136 [FrameworkBundle] added type-hints on private methods
2019-07-27 08:40:13 +02:00
Fabien Potencier
da54325136 [FrameworkBundle] added type-hints on private methods 2019-07-27 08:35:12 +02:00
Fabien Potencier
9595503b8f feature #32745 [Messenger][Profiler] Attempt to give more useful source info when using HandleTrait (ogizanagi)
This PR was merged into the 4.4 branch.

Discussion
----------

[Messenger][Profiler] Attempt to give more useful source info when using HandleTrait

| Q             | A
| ------------- | ---
| Branch?       | 4.4 <!-- see below -->
| Bug fix?      | no
| New feature?  | yes <!-- please update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

### Before

<img width="1052" alt="Capture d’écran 2019-07-25 à 15 02 03" src="https://user-images.githubusercontent.com/2211145/61883193-3e318300-aefa-11e9-9179-a40c7c5aac93.png">

### After

<img width="1054" alt="Capture d’écran 2019-07-25 à 14 59 27" src="https://user-images.githubusercontent.com/2211145/61883192-3d98ec80-aefa-11e9-8f29-df9c417e8025.png">

which works for both examples using the trait in https://symfony.com/doc/current/messenger/handler_results.html

Commits
-------

9ac7e4223c [Messenger][Profiler] Attempt to give more useful source info when using HandleTrait
2019-07-27 08:27:28 +02:00
Fabien Potencier
b00d9882e8 bug #32760 [HttpKernel] clarify error handler restoring process (xabbuh)
This PR was merged into the 4.2 branch.

Discussion
----------

[HttpKernel] clarify error handler restoring process

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

Commits
-------

c1349d1434 clarify error handler restoring process
2019-07-27 08:24:42 +02:00
Fabien Potencier
6aec1297ca feature #32680 [Messenger][Profiler] Collect the stamps at the end of dispatch (ogizanagi)
This PR was merged into the 4.4 branch.

Discussion
----------

[Messenger][Profiler] Collect the stamps at the end of dispatch

| Q             | A
| ------------- | ---
| Branch?       | 4.4 <!-- see below -->
| Bug fix?      | no
| New feature?  | yes <!-- please update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

Currently, only the stamps added before dispatching the message are shown in the profiler.
This PR adds a section to show stamps after dispatch (`HandledStamp`, `SentStamp`, ...).

![Capture d’écran 2019-07-23 à 15 44 04](https://user-images.githubusercontent.com/2211145/61717102-bb28f500-ad60-11e9-93ec-bb2875d176ce.png)

Commits
-------

ee68b1dfa7 [Messenger][Profiler] Collect the stamps at the end of dispatch
2019-07-27 08:22:04 +02:00
Fabien Potencier
5acd99cb3f minor #32771 [DoctrineBridge] add parameter type declarations to private methods (xabbuh)
This PR was merged into the 4.2 branch.

Discussion
----------

[DoctrineBridge] add parameter type declarations to private methods

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

Commits
-------

8157db4522 add parameter type declarations to private methods
2019-07-27 08:17:37 +02:00
Fabien Potencier
65f0d6f6a2 feature #32683 [VarDumper] added support for Imagine/Image (lyrixx)
This PR was merged into the 4.4 branch.

Discussion
----------

[VarDumper] added support for Imagine/Image

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

---

![image](https://user-images.githubusercontent.com/408368/61811135-19c5a000-ae41-11e9-88f1-9f5823e9ca80.png)

Commits
-------

c8d420ddff [VarDumper] added support for Imagine/Image
2019-07-27 08:16:32 +02:00
Fabien Potencier
9d6ca0de01 bug #32730 [Inflector] Fix pluralizing words ending with "son" (norkunas)
This PR was merged into the 4.3 branch.

Discussion
----------

[Inflector] Fix pluralizing words ending with "son"

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

<!--
Replace this notice by a short README for your feature/bugfix. This will help people
understand your PR and can be used as a start for the documentation.

Additionally (see https://symfony.com/roadmap):
 - Bug fixes must be submitted against the lowest maintained branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against branch 4.4.
 - Legacy code removals go to the master branch.
-->

Commits
-------

bf608aaf3c Fix pluralizing "season"
2019-07-27 08:15:15 +02:00
Christian Flothmann
8157db4522 add parameter type declarations to private methods 2019-07-27 08:08:43 +02:00
Christian Flothmann
f7e8a96ffc add missing changelog entry 2019-07-27 07:24:50 +02:00
Robin Chalas
29ba2e1e06 minor #32736 [Console] avoid using huge amount of memory when formatting long exception (paxal)
This PR was submitted for the master branch but it was merged into the 4.4 branch instead (closes #32736).

Discussion
----------

[Console] avoid using huge amount of memory when formatting long exception

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | none
| License       | MIT

When formatting exceptions, `preg_split('//u')` is used to iterate over utf8 characters. When the exception is long, the amount of memory used is huge and can reach `memory_limit`.

This PR uses a `Generator` to iterate over the string instead of splitting it, thus reducing the amount of memory.

Commits
-------

47ffbad82d Avoid using huge amount of memory when formatting long exception
2019-07-27 05:02:48 +02:00
Cyril PASCAL
47ffbad82d Avoid using huge amount of memory when formatting long exception 2019-07-27 05:02:41 +02:00
Grégoire Pineau
c8d420ddff [VarDumper] added support for Imagine/Image 2019-07-26 17:55:43 +02:00
Christian Flothmann
c1349d1434 clarify error handler restoring process 2019-07-26 15:02:58 +02:00
Maxime Steinhausser
9ac7e4223c [Messenger][Profiler] Attempt to give more useful source info when using HandleTrait 2019-07-26 14:03:54 +02:00
Nicolas Grekas
5dc8bc0520 [VarDumper] cs fix 2019-07-26 13:29:23 +02:00
Tobias Schultze
61b0f7934d bug #32715 [DI] fix perf issue with lazy autowire error messages (nicolas-grekas)
This PR was merged into the 4.3 branch.

Discussion
----------

[DI] fix perf issue with lazy autowire error messages

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

See linked issue.

Commits
-------

3c3bda5423 [DI] fix perf issue with lazy autowire error messages
2019-07-26 12:17:52 +02:00
Fabien Potencier
9216cb75ac feature #32749 [Mailer] Make transport factory test case public (Koc)
This PR was merged into the 4.4 branch.

Discussion
----------

[Mailer] Make transport factory test case public

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes, failures looks like irrelevant
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

`TransportFactoryTestCase` could be useful when you adding custom transport and need cover their transport factory with tests.

Commits
-------

5d64009ae0 [Mailer] Make transport factory test case public
2019-07-26 09:06:55 +02:00
Nicolas Grekas
3c3bda5423 [DI] fix perf issue with lazy autowire error messages 2019-07-26 09:03:43 +02:00
Maxime Steinhausser
ee68b1dfa7 [Messenger][Profiler] Collect the stamps at the end of dispatch 2019-07-26 08:01:28 +02:00
Maxime Steinhausser
9282f4fd93 [VarDumper] Add missing changelog entry for VarDumperTestTrait::setUpVarDumper() 2019-07-26 07:53:10 +02:00
Konstantin Myakshin
5d64009ae0 [Mailer] Make transport factory test case public 2019-07-25 22:12:48 +03:00
Yonel Ceruto
e3afab7e76 minor #32748 Typo in variable name (OskarStark)
This PR was merged into the 4.4 branch.

Discussion
----------

Typo in variable name

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #...   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        |

Refs #32587

Commits
-------

784d1d0 Typo in variable name
2019-07-25 13:36:47 -04:00
Oskar Stark
784d1d0ca0
Typo in variable name 2019-07-25 19:14:17 +02:00
Fabien Potencier
86440a4b77 feature #32718 [Form] use a reference date to handle times during DST (xabbuh)
This PR was merged into the 4.4 branch.

Discussion
----------

[Form] use a reference date to handle times during DST

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

Commits
-------

39c98b9a08 use a reference date to handle times during DST
2019-07-25 17:17:00 +02:00
Tobias Schultze
a28609c80c minor #32741 [WebProfilerBundle] Rename the new exception controller and mark it as internal (yceruto)
This PR was merged into the 4.4 branch.

Discussion
----------

[WebProfilerBundle] Rename the new exception controller and mark it as internal

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/32695#discussion_r306965799
| License       | MIT
| Doc PR        | -

I missed some important details in https://github.com/symfony/symfony/pull/32695

Commits
-------

ba24a51ea4 Rename the new exception controller and mark it as internal
2019-07-25 15:15:03 +02:00
Tobias Schultze
c6a9e7a328 minor #32740 [TwigBundle] Update tests inline with master version (yceruto)
This PR was merged into the 4.4 branch.

Discussion
----------

[TwigBundle] Update tests inline with master version

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/32714#discussion_r306945146
| License       | MIT
| Doc PR        | -

Preparing to remove the `Resources/views` for TwigBundle in master branch
https://github.com/symfony/symfony/pull/32714

/cc @Tobion

Commits
-------

28a7ab8048 [TwigBundle] Update tests inline with master version
2019-07-25 15:11:42 +02:00
Yonel Ceruto
ba24a51ea4 Rename the new exception controller and mark it as internal 2019-07-25 08:59:23 -04:00
Yonel Ceruto
28a7ab8048 [TwigBundle] Update tests inline with master version 2019-07-25 08:35:38 -04:00
Tomas
bf608aaf3c Fix pluralizing "season" 2019-07-25 13:54:24 +03:00
Fabien Potencier
f6e93de5cf feature #32637 [ErrorHandler] Decouple from ErrorRenderer component (yceruto)
This PR was squashed before being merged into the 4.4 branch (closes #32637).

Discussion
----------

[ErrorHandler] Decouple from ErrorRenderer component

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | part of https://github.com/symfony/symfony/issues/32605
| License       | MIT
| Doc PR        | -

built on top of https://github.com/symfony/symfony/pull/32636 (See 2nd commit only)

Commits
-------

8f13fc013d [ErrorHandler] Decouple from ErrorRenderer component
2019-07-25 11:38:56 +02:00
Yonel Ceruto
8f13fc013d [ErrorHandler] Decouple from ErrorRenderer component 2019-07-25 11:38:42 +02:00
Fabien Potencier
fc14cb7dee feature #32609 [Mailer][DX][RFC] Rename mailer bridge transport classes (Koc)
This PR was squashed before being merged into the 4.4 branch (closes #32609).

Discussion
----------

[Mailer][DX][RFC] Rename mailer bridge transport classes

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

During working on #31946 I realized how painful to work with multiple classes which has same name. [Nice article](https://www.tomasvotruba.cz/blog/2019/05/02/alias-as-a-code-smell/) by @TomasVotruba with explanation of problems  with such approach.
~Built on top of #32608 , so only [2nd commit](bbf7e99e89) is actual.~

Also I've changed namespaces to make bridge structure much simpler and be linear. All classes located on same level now. See how [bridge](bbf7e99e89/src/Symfony/Component/Mailer/Bridge/Amazon) looks like now.

Now in RFC state to get approve for such king of changes and update all other bridges.

Commits
-------

eda4f01e0e [Mailer][DX][RFC] Rename mailer bridge transport classes
2019-07-25 11:34:39 +02:00
Konstantin Myakshin
eda4f01e0e [Mailer][DX][RFC] Rename mailer bridge transport classes 2019-07-25 11:34:25 +02:00
Christian Flothmann
9a5003eeee Merge branch '4.3' into 4.4
* 4.3:
  relax some assertions to make tests forward compatible
  fix typo
2019-07-24 23:18:55 +02:00
Christian Flothmann
327fb95828 Merge branch '4.2' into 4.3
* 4.2:
  relax some assertions to make tests forward compatible
  fix typo
2019-07-24 21:57:32 +02:00
Christian Flothmann
6085bf10c4 Merge branch '3.4' into 4.2
* 3.4:
  relax some assertions to make tests forward compatible
  fix typo
2019-07-24 21:56:58 +02:00
Christian Flothmann
da6aca66f5 minor #32728 relax some assertions to make tests forward compatible (xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

relax some assertions to make tests forward compatible

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

Commits
-------

c0eed67aa8 relax some assertions to make tests forward compatible
2019-07-24 21:56:41 +02:00
Christian Flothmann
c0eed67aa8 relax some assertions to make tests forward compatible 2019-07-24 21:39:07 +02:00