Commit Graph

47785 Commits

Author SHA1 Message Date
Wouter de Jong 3c8d316f65 Added ROLE_PREVIOUS_ADMIN deprecation to UPGRADE guide 2020-02-28 12:20:28 +01:00
Nicolas Grekas d0e5593b1f Merge branch '5.0'
* 5.0:
  [FrameworkBundle] Fix test
2020-02-25 15:44:02 +01:00
Nicolas Grekas cd355dff07 Merge branch '4.4' into 5.0
* 4.4:
  [FrameworkBundle] Fix test
2020-02-25 15:39:06 +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 c56cf2da5d Merge branch '5.0'
* 5.0:
  minor #35833 [FrameworkBundle] Add missing items in the unused tag pass whitelist (fabpot)
  [HttpClient][DX] Add URL context to JsonException messages
  [Routing] Improve localized routes performances
  [4.4][DoctrineBridge] Use new Types::* constants and support new json type
  [Validator] Add missing translations
  [Notifier] Dispatch message event in null transport
  [Messenger] Use Doctrine DBAL new Types::* constants
2020-02-25 15:29:12 +01:00
Nicolas Grekas 11097a5aa6 Merge branch '4.4' into 5.0
* 4.4:
  minor #35833 [FrameworkBundle] Add missing items in the unused tag pass whitelist (fabpot)
  [HttpClient][DX] Add URL context to JsonException messages
  [Routing] Improve localized routes performances
  [4.4][DoctrineBridge] Use new Types::* constants and support new json type
  [Validator] Add missing translations
  [Messenger] Use Doctrine DBAL new Types::* constants
2020-02-25 15:24:11 +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
Nicolas Grekas 7b89d1b004 feature #35815 [Validator] Allow Sequentially constraints on classes + target guards (ogizanagi)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[Validator] Allow Sequentially constraints on classes + target guards

| Q             | A
| ------------- | ---
| Branch?       | master <!-- see below -->
| Bug fix?      | no
| New feature?  | yes <!-- 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        | todo in https://github.com/symfony/symfony-docs/pull/13206 if not merged yet

There is no reason to limit this constraint to properties, so let's add classes as targets.

Additionally, let's ensure embedded constraints matches allowed targets too.

Commits
-------

1e02a96286 [Validator] Allow Sequentially constraints on classes
2020-02-25 14:41:21 +01:00
Nicolas Grekas d297231c56 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 14:09:27 +01:00
Fabien Potencier d1bcc0fc5e [FrameworkBundle] Add a script that checks for missing items in the unused tag whitelist 2020-02-25 14:08:07 +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
Fabien Potencier 53df70e374 feature #35747 [Routing][FrameworkBundle] Allow using env() in route conditions (atailouloute)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[Routing][FrameworkBundle] Allow using env() in route conditions

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

This is a second implementation of #35727, it overcomes the limitation mentioned by nicolas in (https://github.com/symfony/symfony/pull/35727#issuecomment-586413390)

The goal of this feature is to be able to use env variables in Route conditions

```php
/**
 * @Route("/only-for-dev", condition="env('APP_ENV') === 'dev'")
 */
public function __invoke()
{
   echo "This will be executed only when APP_ENV = dev";
}
```
it supports also env processors/ loaders
```php
/**
 * @Route("/only-for-dev", condition="env('trim:APP_ENV') === 'dev'")
 */
````

**TODOs:**
- [x] Complete unit tests

Commits
-------

b5744601bf [Routing][FrameworkBundle] Allow using env() in route conditions
2020-02-25 14:01:25 +01:00
Ahmed TAILOULOUTE b5744601bf [Routing][FrameworkBundle] Allow using env() in route conditions 2020-02-25 14:01:02 +01:00
Fabien Potencier 8867f57a44 feature #35857 [Routing] deprecate RouteCompiler::REGEX_DELIMITER (nicolas-grekas)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[Routing] deprecate RouteCompiler::REGEX_DELIMITER

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

This should be mostly internal cleanup.

Commits
-------

21b8a64446 [Routing] deprecate RouteCompiler::REGEX_DELIMITER
2020-02-25 13:53:07 +01:00
Fabien Potencier 28a249f2e5 feature #35804 [HttpFoundation] Added MarshallingSessionHandler (atailouloute)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[HttpFoundation] Added MarshallingSessionHandler

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

Added `MarshallingSessionHandler`, a decorator for session handlers which uses the cache marshaller in order to encrypt session data.

(This is an alternative solution to #35643)

To use it, we can simply decorate the session marshaller, after that all session data will be encrypted

```yaml
Symfony\Component\Cache\Marshaller\SodiumMarshaller:
    decorates: 'session.marshaller'
    arguments:
        - ['%env(file:resolve:SODIUM_DECRYPTION_FILE)%']
        - '@Symfony\Component\Cache\Marshaller\SodiumMarshaller.inner'
