Commit Graph

42459 Commits

Author SHA1 Message Date
Tobias Schultze
67af93f3b0 bug #32053 [Messenger] No need for retry to require SentStamp (Tobion)
This PR was merged into the 4.3 branch.

Discussion
----------

[Messenger] No need for retry to require SentStamp

| Q             | A
| ------------- | ---
| Branch?       | 4.3
| Bug fix?      | yes
| 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 |
| License       | MIT
| Doc PR        |

Fixes 2) in #32049
@weaverryan the SentStamp in the worker seems totally irrelevant. You always want to send messages back to the transport where they came from for retry. The only relevance I can potentially see is for the SyncTransport. Messages received async from worker might be routed to the SyncTransport. Using the SentStamp would redeliver the messages into the SyncTransport instead of the async. But that doesn't seem to have any use-case. I'm running the worker which handles the messages immediately. So basically there is no difference if they go to the Sync or Async transport from within the worker.

Commits
-------

0034dee641 [Messenger] make retry logic work without SentStamp
2019-06-24 23:32:13 +01:00
Tobias Schultze
66c2e8483a [Messenger] fix retrying handlers using DoctrineTransactionMiddleware 2019-06-24 15:34:54 +01:00
Hippolyte Alain
afbefe131b [Mailgun Mailer] fixed issue when using html body 2019-06-24 16:09:08 +02:00
Nicolas Grekas
c5c3332400 [HttpClient] fix timing measurements with NativeHttpClient 2019-06-24 10:59:29 +02:00
Nicolas Grekas
412411d795 [HttpClient] fix dealing with 1xx informational responses 2019-06-23 19:42:15 +02:00
Nicolas Grekas
698601140b minor #31993 [Mailer] Catch missing scheme in DSN (derrabus)
This PR was merged into the 4.3 branch.

Discussion
----------

[Mailer] Catch missing scheme in DSN

| Q             | A
| ------------- | ---
| Branch?       | 4.3
| 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 `Symfony\Component\Mailer\Transport::createTransport()` method parses and validates a passed DSN. I noticed that we never check if the DSN contains a valid scheme, but we always assume that the scheme is present in then parse result. If someone passes a DSN without a scheme to that method, they would almost certainly run into a PHP notice.

This PR makes sure that a scheme is present in the URL and throws a proper exception otherwise.

Commits
-------

3eba36c088 [Mailer] Catch missing scheme in DSN.
2019-06-23 17:43:40 +02:00
Nicolas Grekas
b56591c92d bug #32083 [HttpClient] fixing passing debug info to progress callback (nicolas-grekas)
This PR was merged into the 4.3 branch.

Discussion
----------

[HttpClient] fixing passing debug info to progress callback

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

NativeHttpClient already has it.

Commits
-------

dc55cf826a [HttpClient] fixing passing debug info to progress callback
2019-06-23 17:19:50 +02:00
Nicolas Grekas
57d73fcac3 minor #32140 [Filesystem] add test to avoid regressions (xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

[Filesystem] add test to avoid regressions

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

Commits
-------

0d7d1f81bc add test to avoid regressions
2019-06-23 17:08:29 +02:00
Nicolas Grekas
6d02c89c21 bug #32129 [DebugBundle] fix register ReflectionCaster::unsetClosureFileInfo caster in var cloner service (alekitto)
This PR was merged into the 4.3 branch.

Discussion
----------

[DebugBundle] fix register ReflectionCaster::unsetClosureFileInfo caster in var cloner service

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

Non-existent class was checked by `method_exists` in Debug bundle.
This should fix (and correctly register) the caster while loading `DebugExtension` from `DebugBundle`

Commits
-------

