Skip to content

Commit 43f8081

Browse files
committed
minor symfony#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
2 parents 17d1054 + 0c6ec3f commit 43f8081

File tree

34 files changed

+93
-99
lines changed

34 files changed

+93
-99
lines changed

UPGRADE-4.1.md

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -5,48 +5,46 @@ Config
55
------
66

77
* Implementing `ParentNodeDefinitionInterface` without the `getChildNodeDefinitions()` method
8-
is deprecated and will be unsupported in 5.0.
8+
is deprecated.
99

1010
EventDispatcher
1111
---------------
1212

13-
* The `TraceableEventDispatcherInterface` has been deprecated and will be removed in 5.0.
13+
* The `TraceableEventDispatcherInterface` has been deprecated.
1414

1515
FrameworkBundle
1616
---------------
1717

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

2121
HttpFoundation
2222
--------------
2323

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

2726
* The `getClientSize()` method of the `UploadedFile` class is deprecated. Use `getSize()` instead.
2827

2928
Security
3029
--------
3130

32-
* The `ContextListener::setLogoutOnUserChange()` method is deprecated and will be removed in 5.0.
31+
* The `ContextListener::setLogoutOnUserChange()` method is deprecated.
3332
* Using the `AdvancedUserInterface` is now deprecated. To use the existing
3433
functionality, create a custom user-checker based on the
35-
`Symfony\Component\Security\Core\User\UserChecker`. This functionality will
36-
be removed in Symfony 5.0.
34+
`Symfony\Component\Security\Core\User\UserChecker`.
3735

3836
SecurityBundle
3937
--------------
4038

41-
* The `logout_on_user_change` firewall option is deprecated and will be removed in 5.0.
42-
* The `SecurityUserValueResolver` class is deprecated and will be removed in 5.0, use
39+
* The `logout_on_user_change` firewall option is deprecated.
40+
* The `SecurityUserValueResolver` class is deprecated, use
4341
`Symfony\Component\Security\Http\Controller\UserValueResolver` instead.
4442

4543
Translation
4644
-----------
4745

48-
* 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.
5048

5149
TwigBundle
5250
----------
@@ -56,9 +54,9 @@ TwigBundle
5654
Validator
5755
--------
5856

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

6361
Workflow
6462
--------

src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ CHANGELOG
88
* Added a new `parameter_bag` service with related autowiring aliases to access parameters as-a-service
99
* Allowed the `Router` to work with any PSR-11 container
1010
* 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.
1313
* The `RedirectController` class allows for 307/308 HTTP status codes
1414

1515
4.0.0

src/Symfony/Bundle/FrameworkBundle/DataCollector/RequestDataCollector.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@
1313

1414
use Symfony\Component\HttpKernel\DataCollector\RequestDataCollector as BaseRequestDataCollector;
1515

16-
@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);
1717

1818
/**
1919
* RequestDataCollector.
2020
*
2121
* @author Jules Pietri <[email protected]>
2222
*
23-
* @deprecated since version 4.1, to be removed in Symfony 5.0
23+
* @deprecated since Symfony 4.1
2424
*/
2525
class RequestDataCollector extends BaseRequestDataCollector
2626
{

src/Symfony/Bundle/FrameworkBundle/Resources/config/session.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
</service>
7171

7272
<service id="session.save_listener" class="Symfony\Component\HttpKernel\EventListener\SaveSessionListener">
73-
<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>
7474
</service>
7575

7676
<!-- for BC -->

src/Symfony/Bundle/SecurityBundle/CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ CHANGELOG
44
4.1.0
55
-----
66

7-
* The `logout_on_user_change` firewall option is deprecated and will be removed in 5.0.
7+
* The `logout_on_user_change` firewall option is deprecated.
88
* deprecated `SecurityUserValueResolver`, use
99
`Symfony\Component\Security\Http\Controller\UserValueResolver` instead.
1010

src/Symfony/Bundle/SecurityBundle/DependencyInjection/MainConfiguration.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ private function addFirewallsSection(ArrayNodeDefinition $rootNode, array $facto
200200
->booleanNode('logout_on_user_change')
201201
->defaultTrue()
202202
->info('When true, it will trigger a logout for the user if something has changed. Note: No-Op option since 4.0. Will always be true.')
203-
->setDeprecated('The "%path%.%node%" configuration key has been deprecated in Symfony 4.1 and will be removed in 5.0.')
203+
->setDeprecated('The "%path%.%node%" configuration key has been deprecated in Symfony 4.1.')
204204
->end()
205205
->arrayNode('logout')
206206
->treatTrueLike(array())

src/Symfony/Bundle/SecurityBundle/Resources/config/security.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@
165165
<!-- Provisioning -->
166166
<service id="security.user.provider.in_memory" class="Symfony\Component\Security\Core\User\InMemoryUserProvider" abstract="true" />
167167
<service id="security.user.provider.in_memory.user" class="Symfony\Component\Security\Core\User\User" abstract="true">
168-
<deprecated>The "%service_id%" service is deprecated since Symfony 4.1 and will be removed in 5.0.</deprecated>
168+
<deprecated>The "%service_id%" service is deprecated since Symfony 4.1.</deprecated>
169169
</service>
170170

171171
<service id="security.user.provider.ldap" class="Symfony\Component\Security\Core\User\LdapUserProvider" abstract="true">

src/Symfony/Bundle/SecurityBundle/SecurityUserValueResolver.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,14 @@
1919
use Symfony\Component\Security\Core\User\UserInterface;
2020
use Symfony\Component\Security\Http\Controller\UserValueResolver;
2121

22-
@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);
2323

2424
/**
2525
* Supports the argument type of {@see UserInterface}.
2626
*
2727
* @author Iltar van der Berg <[email protected]>
2828
*
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
3030
*/
3131
final class SecurityUserValueResolver implements ArgumentValueResolverInterface
3232
{

src/Symfony/Component/Config/Definition/Builder/NodeDefinition.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ public function setPathSeparator(string $separator)
364364
$child->setPathSeparator($separator);
365365
}
366366
} 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);
368368
}
369369
}
370370

src/Symfony/Component/EventDispatcher/CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ CHANGELOG
66

77
* added support for invokable event listeners tagged with `kernel.event_listener` by default
88
* The `TraceableEventDispatcher::getOrphanedEvents()` method has been added.
9-
* The `TraceableEventDispatcherInterface` has been deprecated and will be removed in 5.0.
9+
* The `TraceableEventDispatcherInterface` has been deprecated.
1010

1111
4.0.0
1212
-----

0 commit comments

Comments
 (0)