```

TODO:
- [x] unit tests

Commits
-------

155d980aea [HttpFoundation][Cache] Added MarshallingSessionHandler
2020-02-25 13:51:34 +01:00
Fabien Potencier 82db995908 feature #35858 [Security] Deprecated ROLE_PREVIOUS_ADMIN (wouterj)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[Security] Deprecated ROLE_PREVIOUS_ADMIN

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| Deprecations? | yes
| Tickets       | n/a
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/pull/11487

`ROLE_PREVIOUS_ADMIN` is added to the token roles if the session is an impersonation. Since https://github.com/symfony/symfony/pull/31189 we have the `IS_IMPERSONATOR` attribute which can be used for the same reason. I propose to deprecate the `ROLE_PREVIOUS_ADMIN`:

* This is not what roles are for ([resulting in hacking this exception in `AbstractToken`](https://github.com/symfony/symfony/blob/5.0/src/Symfony/Component/Security/Core/Authentication/Token/AbstractToken.php#L275-L277))
* The role isn't very descriptive
* I don't like having 2 ways of doing exactly the same thing
* While every application with impersonation enabled probably needs to be updated, the update is as simple as replacing `ROLE_PREVIOUS_ADMIN` with `IS_IMPERSONATOR`: `find ./ -type f -exec sed -i 's/ROLE_PREVIOUS_ADMIN/IS_IMPERSONATOR/g' {} +`

---

I'm a bit unsure on how to deprecate this role, but I think having it in `RoleVoter` is probably the safest (`isGranted()` and variants + `AccessDecisionManager#decide()` all use this voter to check if the token has this role).

Commits
-------

dce55f352a Deprecated ROLE_PREVIOUS_ADMIN
2020-02-25 13:48:58 +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
Fabien Potencier a4c0bfacee minor #35854 [Security] Use new IS_* attributes in the expression language functions (wouterj)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[Security] Use new IS_* attributes in the expression language functions

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | n/a
| License       | MIT
| Doc PR        | n/a

#31189 has been merged which introduces some new attributes (`IS_ANONYMOUS` & friends). We can now modify the code behind the `is_*()` expression language functions to use these new attributes. This avoids any possibility of having them out of sync.

In case you - just like me - are interested why `isGranted("IS_AUTHENTICATED_FULLY")` wasn't used before: These functions were implemented without `auth_checker` being available. The auth checker  variable was introduced in 4.2 by #27305, so now we can use this.

Commits
-------

3f0c599289 Use new IS_* attributes in the expression language functions
2020-02-25 13:43:42 +01:00
Mathias Arlaud 8e9eafe18b [Routing] Improve localized routes performances 2020-02-25 13:41:09 +01:00
Wouter de Jong dce55f352a Deprecated ROLE_PREVIOUS_ADMIN 2020-02-25 13:38:33 +01:00
Wouter J 3f0c599289 Use new IS_* attributes in the expression language functions 2020-02-25 12:47:18 +01:00
Nicolas Grekas 21b8a64446 [Routing] deprecate RouteCompiler::REGEX_DELIMITER 2020-02-25 11:55:47 +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
Fabien Potencier ff9b8dae88 minor #35850 [Validator] Add missing translations (fabpot)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[Validator] Add missing translations

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| 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

Backport translations for 5.1.

Commits
-------

a9021861f6 [Validator] Add missing translations
2020-02-24 18:15:09 +01:00
Fabien Potencier a9021861f6 [Validator] Add missing translations 2020-02-24 18:11:18 +01:00
Fabien Potencier 8b819ba442 bug #35841 [Notifier] Dispatch message event in null transport (jschaedl)
This PR was squashed before being merged into the 5.0 branch.

Discussion
----------

[Notifier] Dispatch message event in null transport

| Q             | A
| ------------- | ---
| Branch?       | 5.0
| Bug fix?      | yes
| 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 -->

I think we should be able to log notifications via the `NotificationLoggerListener` even if they were sent to a null transport. The mailer component does it the same way.

Commits
-------

a0d99ce398 [Notifier] Dispatch message event in null transport
2020-02-24 18:03:22 +01:00
Jan Schädlich a0d99ce398 [Notifier] Dispatch message event in null transport 2020-02-24 18:03:13 +01:00
Fabien Potencier b5e6582398 feature #35848 [Validator] add alpha3 option to Language constraint (xabbuh)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[Validator] add alpha3 option to Language constraint

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

Commits
-------

ce73b98e2c add alpha3 option to Language constraint
2020-02-24 17:28:00 +01:00
Fabien Potencier 6178c63148 feature #31189 [Security] Add IS_IMPERSONATOR, IS_ANONYMOUS and IS_REMEMBERED (HeahDude)
This PR was merged into the 5.1-dev branch.

