You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
minor #26225 Make deprecation notices less verbose (fabpot)
This PR was merged into the 4.1-dev branch.
Discussion
----------
Make deprecation notices less verbose
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
I think there is no need to say that deprecated features will be removed in the next major version. That makes messages more verbose for no real reasons.
Commits
-------
0c6ec3f made deprecation notices less verbose
Copy file name to clipboardExpand all lines: UPGRADE-4.1.md
+14-16
Original file line number
Diff line number
Diff line change
@@ -5,48 +5,46 @@ Config
5
5
------
6
6
7
7
* Implementing `ParentNodeDefinitionInterface` without the `getChildNodeDefinitions()` method
8
-
is deprecated and will be unsupported in 5.0.
8
+
is deprecated.
9
9
10
10
EventDispatcher
11
11
---------------
12
12
13
-
* The `TraceableEventDispatcherInterface` has been deprecated and will be removed in 5.0.
13
+
* The `TraceableEventDispatcherInterface` has been deprecated.
14
14
15
15
FrameworkBundle
16
16
---------------
17
17
18
-
* A `RouterInterface` that does not implement the `WarmableInterface` is deprecated and will not be supported in Symfony 5.0.
19
-
* The `RequestDataCollector` class has been deprecated and will be removed in Symfony 5.0. Use the `Symfony\Component\HttpKernel\DataCollector\RequestDataCollector` class instead.
18
+
* A `RouterInterface` that does not implement the `WarmableInterface` is deprecated.
19
+
* The `RequestDataCollector` class has been deprecated. Use the `Symfony\Component\HttpKernel\DataCollector\RequestDataCollector` class instead.
20
20
21
21
HttpFoundation
22
22
--------------
23
23
24
-
* Passing the file size to the constructor of the `UploadedFile` class is deprecated and won't be
25
-
supported anymore in 5.0.
24
+
* Passing the file size to the constructor of the `UploadedFile` class is deprecated.
26
25
27
26
* The `getClientSize()` method of the `UploadedFile` class is deprecated. Use `getSize()` instead.
28
27
29
28
Security
30
29
--------
31
30
32
-
* The `ContextListener::setLogoutOnUserChange()` method is deprecated and will be removed in 5.0.
31
+
* The `ContextListener::setLogoutOnUserChange()` method is deprecated.
33
32
* Using the `AdvancedUserInterface` is now deprecated. To use the existing
34
33
functionality, create a custom user-checker based on the
35
-
`Symfony\Component\Security\Core\User\UserChecker`. This functionality will
* The `FileDumper::setBackup()` method is deprecated and will be removed in 5.0.
49
-
* The `TranslationWriter::disableBackup()` method is deprecated and will be removed in 5.0.
46
+
* The `FileDumper::setBackup()` method is deprecated.
47
+
* The `TranslationWriter::disableBackup()` method is deprecated.
50
48
51
49
TwigBundle
52
50
----------
@@ -56,9 +54,9 @@ TwigBundle
56
54
Validator
57
55
--------
58
56
59
-
* The `Email::__construct()` 'strict' property is deprecated and will be removed in 5.0. Use 'mode'=>"strict" instead.
60
-
* Calling `EmailValidator::__construct()` method with a boolean parameter is deprecated and will be removed in 5.0, use `EmailValidator("strict")` instead.
61
-
* Deprecated the `checkDNS` and `dnsMessage` options of the `Url` constraint. They will be removed in 5.0.
57
+
* The `Email::__construct()` 'strict' property is deprecated. Use 'mode'=>"strict" instead.
58
+
* Calling `EmailValidator::__construct()` method with a boolean parameter is deprecated, use `EmailValidator("strict")` instead.
59
+
* Deprecated the `checkDNS` and `dnsMessage` options of the `Url` constraint.
Copy file name to clipboardExpand all lines: src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -8,8 +8,8 @@ CHANGELOG
8
8
* Added a new `parameter_bag` service with related autowiring aliases to access parameters as-a-service
9
9
* Allowed the `Router` to work with any PSR-11 container
10
10
* Added option in workflow dump command to label graph with a custom label
11
-
* Using a `RouterInterface` that does not implement the `WarmableInterface` is deprecated and will not be supported in Symfony 5.0.
12
-
* The `RequestDataCollector` class has been deprecated and will be removed in Symfony 5.0. Use the `Symfony\Component\HttpKernel\DataCollector\RequestDataCollector` class instead.
11
+
* Using a `RouterInterface` that does not implement the `WarmableInterface` is deprecated.
12
+
* The `RequestDataCollector` class has been deprecated. Use the `Symfony\Component\HttpKernel\DataCollector\RequestDataCollector` class instead.
13
13
* The `RedirectController` class allows for 307/308 HTTP status codes
@trigger_error(sprintf('The "%s" class is deprecated since version 4.1 and will be removed in Symfony 5.0. Use %s instead.', RequestDataCollector::class, BaseRequestDataCollector::class), E_USER_DEPRECATED);
16
+
@trigger_error(sprintf('The "%s" class is deprecated since Symfony 4.1. Use %s instead.', RequestDataCollector::class, BaseRequestDataCollector::class), E_USER_DEPRECATED);
17
17
18
18
/**
19
19
* RequestDataCollector.
20
20
*
21
21
* @author Jules Pietri <jusles@heahprod.com>
22
22
*
23
-
* @deprecated since version 4.1, to be removed in Symfony 5.0
23
+
* @deprecated since Symfony 4.1
24
24
*/
25
25
class RequestDataCollector extends BaseRequestDataCollector
<deprecated>The "%service_id%" service is deprecated since Symfony 4.1 and will be removed in 5.0. Use the "session_listener" service instead.</deprecated>
73
+
<deprecated>The "%service_id%" service is deprecated since Symfony 4.1. Use the "session_listener" service instead.</deprecated>
@trigger_error(sprintf('The "%s" class is deprecated since Symfony 4.1 and will be removed in 5.0, use "%s" instead.', SecurityUserValueResolver::class, UserValueResolver::class), E_USER_DEPRECATED);
22
+
@trigger_error(sprintf('The "%s" class is deprecated since Symfony 4.1, use "%s" instead.', SecurityUserValueResolver::class, UserValueResolver::class), E_USER_DEPRECATED);
23
23
24
24
/**
25
25
* Supports the argument type of {@see UserInterface}.
26
26
*
27
27
* @author Iltar van der Berg <kjarli@gmail.com>
28
28
*
29
-
* @deprecated since Symfony 4.1, to be removed in 5.0. Use {@link UserValueResolver} instead
29
+
* @deprecated since Symfony 4.1, use {@link UserValueResolver} instead
Copy file name to clipboardExpand all lines: src/Symfony/Component/Config/Definition/Builder/NodeDefinition.php
+1-1
Original file line number
Diff line number
Diff line change
@@ -364,7 +364,7 @@ public function setPathSeparator(string $separator)
364
364
$child->setPathSeparator($separator);
365
365
}
366
366
} else {
367
-
@trigger_error('Passing a ParentNodeDefinitionInterface without getChildNodeDefinitions() is deprecated since version 4.1 and will be removed in 5.0.', E_USER_DEPRECATED);
367
+
@trigger_error('Passing a ParentNodeDefinitionInterface without getChildNodeDefinitions() is deprecated since Symfony 4.1.', E_USER_DEPRECATED);
@trigger_error(sprintf('Passing a size as 4th argument to the constructor of "%s" is deprecated since Symfony 4.1 and will be unsupported in 5.0.', __CLASS__), E_USER_DEPRECATED);
62
+
@trigger_error(sprintf('Passing a size as 4th argument to the constructor of "%s" is deprecated since Symfony 4.1.', __CLASS__), E_USER_DEPRECATED);
Copy file name to clipboardExpand all lines: src/Symfony/Component/HttpFoundation/Tests/File/UploadedFileTest.php
+2-2
Original file line number
Diff line number
Diff line change
@@ -195,7 +195,7 @@ public function testGetSize()
195
195
196
196
/**
197
197
* @group legacy
198
-
* @expectedDeprecation Passing a size as 4th argument to the constructor of "Symfony\Component\HttpFoundation\File\UploadedFile" is deprecated since Symfony 4.1 and will be unsupported in 5.0.
198
+
* @expectedDeprecation Passing a size as 4th argument to the constructor of "Symfony\Component\HttpFoundation\File\UploadedFile" is deprecated since Symfony 4.1.
199
199
*/
200
200
publicfunctiontestConstructDeprecatedSize()
201
201
{
@@ -213,7 +213,7 @@ public function testConstructDeprecatedSize()
213
213
214
214
/**
215
215
* @group legacy
216
-
* @expectedDeprecation Passing a size as 4th argument to the constructor of "Symfony\Component\HttpFoundation\File\UploadedFile" is deprecated since Symfony 4.1 and will be unsupported in 5.0.
216
+
* @expectedDeprecation Passing a size as 4th argument to the constructor of "Symfony\Component\HttpFoundation\File\UploadedFile" is deprecated since Symfony 4.1.
@trigger_error(sprintf('The "%s" class is deprecated since Symfony 4.1 and will be removed in 5.0. Use AbstractSessionListener instead.', SaveSessionListener::class), E_USER_DEPRECATED);
14
+
@trigger_error(sprintf('The "%s" class is deprecated since Symfony 4.1, use AbstractSessionListener instead.', SaveSessionListener::class), E_USER_DEPRECATED);
Copy file name to clipboardExpand all lines: src/Symfony/Component/Security/Core/Authentication/Token/AbstractToken.php
+2-2
Original file line number
Diff line number
Diff line change
@@ -261,7 +261,7 @@ private function hasUserChanged(UserInterface $user)
261
261
}
262
262
263
263
if ($this->userinstanceof AdvancedUserInterface && $userinstanceof AdvancedUserInterface) {
264
-
@trigger_error(sprintf('Checking for the AdvancedUserInterface in %s has been deprecated in 4.1 and will be removed in 5.0. Implement the %s to check if the user has been changed,', __METHOD__, EquatableInterface::class), E_USER_DEPRECATED);
264
+
@trigger_error(sprintf('Checking for the AdvancedUserInterface in %s has been deprecated in 4.1. Implement the %s to check if the user has been changed,', __METHOD__, EquatableInterface::class), E_USER_DEPRECATED);
265
265
if ($this->user->isAccountNonExpired() !== $user->isAccountNonExpired()) {
266
266
returntrue;
267
267
}
@@ -278,7 +278,7 @@ private function hasUserChanged(UserInterface $user)
@trigger_error(sprintf('Checking for the AdvancedUserInterface in %s has been deprecated in 4.1 and will be removed in 5.0. Implement the %s to check if the user has been changed,', __METHOD__, EquatableInterface::class), E_USER_DEPRECATED);
281
+
@trigger_error(sprintf('Checking for the AdvancedUserInterface in %s has been deprecated in 4.1. Implement the %s to check if the user has been changed,', __METHOD__, EquatableInterface::class), E_USER_DEPRECATED);
Copy file name to clipboardExpand all lines: src/Symfony/Component/Security/Core/Tests/User/UserCheckerTest.php
+6-6
Original file line number
Diff line number
Diff line change
@@ -32,7 +32,7 @@ public function testCheckPostAuthPass()
32
32
33
33
/**
34
34
* @group legacy
35
-
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPostAuth with an AdvancedUserInterface is deprecated as of 4.1 and will be removed in 5.0. Create a custom user checker if you wish to keep this functionality.
35
+
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPostAuth with an AdvancedUserInterface is deprecated since Symfony 4.1. Create a custom user checker if you wish to keep this functionality.
36
36
*/
37
37
publicfunctiontestCheckPostAuthPassAdvancedUser()
38
38
{
@@ -55,7 +55,7 @@ public function testCheckPostAuthCredentialsExpired()
55
55
56
56
/**
57
57
* @group legacy
58
-
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPostAuth with an AdvancedUserInterface is deprecated as of 4.1 and will be removed in 5.0. Create a custom user checker if you wish to keep this functionality.
58
+
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPostAuth with an AdvancedUserInterface is deprecated since Symfony 4.1. Create a custom user checker if you wish to keep this functionality.
@@ -70,7 +70,7 @@ public function testCheckPostAuthCredentialsExpiredAdvancedUser()
70
70
71
71
/**
72
72
* @group legacy
73
-
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPreAuth with an AdvancedUserInterface is deprecated as of 4.1 and will be removed in 5.0. Create a custom user checker if you wish to keep this functionality.
73
+
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPreAuth with an AdvancedUserInterface is deprecated since Symfony 4.1. Create a custom user checker if you wish to keep this functionality.
74
74
*/
75
75
publicfunctiontestCheckPreAuthPassAdvancedUser()
76
76
{
@@ -95,7 +95,7 @@ public function testCheckPreAuthAccountLocked()
95
95
96
96
/**
97
97
* @group legacy
98
-
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPreAuth with an AdvancedUserInterface is deprecated as of 4.1 and will be removed in 5.0. Create a custom user checker if you wish to keep this functionality.
98
+
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPreAuth with an AdvancedUserInterface is deprecated since Symfony 4.1. Create a custom user checker if you wish to keep this functionality.
@@ -119,7 +119,7 @@ public function testCheckPreAuthDisabled()
119
119
120
120
/**
121
121
* @group legacy
122
-
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPreAuth with an AdvancedUserInterface is deprecated as of 4.1 and will be removed in 5.0. Create a custom user checker if you wish to keep this functionality.
122
+
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPreAuth with an AdvancedUserInterface is deprecated since Symfony 4.1. Create a custom user checker if you wish to keep this functionality.
@@ -144,7 +144,7 @@ public function testCheckPreAuthAccountExpired()
144
144
145
145
/**
146
146
* @group legacy
147
-
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPreAuth with an AdvancedUserInterface is deprecated as of 4.1 and will be removed in 5.0. Create a custom user checker if you wish to keep this functionality.
147
+
* @expectedDeprecation Calling Symfony\Component\Security\Core\User\UserChecker::checkPreAuth with an AdvancedUserInterface is deprecated since Symfony 4.1. Create a custom user checker if you wish to keep this functionality.
0 commit comments