Commit Graph

46335 Commits

Author SHA1 Message Date
Fabien Potencier
4103a6ebd2 minor #35946 [DI] relax test to ignore changes to error message in master (nicolas-grekas)
This PR was merged into the 4.4 branch.

Discussion
----------

[DI] relax test to ignore changes to error message in master

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

Required to make https://github.com/symfony/symfony/pull/35945 green (check https://travis-ci.org/symfony/symfony/jobs/657931002#L4720)

Commits
-------

bf5d25c838 [DI] relax test to ignore changes to error message in master
2020-03-04 10:07:10 +01:00
Nicolas Grekas
bf5d25c838 [DI] relax test to ignore changes to error message in master 2020-03-04 08:10:40 +01:00
Nicolas Grekas
d246e941ab minor #35926 [Routing] Fix some wrong localized routes tests (fancyweb)
This PR was merged into the 4.4 branch.

Discussion
----------

[Routing] Fix some wrong localized routes tests

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

~~Since https://github.com/symfony/symfony/pull/35855, the `_locale` path param is directly substituted so those tests are not valid cases anymore. Instead, the path directly contain the right locale.~~ Actually, the compilation is done after, so instead we need to set the new requirement in all tests to reflect the "reality".

https://github.com/symfony/symfony/pull/35855 also causes a BC break on one case:
```php
$compiledUrlGenerator->generate('foo.fr', ['_locale' => 'en']))
```

Previously, the generated route would be the `/en/fourchette`. Now that the locale is hardcoded in the route path, it will always be `/fr/fourchette`. I changed `foo` to relevant words because it is easier to understand like that.

Commits
-------

99ae55ff1a [Routing] Fix some wrong localized routes tests
2020-03-02 18:19:11 +01:00
Nicolas Grekas
afdd507225 bug #35928 [Routing] Prevent localized routes _locale default & requirement from being overridden (fancyweb)
This PR was merged into the 4.4 branch.

Discussion
----------

[Routing] Prevent localized routes _locale default & requirement from being overridden

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | https://github.com/symfony/symfony/issues/35915
| License       | MIT
| Doc PR        | -

When we have configured a localized route, its default _locale and _locale requirement should not be modified to ensure it works as expected.

Commits
-------

096dc0aeef [Routing] Prevent localized routes _locale default & requirement from being overridden
2020-03-02 18:17:59 +01:00
Thomas Calvet
99ae55ff1a [Routing] Fix some wrong localized routes tests 2020-03-02 17:31:03 +01:00
Thomas Calvet
096dc0aeef [Routing] Prevent localized routes _locale default & requirement from being overridden 2020-03-02 17:08:48 +01:00
Fabien Potencier
4ab87747ad bug #35912 [FrameworkBundle] register only existing transport factories (xabbuh)
This PR was merged into the 4.4 branch.

Discussion
----------

[FrameworkBundle] register only existing transport factories

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #35866
| License       | MIT
| Doc PR        |

The parts from #35907 that also apply to the `4.4` branch.

Commits
-------

650c9f3f4b register only existing transport factories
2020-03-02 13:31:21 +01:00
Christian Flothmann
650c9f3f4b register only existing transport factories 2020-03-02 13:28:23 +01:00
Fabien Potencier
0936a4e75f bug #35899 [DomCrawler] prevent deprecation being triggered from assertion (xabbuh)
This PR was merged into the 4.4 branch.

Discussion
----------

[DomCrawler] prevent deprecation being triggered from assertion

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #35889
| License       | MIT
| Doc PR        |

Commits
-------

b01a10c760 prevent deprecation being triggered from assertion
2020-03-02 13:08:26 +01:00
Christian Flothmann
b01a10c760 prevent deprecation being triggered from assertion 2020-03-01 20:15:08 +01:00
Fabien Potencier
2bd76fa32c bumped Symfony version to 4.4.6 2020-02-29 11:35:30 +01:00
Fabien Potencier
b802dd453f
Merge pull request #35905 from fabpot/release-4.4.5
released v4.4.5
2020-02-29 11:31:55 +01:00
Fabien Potencier
6c52d481e7 updated VERSION for 4.4.5 2020-02-29 11:31:38 +01:00
Fabien Potencier
199bfceb7d updated CHANGELOG for 4.4.5 2020-02-29 11:31:29 +01:00
Fabien Potencier
8f7b8aa41d Merge branch '3.4' into 4.4
* 3.4:
  [Validator] Add missing vietnamese translations
  add German translation
  [Validator][ConstraintValidator] Update wrong PRETTY_DATE doc
  [DomCrawler][Form] Fix PHPDoc on get & offsetGet
  prevent method calls on null values
  Return int if scale = 0