Discussion
----------

[Security] Add IS_IMPERSONATOR, IS_ANONYMOUS and IS_REMEMBERED

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

This continues work of @HeahDude and finally finishes one of the code PRs I've been working on during the ️ EUFOSSA Hackathon.

Changes
---

The PRs modifies some of the attributes used by the `AuthenticatedVoter`:

* New `IS_IMPERSONATOR`, `IS_ANONYMOUS` and `IS_REMEMBERED` attributes are introduced to indicate the user either impersonated, anonymous or rembered.
* <s>`IS_AUTHENTICATED_ANONYMOUSLY` actually meant "is authenticated, either anonymous or fully". As this is confusing, it is replaced by `IS_AUTHENTICATED`.</s>
* <s>All `is_*()` functions in expressions are deprecated in favor of `is_granted('IS_*')`. It's not worth duplicating the `AuthenticatedVoter` logic in two places now we have shorter `IS_*` attributes</s>

**Before**

```php
if ($authorizationChecker->isGranted('ROLE_PREVIOUS_ADMIN')) {
    // ...
}
```
<s>

```yaml
security:
  # ...

  access_control:
    - { path: ^/protected, roles: 'IS_AUTHENTICATED_ANONYMOUSLY' }
```
</s>

**After**

```php
if ($authorizationChecker->isGranted('IS_IMPERSONATOR')) {
    // ...
}
```
<s>

```yaml
security:
  # ...

  access_control:
    - { path: ^/protected, roles: 'IS_AUTHENTICATED' }
```
</s>

<s>Discussion
---

The only thing I'm wondering is how we combine this with the `is_authenticated()` expression function:

98929dc292/src/Symfony/Component/Security/Core/Authorization/ExpressionLanguageProvider.php (L33-L37)

As you can see, the `IS_AUTHENTICATED` attribute and `is_authenticated()` expression function do not have the same meaning. Should we somehow deprecate the current behavior of `is_authenticated()` or should we find another name for `IS_AUTHENTICATED` (that would be a shame imo).</s>

Commits
-------

6c522a7d98 Added IS_ANONYMOUS, IS_REMEMBERED, IS_IMPERSONATOR
2020-02-24 17:01:02 +01:00
Nicolas Grekas c231214e59 Merge branch '5.0'
* 5.0: (28 commits)
  [DoctrineBridge] Use new Types::* constants and support new json type
  Fix bad merge in README of Nexmo Notifier bridge
  [Debug][ErrorHandler] improved deprecation notices for methods new args and return type
  [BrowserKit] Nested file array prevents uploading file
  [ExpressionLanguage] Fixed collisions of character operators with object properties
  remove usage of already deleted Symfony\Component\EventDispatcher\Event
  [Notifier] Add correct tags for NullTransportFactory
  [Validator] Remove specific check for Valid targets
  [PhpUnitBridge] Use trait instead of extending deprecated class
  Fix versioned namespace clears
  fix remember me
  Use strict assertion in asset tests
  [DoctrineBridge][DoctrineExtractor] Fix indexBy with custom and some core types
  Do not rely on the current locale when dumping a Graphviz object
  fix typo
  [Ldap] force default network timeout
  [Config] don't throw on missing excluded paths
  Docs: Typo, grammar
  [Validator] Add the missing translations for the Polish ("pl") locale
  [PhpUnitBridge] Add compatibility to PHPUnit 9 #35662
  ...
2020-02-24 16:14:17 +01:00
Nicolas Grekas 08a233bc6d Merge branch '4.4' into 5.0
* 4.4: (25 commits)
  [DoctrineBridge] Use new Types::* constants and support new json type
  [Debug][ErrorHandler] improved deprecation notices for methods new args and return type
  [BrowserKit] Nested file array prevents uploading file
  [ExpressionLanguage] Fixed collisions of character operators with object properties
  [Validator] Remove specific check for Valid targets
  [PhpUnitBridge] Use trait instead of extending deprecated class
  Fix versioned namespace clears
  fix remember me
  Use strict assertion in asset tests
  [DoctrineBridge][DoctrineExtractor] Fix indexBy with custom and some core types
  Do not rely on the current locale when dumping a Graphviz object
  fix typo
  [Ldap] force default network timeout
  [Config] don't throw on missing excluded paths
  Docs: Typo, grammar
  [Validator] Add the missing translations for the Polish ("pl") locale
  [PhpUnitBridge] Add compatibility to PHPUnit 9 #35662
  [Routing] Add locale requirement for localized routes
  [Console] Inline exact-match handling with 4.4
  Set previous exception when rethrown from controller resolver
  ...