860164ee7e [DebugBundle] fix register ReflectionCaster::unsetClosureFileInfo caster in var cloner service
2019-06-23 16:55:14 +02:00
Christian Flothmann
0d7d1f81bc add test to avoid regressions 2019-06-23 11:29:17 +02:00
Christian Flothmann
b58a806340 fix mirroring directory into parent directory 2019-06-23 10:51:25 +02:00
Christian Flothmann
196ee5599d fix typos 2019-06-23 10:10:04 +02:00
Christian Flothmann
8a00c256f2 minor #32112 Turkish translation added to Form Component (emr)
This PR was submitted for the 4.4 branch but it was merged into the 3.4 branch instead (closes #32112).

Discussion
----------

Turkish translation added to Form Component

| 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        |

Commits
-------

a030e393c5 Turkish translation added to Form Component
2019-06-23 09:45:29 +02:00
Emre Akinci
a030e393c5 Turkish translation added to Form Component 2019-06-23 09:45:21 +02:00
Tobias Schultze
7822b3cbc0 bug #32027 [Messenger] Remove DispatchAfterCurrentBusStamp when message is put on internal queue (Nyholm)
This PR was merged into the 4.3 branch.

Discussion
----------

[Messenger] Remove DispatchAfterCurrentBusStamp when message is put on internal queue

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

This will fix #32009.

Thank you @brpauwels for the report.

I consider it safe to remove the `DispatchAfterCurrentBusStamp` because its meaning disappear after we handled the "current bus".

T0: We add the stamp
T1: We put the envelope on an internal queue in `DispatchAfterCurrentBusMiddleware`
T2: We handle the current bus.
T3: We start processing our internal queue.

At T3 there we are "after current bus", that is why we dont need the stamp any more.

Commits
-------

91f1680b3f [Messenger] Remove DispatchAfterCurrentBusStamp when message is put on internal queue
2019-06-22 23:18:30 +01:00
Christian Flothmann
7a4570dcac fix accessing session bags 2019-06-22 22:10:25 +02:00
Fabien Potencier
3634390a27 Merge branch '4.2' into 4.3
* 4.2:
  Fix link to documentation
  [Validator] Use LogicException for missing Property Access Component in comparison constraints
2019-06-22 10:39:44 +02:00
Fabien Potencier
0dbf4775e2 bug #32125 [Form] accept floats for input="string" in NumberType (xabbuh)
This PR was merged into the 4.3 branch.

Discussion
----------

[Form] accept floats for input="string" in NumberType

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

Commits
-------

2abf85599d accept floats for input="string" in NumberType
2019-06-22 10:27:15 +02:00
Fabien Potencier
0546941dc1 minor #32121 Fix link to documentation (AMartinNo1)
This PR was submitted for the master branch but it was merged into the 4.2 branch instead (closes #32121).

Discussion
----------

Fix link to documentation

| Q             | A
| ------------- | ---
| Branch?       | 4.4 for features / 3.4, 4.2 or 4.3 for bug fixes <!-- see below -->
| Bug fix?      | yes
| New feature?  |No, update link to VarExporter doc only
| BC breaks?    | no
| Deprecations? | no
| Test pass? | yes
| Fixed tickets | none
| License | MIT
| Doc PR | symfony/symfony-docs

Commits
-------

e0d2c58bc2 Fix link to documentation
2019-06-22 10:17:24 +02:00
Alex Nostadt
e0d2c58bc2 Fix link to documentation 2019-06-22 10:17:17 +02:00
Fabien Potencier
5471867efc bug #32094 [Validator] Use LogicException for missing Property Access Component in comparison constraints (Lctrs)
This PR was merged into the 4.2 branch.

Discussion
----------

[Validator] Use LogicException for missing Property Access Component in comparison constraints

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

For consistency.

Commits
-------

6ac2316993 [Validator] Use LogicException for missing Property Access Component in comparison constraints
2019-06-22 10:13:40 +02:00
Fabien Potencier
04b2f7f3ef bug #32136 [FrameworkBundle] sync require-dev and conflict constraints (xabbuh)
This PR was merged into the 4.3 branch.

Discussion
----------

[FrameworkBundle] sync `require-dev` and `conflict` constraints

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

The `conflict` section already prevents the Translation component 4.2 to be installed.

Commits
-------

47f9235568 sync `require-dev` and `conflict` constraints
2019-06-22 10:05:56 +02:00
Christian Flothmann
47f9235568 sync require-dev and conflict constraints 2019-06-21 23:08:55 +02:00
Christian Flothmann
48664445ba fix typo 2019-06-21 22:46:43 +02:00
Alessandro Chitolina
860164ee7e
[DebugBundle] fix register ReflectionCaster::unsetClosureFileInfo caster in var cloner service 2019-06-21 12:18:42 +02:00
Christian Flothmann
a25c2af559 Merge branch '4.2' into 4.3
* 4.2:
  fix translation domain
  tag the FileType service as a form type
  [Validator] Fix GroupSequenceProvider annotation
  Update ajax security cheat sheet link
  Fix AuthenticationException::getToken typehint
2019-06-21 12:01:08 +02:00
Christian Flothmann
6821850183 Merge branch '3.4' into 4.2
* 3.4:
  fix translation domain
  tag the FileType service as a form type
  [Validator] Fix GroupSequenceProvider annotation
  Update ajax security cheat sheet link
  Fix AuthenticationException::getToken typehint
2019-06-21 11:59:02 +02:00
Christian Flothmann
2abf85599d accept floats for input="string" in NumberType 2019-06-21 11:58:40 +02:00
Christian Flothmann
4c088b6dae bug #32123 [Form] fix translation domain (xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

[Form] fix translation domain

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/32045#issuecomment-504005348
| License       | MIT
| Doc PR        |

Commits
-------

74387cf21f fix translation domain
2019-06-21 11:53:38 +02:00
Christian Flothmann
74387cf21f fix translation domain 2019-06-20 22:29:36 +02:00
Fabien Potencier
030396ada4 bug #32115 [SecurityBundle] don't validate IP addresses from env var placeholders (xabbuh)
This PR was merged into the 4.3 branch.

Discussion
----------

[SecurityBundle] don't validate IP addresses from env var placeholders

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

Commits
-------

f23a7f60cf don't validate IP addresses from env var placeholders
2019-06-20 13:19:59 +02:00
Fabien Potencier
370682c307 bug #32116 [FrameworkBundle] tag the FileType service as a form type (xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

[FrameworkBundle] tag the FileType service as a form type

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

In #30961 we undeprecated the `form.type.file` service as we need to pass the translator to the form type. But we forgot to add back the `form.type` tag which means that the form registry actually never used our service but instantiated the `FileType` itself and thus the type was never able to use a translator.

Commits
-------

ea5b1f4d67 tag the FileType service as a form type
2019-06-20 13:17:42 +02:00
Christian Flothmann
ea5b1f4d67 tag the FileType service as a form type 2019-06-20 12:19:18 +02:00
Christian Flothmann
f23a7f60cf don't validate IP addresses from env var placeholders 2019-06-20 12:11:09 +02:00
Fabien Potencier
6fcd319d78 minor #32044 [Validator] Fix GroupSequenceProvider annotation (enumag)
This PR was squashed before being merged into the 3.4 branch (closes #32044).

Discussion
----------

[Validator] Fix GroupSequenceProvider annotation

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

The possibility was added in https://github.com/symfony/symfony/pull/19982, just forgot to fix this annotation back then.

Commits
-------

bf6d2532de [Validator] Fix GroupSequenceProvider annotation
2019-06-20 08:43:36 +02:00
Jáchym Toušek
bf6d2532de [Validator] Fix GroupSequenceProvider annotation 2019-06-20 08:43:29 +02:00
Fabien Potencier
0a1a88512a bug #32109 [Messenger] fix delay exchange recreation after disconnect (Tobion)
This PR was merged into the 4.3 branch.

Discussion
----------

[Messenger] fix delay exchange recreation after disconnect

| Q             | A
| ------------- | ---
| Branch?       | 4.3
| Bug fix?      | yes
| 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 |
| License       | MIT
| Doc PR        |

Commits
-------

c1c3b54a0f [Messenger] fix delay exchange recreation after disconnect
2019-06-20 08:10:49 +02:00
Tobias Schultze
c1c3b54a0f [Messenger] fix delay exchange recreation after disconnect 2019-06-20 03:38:05 +01:00
Robin Chalas
8ad74a859d minor #32001 [Security] Fix AuthenticationException::getToken typehint (norkunas)
This PR was merged into the 3.4 branch.

Discussion
----------

[Security] Fix AuthenticationException::getToken typehint

| Q             | A
| ------------- | ---
| Branch?       | 3.4 <!-- see below -->
| 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        | symfony/symfony-docs#... <!-- required for new features -->

The token may be not set when throwing AuthenticationException.

<!--
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
-------

a9705a0143 Fix AuthenticationException::getToken typehint
2019-06-19 19:38:48 +02:00
Nicolas Grekas
2fa52989db Merge branch '4.2' into 4.3
* 4.2:
  [FrameworkBundle] minor: fix typo in SessionTest
  [Debug] workaround BC break in PHP 7.3
2019-06-19 17:27:09 +02:00
Nicolas Grekas
b2eeaea00c Merge branch '3.4' into 4.2
* 3.4:
  [FrameworkBundle] minor: fix typo in SessionTest
  [Debug] workaround BC break in PHP 7.3
2019-06-19 17:26:44 +02:00
Fabien Potencier
df210194e0 minor #32100 Update ajax security cheat sheet link (steef)
This PR was merged into the 3.4 branch.

Discussion
----------

Update ajax security cheat sheet link

| Q             | A
| ------------- | ---
| Branch?       | 3.4 <!-- see below -->
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT

# Description
After looking in the `JsonResponse` class I found an old OWASP [link](https://www.owasp.org/index.php/AJAX_Security_Cheat_Sheet#Always_return_JSON_with_an_Object_on_the_outside). As the cheat sheet series project is moved to GitHub the link can be updated to the [following](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/AJAX_Security_Cheat_Sheet.md).

## Screenshot
<img width="552" alt="Screenshot 2019-06-19 at 16 52 19" src="https://user-images.githubusercontent.com/34915382/59776184-a7e2bf80-92b2-11e9-8d23-802acfddfb1d.png">

Commits
-------

32d02d6141 Update ajax security cheat sheet link
2019-06-19 17:25:42 +02:00
Stefano Degenkamp
32d02d6141
Update ajax security cheat sheet link
As the cheat sheet series project has been moved to github.
2019-06-19 17:21:12 +02:00
Fabien Potencier
eb4026b3f4 bug #32090 [Debug] workaround BC break in PHP 7.3 (nicolas-grekas)
This PR was merged into the 3.4 branch.

Discussion
----------

[Debug] workaround BC break in PHP 7.3

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony-standard/issues/1138 https://github.com/symfony/website-skeleton/issues/231
| License       | MIT
| Doc PR        | -

A new warning has been added in PHP 7.3 that is breaking BC with Symfony, since we turn warnings into exceptions.
This PR turns the new warning into a deprecation, so that we will be able to remove the added "if" in 5.0.

I noticed a few other similar BC breaks in 7.1 and 7.2, but *unless someone reports that they block them*, I don't think we need to care.
- 7.1 A non well formed numeric value encountered E_NOTICE
- 7.1 A non-numeric value encountered E_WARNING
- 7.2 count() now raises a warning when an invalid parameter is passed.

See https://github.com/php/php-src/blob/PHP-7.1/UPGRADING + same in upper branches.

Commits
-------

d8d43e6195 [Debug] workaround BC break in PHP 7.3
2019-06-19 12:21:41 +02:00
Fabien Potencier
459e791e59 minor #32092 [FrameworkBundle] minor: fix typo in SessionTest (Simperfit)
This PR was submitted for the 4.4 branch but it was merged into the 3.4 branch instead (closes #32092).

Discussion
----------

[FrameworkBundle] minor: fix typo in SessionTest

| Q             | A
| ------------- | ---
| Branch?       | 4.2
| 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.   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | no  <!-- required for new features -->

<!--
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.
-->

A little typo

Commits
-------

494281465d [FrameworkBundle] minor: fix typo in SessionTest
2019-06-19 10:53:57 +02:00
Amrouche Hamza
494281465d [FrameworkBundle] minor: fix typo in SessionTest 2019-06-19 10:53:48 +02:00
Lctrs
6ac2316993 [Validator] Use LogicException for missing Property Access Component in comparison constraints 2019-06-19 10:51:43 +02:00
Nicolas Grekas
d8d43e6195 [Debug] workaround BC break in PHP 7.3 2019-06-18 23:26:03 +02:00
Nicolas Grekas
dc55cf826a [HttpClient] fixing passing debug info to progress callback 2019-06-18 14:13:04 +02:00
Nicolas Grekas
5af1e9e1a5 minor #32075 [Lock] Fix expired lock not cleaned in ZooKeeper (jderusse)
This PR was merged into the 4.3 branch.

Discussion
----------

[Lock] Fix expired lock not cleaned in ZooKeeper

| Q             | A
| ------------- | ---
| Branch?       | 4.3
| Bug fix?      | yes
| New feature?  | ,p
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #31426
| License       | MIT
| Doc PR        | NA

Following #32071 for 4.3 branch

context:
When a lock is acquired BUT not as fast as expected, a LockExpiredException is thrown.
Issue is, that the lock is not removed which avoid other process to acquire that lock.

This PR clean state of store when a LockExpiredException is triggered in PDO and ZooKeepeer.

Commits
-------

4f808ef4f4 Fix Expiring lock in PDO and ZooKeeper
2019-06-17 21:42:39 +02:00