2020-02-29 11:05:28 +01:00
Fabien Potencier
4ac38ef200 minor #35887 [Dotenv] Documentation improvement (jonmldr)
This PR was submitted for the master branch but it was merged into the 4.4 branch instead.

Discussion
----------

[Dotenv] Documentation improvement

| Q             | A
| ------------- | ---
| Branch?       | 4.4 <!-- see below -->
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| License       | MIT
<!--
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/releases):
 - Always add tests and ensure they pass.
 - Never break backward compatibility (see https://symfony.com/bc).
 - 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 master.
-->

Equalization with the component description in the [documentation](https://symfony.com/doc/current/components/dotenv.html).
My suggestion is to remove `getenv()` from this description. [Since Symfony 4.3](https://github.com/symfony/symfony/blob/master/UPGRADE-4.3.md), `$usePutenv = false` by default in `Dotenv::__construct()`. Because of this, `getenv()` is not usable by default.

Commits
-------

4f61247ccc [Dotenv] Documentation improvement
2020-02-29 11:04:08 +01:00
jonmldr
4f61247ccc [Dotenv] Documentation improvement 2020-02-29 11:04:02 +01:00
Fabien Potencier
34c2e96b08 bug #35781 [Form] NumberToLocalizedStringTransformer return int if scale = 0 (VincentLanglet)
This PR was merged into the 3.4 branch.

Discussion
----------

[Form] NumberToLocalizedStringTransformer return int if scale = 0

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #35775
| License       | MIT
<!--
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/releases):
 - Always add tests and ensure they pass.
 - Never break backward compatibility (see https://symfony.com/bc).
 - 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 master.
-->

Commits
-------

2993fc9fc5 Return int if scale = 0
2020-02-29 10:59:06 +01:00
Fabien Potencier
7295d25f32 bug #35846 [Serializer] prevent method calls on null values (xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

[Serializer] prevent method calls on null values

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #35824
| License       | MIT
| Doc PR        |

Commits
-------

847d6dc8f3 prevent method calls on null values
2020-02-29 10:53:07 +01:00
Fabien Potencier
dc9a0b586f bug #35897 [FrameworkBundle] add missing Messenger options to XML schema definition (xabbuh)
This PR was merged into the 4.4 branch.

Discussion
----------

[FrameworkBundle] add missing Messenger options to XML schema definition

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix symfony/symfony-docs#13010
| License       | MIT
| Doc PR        | symfony/symfony-docs#13277

Commits
-------

45a033d67b add missing Messenger options to XML schema definition
2020-02-29 10:50:54 +01:00
Fabien Potencier
8ed2e66de4 minor #35898 [DI] Clarified deprecation for TypedReference in 4.4 (linaori)
This PR was squashed before being merged into the 4.4 branch.

Discussion
----------

[DI] Clarified deprecation for TypedReference in 4.4

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tickets       | Fix #35752 <!-- prefix each issue number with "Fix #", if any -->
| License       | MIT
| Doc PR        |~ <!-- required for new features -->

Changes the deprecation message to indicate the argument has been removed and how to fix it.

Commits
-------

1c70048e9c [DI] Clarified deprecation for TypedReference in 4.4
2020-02-29 10:50:10 +01:00
Lynn
1c70048e9c [DI] Clarified deprecation for TypedReference in 4.4 2020-02-29 10:50:04 +01:00
Fabien Potencier
6c042661e2 minor #35901 [Validator] add German translation (xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

[Validator] add German translation

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       |
| License       | MIT
| Doc PR        |

Commits
-------

9d837ecb34 add German translation
2020-02-29 10:08:42 +01:00
Fabien Potencier
e4104b6411 minor #35903 [Validator] add Vietnamese translation (jschaedl)
This PR was merged into the 3.4 branch.

Discussion
----------

[Validator] add Vietnamese translation

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tickets       |  <!-- prefix each issue number with "Fix #", if any -->
| License       | MIT
| Doc PR        |  <!-- 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/releases):
 - Always add tests and ensure they pass.
 - Never break backward compatibility (see https://symfony.com/bc).
 - 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 master.
-->

Commits
-------

c16d153522 [Validator] Add missing vietnamese translations
2020-02-29 10:07:39 +01:00
Jan Schädlich
c16d153522 [Validator] Add missing vietnamese translations 2020-02-29 09:57:15 +01:00
Christian Flothmann
9d837ecb34 add German translation 2020-02-28 15:30:03 +01:00
Christian Flothmann
45a033d67b add missing Messenger options to XML schema definition 2020-02-28 14:15:16 +01:00
Nicolas Grekas
5ffb96452f minor #35861 [DomCrawler][Form] Fix PHPDoc on get & offsetGet (fancyweb)
This PR was merged into the 3.4 branch.

Discussion
----------

[DomCrawler][Form] Fix PHPDoc on get & offsetGet

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

`FormFieldRegistry::get()` returns mixed. For example, it can return an array when the field is a collection.

Commits
-------

f8735cc47b [DomCrawler][Form] Fix PHPDoc on get & offsetGet
2020-02-27 11:19:42 +01:00
Nicolas Grekas
dd8f580eda minor #35877 [Validator][ConstraintValidator] Update wrong PRETTY_DATE doc (fancyweb)
This PR was merged into the 3.4 branch.

Discussion
----------

[Validator][ConstraintValidator] Update wrong PRETTY_DATE doc

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

That is really minor but the current doc is not up to date with the real behavior.

Commits
-------

491fc5c24d [Validator][ConstraintValidator] Update wrong PRETTY_DATE doc
2020-02-27 11:12:24 +01:00
Thomas Calvet
491fc5c24d [Validator][ConstraintValidator] Update wrong PRETTY_DATE doc 2020-02-26 21:34:36 +01:00
Thomas Calvet
f8735cc47b [DomCrawler][Form] Fix PHPDoc on get & offsetGet 2020-02-26 18:12:32 +01:00
Nicolas Grekas
da0e2f94bb bug #35870 [ErrorHandler] fix parsing static return type on interface method annotation (alekitto)
This PR was merged into the 4.4 branch.

Discussion
----------

[ErrorHandler] fix parsing static return type on interface method annotation

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #35836
| License       | MIT

As suggested in the issue, the regex has been adapted to capture the return type, then it will be checked while determining if the method to be implemented should be static or just returns an instance of `static`.

Commits
-------

55734a297f [ErrorHandler] fix parsing static return type on interface method annotation (fix #35836)
2020-02-26 17:55:50 +01:00
Alessandro Chitolina
55734a297f
[ErrorHandler] fix parsing static return type on interface method annotation (fix #35836) 2020-02-26 12:45:31 +01:00
Robin Chalas
3057c68b93 Merge branch '3.4' into 4.4
* 3.4:
  [Security] Allow switching to another user when already switched
2020-02-26 11:27:30 +01:00
Nicolas Grekas
6f95125a09 bug #35839 [Security] Allow switching to another user when already switched (chalasr)
This PR was merged into the 3.4 branch.

Discussion
----------

[Security] Allow switching to another user when already switched

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #34690
| License       | MIT
| Doc PR        | -

Commits
-------

0353077083 [Security] Allow switching to another user when already switched
2020-02-26 10:44:17 +01:00
Robin Chalas
0353077083 [Security] Allow switching to another user when already switched 2020-02-26 04:23:24 +01:00
Nicolas Grekas
1b377a86db Merge branch '3.4' into 4.4
* 3.4:
  [FrameworkBundle] Fix test
2020-02-25 15:33:04 +01:00
Nicolas Grekas
159ef1bf1d [FrameworkBundle] Fix test 2020-02-25 15:31:47 +01:00
Nicolas Grekas
1107548146 Merge branch '3.4' into 4.4
* 3.4:
  minor #35833 [FrameworkBundle] Add missing items in the unused tag pass whitelist (fabpot)
  [Validator] Add missing translations
2020-02-25 15:19:32 +01:00
Nicolas Grekas
b515bc9a97 minor #35833 [FrameworkBundle] Add missing items in the unused tag pass whitelist (fabpot)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[FrameworkBundle] Add missing items in the unused tag pass whitelist

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tickets       | n/a <!-- prefix each issue number with "Fix #", if any -->
| License       | MIT
| Doc PR        | n/a

We have some missing tags in the whitelist. I've added a script that adds the missing ones, and added a test to avoid forgetting about updating the whitelist.

Commits
-------

d1bcc0fc5e [FrameworkBundle] Add a script that checks for missing items in the unused tag whitelist
2020-02-25 15:18:39 +01:00
Nicolas Grekas
cad3f10cdb minor #35822 [HttpClient][DX] Add URL context to JsonException messages (GromNaN)
This PR was squashed before being merged into the 4.4 branch.

Discussion
----------

[HttpClient][DX] Add URL context to JsonException messages

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | https://github.com/symfony/symfony/pull/35762#issuecomment-589770016
| License       | MIT
| Doc PR        | N/A

In order to help when debugging incorrect JSON responses, this PR adds the requested URL to the error message.

Before: `Syntax Error`
After: `JSON error: Syntax error, from "https://example.com/file.json".`
See the 2nd commit for full diff in new unit tests

Commits
-------

06539173e7 [HttpClient][DX] Add URL context to JsonException messages
2020-02-25 14:55:46 +01:00
Jérôme TAMARELLE
06539173e7 [HttpClient][DX] Add URL context to JsonException messages 2020-02-25 14:55:11 +01:00
Fabien Potencier
8a678f6679 minor #35819 [Messenger] Use Doctrine DBAL new Types::* constants (fancyweb)
This PR was merged into the 4.4 branch.

Discussion
----------

[Messenger] Use Doctrine DBAL new Types::* constants

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

Commits
-------

f1fb1597ff [Messenger] Use Doctrine DBAL new Types::* constants
2020-02-25 14:05:06 +01:00
Nicolas Grekas
ef95f2ecbc minor #35855 [Routing] Improve localized routes performances (mtarld)
This PR was merged into the 4.4 branch.

Discussion
----------

[Routing] Improve localized routes performances

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| License       | MIT

Implementation of the following idea: https://github.com/symfony/symfony/pull/35735#pullrequestreview-360525593

Improve route matching performances by turning dynamic routes with fixed `_locale` to actual static routes.

Commits
-------

8e9eafe18b [Routing] Improve localized routes performances
2020-02-25 13:47:10 +01:00
Fabien Potencier
88b96abe04 bug #35851 [4.4][DoctrineBridge] Use new Types::* constants and support new json types (fancyweb)
This PR was merged into the 4.4 branch.

Discussion
----------

[4.4][DoctrineBridge] Use new Types::* constants and support new json types

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | https://github.com/symfony/symfony/pull/35817#issuecomment-590419754
| License       | MIT
| Doc PR        | -

Commits
-------

ddf33535d0 [4.4][DoctrineBridge] Use new Types::* constants and support new json type
2020-02-25 13:46:09 +01:00
Mathias Arlaud
8e9eafe18b [Routing] Improve localized routes performances 2020-02-25 13:41:09 +01:00
Thomas Calvet
ddf33535d0 [4.4][DoctrineBridge] Use new Types::* constants and support new json type 2020-02-24 18:16:47 +01:00
Fabien Potencier
d7250ef620 [Validator] Add missing translations 2020-02-24 18:16:32 +01:00
Nicolas Grekas
1024f5fc10 bug #35716 [PhpUnitBridge] Fix compatibility to PHPUnit 9 (Benjamin)
This PR was merged into the 4.4 branch.

Discussion
----------

[PhpUnitBridge] Fix compatibility to PHPUnit 9

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #35662
| License       | MIT
| Doc PR        |  -

Adding the possibility to use PHPUnit 9.

Commits
-------

771c642a43 [PhpUnitBridge] Add compatibility to PHPUnit 9 #35662
2020-02-24 15:58:55 +01:00
Nicolas Grekas
c0caef1708 bug #35803 [Cache] Fix versioned namespace atomic clears (trvrnrth)
This PR was merged into the 4.4 branch.

Discussion
----------

[Cache] Fix versioned namespace atomic clears

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| License       | MIT

When using namespace versioning to achieve atomic cache clears, only delete cache keys matching the old/current version.

This resolves tag inconsistency issues whereby the process running the clear would delete keys set against the new version by more recently spawned concurrent processes. Most seriously this could result in newly set data keys remaining, but with empty associated tag sets meaning the invalidation via tags was no longer possible.

Clearing specific prefixes is not supported when using versioned namespaces as it is desirable to clear all old keys as they will no longer be used and would otherwise eventually fill cache memory.

Commits
-------

971b177d27 Fix versioned namespace clears
2020-02-24 15:49:35 +01:00