2020-02-24 16:05:31 +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
Christian Flothmann ce73b98e2c add alpha3 option to Language constraint 2020-02-24 15:47:52 +01:00
Nicolas Grekas 2d53ff64c9 Merge branch '3.4' into 4.4
* 3.4:
  [DoctrineBridge] Use new Types::* constants and support new json type
2020-02-24 15:14:40 +01:00
Nicolas Grekas 9819814a8a bug #35817 [3.4][DoctrineBridge] Use new Types::* constants and support new json type (fancyweb)
This PR was merged into the 3.4 branch.

Discussion
----------

[3.4][DoctrineBridge] Use new Types::* constants and support new json type

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

All `Type::*` constants were moved and deprecated. This PR makes sure we use the good ones when they exist so we are prepared for their removal. It allows to be deprecation free. If deprecated constants could be detected, we would have failing tests 😄

Also, `json_array` was deprecated and renamed to `json`, so I added support for this new type.

Some new components also use these constants on upper branches, so I will submit PRs there.

Commits
-------

3e35fa59ea [DoctrineBridge] Use new Types::* constants and support new json type
2020-02-24 14:39:45 +01:00
Fabien Potencier f4332cb109 Merge branch '5.0'
* 5.0:
  [FrameworkBundle] Skip notifiers tags in UnusedTagsPass
  [Notifier] Remove not needed argument $bus in BrowserChannel::notify()
2020-02-24 14:39:20 +01:00
Thomas Calvet f1fb1597ff [Messenger] Use Doctrine DBAL new Types::* constants 2020-02-24 14:12:43 +01:00
Thomas Calvet 3e35fa59ea [DoctrineBridge] Use new Types::* constants and support new json type 2020-02-24 14:11:05 +01:00
Fabien Potencier a67abe1fb6 Merge branch '3.4' into 4.4
* 3.4:
  [ExpressionLanguage] Fixed collisions of character operators with object properties
  [Validator] Remove specific check for Valid targets
  [PhpUnitBridge] Use trait instead of extending deprecated class
  fix remember me
  Use strict assertion in asset tests
  [DoctrineBridge][DoctrineExtractor] Fix indexBy with custom and some core types
  Do not rely on the current locale when dumping a Graphviz object
  fix typo
  [Ldap] force default network timeout
  [Config] don't throw on missing excluded paths
  Docs: Typo, grammar
  [Validator] Add the missing translations for the Polish ("pl") locale
  [Console] Inline exact-match handling with 4.4
  Set previous exception when rethrown from controller resolver
  [VarDumper] fixed DateCaster not displaying additional fields
  [HttpKernel] fix registering DebugHandlersListener regardless of the PHP_SAPI
2020-02-24 14:10:00 +01:00
Nicolas Grekas da28445ea4 bug #35832 [Debug][ErrorHandler] improved deprecation notices for methods new args and return type (HeahDude)
This PR was merged into the 4.4 branch.

Discussion
----------

[Debug][ErrorHandler] improved deprecation notices for methods new args and return type

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

~I don't know if this should be considered a bug fix or a feature.~

Commits
-------

83d4aa7683 [Debug][ErrorHandler] improved deprecation notices for methods new args and return type
2020-02-24 10:54:50 +01:00
Nicolas Grekas d29865ed79 minor #35835 Fix bad merge in README of Nexmo Notifier bridge (eXtreme)
This PR was merged into the 5.0 branch.

Discussion
----------

Fix bad merge in README of Nexmo Notifier bridge

| Q             | A
| ------------- | ---
| Branch?       |  5.0
| License       | MIT

[Bad merge](85f793bec6 (diff-ba05e8af79b613430b91ba4d4ccbea0d)) made b52b7b9fd6 end up in Nexmo README :)

Commits
-------

a8d0c5b1d7 Fix bad merge in README of Nexmo Notifier bridge
2020-02-24 10:52:43 +01:00
Ahmed TAILOULOUTE 155d980aea [HttpFoundation][Cache] Added MarshallingSessionHandler 2020-02-23 23:33:06 +01:00
Nicolas Grekas f75be008bc minor #35816 [Validator] Remove specific check for Valid targets (ogizanagi)
This PR was merged into the 3.4 branch.

Discussion
----------

[Validator] Remove specific check for Valid targets

| Q             | A
| ------------- | ---
| Branch?       | 3.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 -->
| Tickets       | N/A <!-- prefix each issue number with "Fix #", if any -->
| License       | MIT
| Doc PR        | N/A

As covered by `ClassMetadataTest::testAddConstraintDoesNotAcceptValid`, this check is useless, as `Valid` already accepts only properties as targets.

This check is a [leftover of a time](9b07b0c672) `Valid` was extending `Traverse` which was allowing classes & properties.
The `Valid` targets are properly checked by the lines above, the same way as other constraints.

Commits
-------

0086562c77 [Validator] Remove specific check for Valid targets
2020-02-23 22:17:02 +01:00