8000 Merge branch '4.2' · symfony/symfony@0d35f97 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0d35f97

Browse files
Merge branch '4.2'
* 4.2: Update PR template Fixes sprintf(): Too few arguments in Translator [Cache] fix deps updated CHANGELOG for 4.2.0-RC1 bumped Symfony version to 4.1.9 updated VERSION for 4.1.8 updated CHANGELOG for 4.1.8 bumped Symfony version to 3.4.20 updated VERSION for 3.4.19 updated CHANGELOG for 3.4.19 [Console] Move back root exception to stack trace in verbose mode
2 parents 534b83f + 5e2e3fd commit 0d35f97

File tree

7 files changed

+110
-3
lines changed

7 files changed

+110
-3
lines changed

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
| Q | A
22
| ------------- | ---
3-
| Branch? | master for features / 2.8 up to 4.1 for bug fixes <!-- see below -->
3+
| Branch? | master for features / 3.4 up to 4.2 for bug fixes <!-- see below -->
44
| Bug fix? | yes/no
55
| New feature? | yes/no <!-- don't forget to update src/**/CHANGELOG.md files -->
66
| BC breaks? | no <!-- see https://symfony.com/bc -->

CHANGELOG-4.1.md

Lines changed: 43 additions & 0 deletions
< 6D40 /tr>
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,49 @@ in 4.1 minor versions.
77
To get the diff for a specific change, go to https://github.com/symfony/symfony/commit/XXX where XXX is the change hash
88
To get the diff between two versions, go to https://github.com/symfony/symfony/compare/v4.1.0...v4.1.1
99

10+
* 4.1.8 (2018-11-26)
11+
12+
* bug #29318 [Console] Move back root exception to stack trace in verbose mode (chalasr)
13+
* bug #29332 [PropertyAccess] make cache keys encoding bijective (nicolas-grekas)
14+
* bug #29298 [Routing] fix trailing slash redirection when using RedirectableUrlMatcher (nicolas-grekas)
15+
* bug #29297 [Routing] fix trailing slash redirection when using RedirectableUrlMatcher (nicolas-grekas)
16+
* bug #29313 [PropertyAccessor] fix encoding of cache keys (nicolas-grekas)
17+
* bug #28917 [DoctrineBridge] catch errors while converting to db values in data collector (alekitto)
18+
* bug #29317 [WebProfiler] Detect non-file paths in file viewer (ro0NL)
19+
* bug #29305 [EventDispatcher] Unwrap wrapped listeners internally (ro0NL)
20+
* bug #27314 [DoctrineBridge] fix case sensitivity issue in RememberMe\DoctrineTokenProvider (PF4Public)
21+
* bug #29310 [MonologBridge] Return empty list for unknown requests (ro0NL)
22+
* bug #29308 [Translation] Use XLIFF source rather than resname when there's no target (thewilkybarkid)
23+
* bug #26244 [BrowserKit] fixed BC Break for HTTP_HOST header (brizzz)
24+
* bug #28147 [DomCrawler] exclude fields inside "template" tags (Gorjunov)
25+
* bug #29222 [Dotenv] properly parse backslashes in unquoted env vars (xabbuh)
26+
* bug #29256 [HttpFoundation] Fixed absolute Request URI with default port (thomasbisignani)
27+
* bug #29274 [Routing] Remove duplicate schemes and methods for invokable controllers (claudusd)
28+
* bug #29271 [HttpFoundation] Fix trailing space for mime-type with parameters (Sascha Dens)
29+
* bug #29243 [Cache] fix optimizing Psr6Cache for AdapterInterface pools (nicolas-grekas)
30+
* bug #29247 [DI] fix taking lazy services into account when dumping the container (nicolas-grekas)
31+
* bug #29249 [Form] Fixed empty data for compound date interval (HeahDude)
32+
* bug #29265 [Bridge/PhpUnit] Use composer to download phpunit (nicolas-grekas)
33+
* bug #28769 [FrameworkBundle] deal with explicitly enabled workflow nodes (xabbuh)
34+
* bug #29223 [Validator] Added the missing constraints instance checks (thomasbisignani)
35+
* bug #28966 [PropertyAccessor] Fix unable to write to singular property using setter while plural adder/remover exist (karser)
36+
* bug #29182 [Form] Fixed empty data for compound date types (HeahDude)
37+
* bug #29191 [Routing] generate(null) should throw an exception (nicolas-grekas)
38+
* bug #29185 [Form] Fixed keeping hash of equal \DateTimeInterface on submit (HeahDude)
39+
* bug #29141 [Workflow] Fixed bug of buildTransitionBlockerList when many transition are enabled (Tetragramat, lyrixx)
40+
* bug #29137 [Workflow][FrameworkBundle] fixed guard event names for transitions (destillat, lyrixx)
41+
* bug #28731 [Form] invalidate forms on transformation failures (xabbuh)
42+
* bug #29152 [Config] Unset key during normalization (ro0NL)
43+
* bug #29165 [DI] align IniFileLoader to PHP bugfix #76965 (nicolas-grekas)
44+
* bug #29115 Change button_widget class to btn-primary (neFAST)
45+
* bug #29131 [Dotenv] dont use getenv() to read SYMFONY_DOTENV_VARS (nicolas-grekas)
46+
* bug #29057 [HttpFoundation] replace any preexisting Content-Type headers (nicolas-grekas)
47+
* bug #29076 [Serializer] Allow null values when denormalizing with constructor missing data (danut007ro)
48+
* bug #29104 [DI] fix dumping inlined services (nicolas-grekas)
49+
* bug #29054 [VarDumper] fix dump of closures created from callables (nicolas-grekas)
50+
* bug #29102 [DI] fix GraphvizDumper ignoring inline definitions (nicolas-grekas)
51+
* bug #29107 [DI] dont track classes/interfaces used to compute autowiring error messages (nicolas-grekas)
52+
1053
* 4.1.7 (2018-11-03)
1154

1255
* bug #28820 [DependencyInjection] Fix tags on multiple decorated service (Soner Sayakci)

CHANGELOG-4.2.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,38 @@ in 4.2 minor versions.
77
To get the diff for a specific change, go to https://github.com/symfony/symfony/commit/XXX where XXX is the change hash
88
To get the diff between two versions, go to https://github.com/symfony/symfony/compare/v4.2.0...v4.2.1
99

10+
* 4.2.0-RC1 (2018-11-26)
11+
12+
* bug #29332 [PropertyAccess] make cache keys encoding bijective (nicolas-grekas)
13+
* bug #29298 [Routing] fix trailing slash redirection when using RedirectableUrlMatcher (nicolas-grekas)
14+
* bug #29297 [Routing] fix trailing slash redirection when using RedirectableUrlMatcher (nicolas-grekas)
15+
* bug #29313 [PropertyAccessor] fix encoding of cache keys (nicolas-grekas)
16+
* bug #29328 [HttpKernel] handle anonymous classes when generating the dumped container class name (nicolas-grekas)
17+
* bug #28917 [DoctrineBridge] catch errors while converting to db values in data collector (alekitto)
18+
* bug #29317 [WebProfiler] Detect non-file paths in file viewer (ro0NL)
19+
* bug #29305 [EventDispatcher] Unwrap wrapped listeners internally (ro0NL)
20+
* bug #29302 [Contracts][Cache] allow retrieving metadata of cached items (nicolas-grekas)
21+
* bug #29315 [DI] fix copying expression providers when analyzing the service graph (nicolas-grekas)
22+
* bug #27314 [DoctrineBridge] fix case sensitivity issue in RememberMe\DoctrineTokenProvider (PF4Public)
23+
* bug #29310 [MonologBridge] Return empty list for unknown requests (ro0NL)
24+
* bug #29316 [VarDumper] Fix ClassStub ellipsis (ro0NL)
25+
* bug #29300 [Translation] fix dumping catalogues cache (nicolas-grekas)
26+
* bug #29308 [Translation] Use XLIFF source rather than resname when there's no target (thewilkybarkid)
27+
* bug #26244 [BrowserKit] fixed BC Break for HTTP_HOST header (brizzz)
28+
* bug #28147 [DomCrawler] exclude fields inside "template" tags (Gorjunov)
29+
* bug #29260 [Lock] Fixed PdoStore::putOffExpiration(), PdoStore::getHashedKey() (PavelPrischepa)
30+
* bug #29222 [Dotenv] properly parse backslashes in unquoted env vars (xabbuh)
31+
* bug #29256 [HttpFoundation] Fixed absolute Request URI with default port (thomasbisignani)
32+
* bug #29274 [Routing] Remove duplicate schemes and methods for invokable controllers (claudusd)
33+
* bug #29285 [HttpKernel][WebProfilerBundle] Getting the cached client mime type instead of guessing it again (yceruto)
34+
* bug #29271 [HttpFoundation] Fix trailing space for mime-type with parameters (Sascha Dens)
35+
* feature #29167 [Messenger] Add a trait for synchronous query & command buses (ogizanagi)
36+
* bug #29243 [Cache] fix optimizing Psr6Cache for AdapterInterface pools (nicolas-grekas)
37+
* bug #29247 [DI] fix taking lazy services into account when dumping the container (nicolas-grekas)
38+
* bug #29249 [Form] Fixed empty data for compound date interval (HeahDude)
39+
* bug #29265 [Bridge/PhpUnit] Use composer to download phpunit (nicolas-grekas)
40+
* bug #28769 [FrameworkBundle] deal with explicitly enabled workflow nodes (xabbuh)
41+
1042
* 4.2.0-BETA2 (2018-11-16)
1143

1244
* bug #29190 [Debug][HttpKernel] remove frames added by DebugClassLoader in stack traces (nicolas-grekas)

src/Symfony/Component/Cache/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
"doctrine/dbal": "~2.5",
3535
"predis/predis": "~1.1",
3636
"symfony/config": "~4.2",
37-
"symfony/dependency-injection": "~3.4",
37+
"symfony/dependency-injection": "~3.4|~4.1",
3838
"symfony/var-dumper": "^4.1.1"
3939
},
4040
"conflict": {

src/Symfony/Component/Console/Application.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -801,6 +801,13 @@ protected function doRenderException(\Exception $e, OutputInterface $output)
801801
// exception related properties
802802
$trace = $e->getTrace();
803803

804+
array_unshift($trace, array(
805+
'function' => '',
806+
'file' => $e->getFile() ?: 'n/a',
807+
'line' => $e->getLine() ?: 'n/a',
808+
'args' => array(),
809+
));
810+
804811
for ($i = 0, $count = \count($trace); $i < $count; ++$i) {
805812
$class = isset($trace[$i]['class']) ? $trace[$i]['class'] : '';
806813
$type = isset($trace[$i]['type']) ? $trace[$i]['type'] : '';

src/Symfony/Component/Console/Tests/ApplicationTest.php

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -849,6 +849,31 @@ public function testRenderAnonymousException()
849849
$this->assertContains('Dummy type "@anonymous" is invalid.', $tester->getDisplay(true));
850850
}
851851

852+
public function testRenderExceptionStackTraceContainsRootException()
853+
{
854+
$application = new Application();
855+
$application->setAutoExit(false);
856+
$application->register('foo')->setCode(function () {
857+
throw new class('') extends \InvalidArgumentException {
858+
};
859+
});
860+
$tester = new ApplicationTester($application);
861+
862+
$tester->run(array('command' => 'foo'), array('decorated' => false));
863+
$this->assertContains('[InvalidArgumentException@anonymous]', $tester->getDisplay(true));
864+
865+
$application = new Application();
866+
$application->setAutoExit(false);
867+
$application->register('foo')->setCode(function () {
868+
throw new \InvalidArgumentException(sprintf('Dummy type "%s" is invalid.', \get_class(new class() {
869+
})));
870+
});
871+
$tester = new ApplicationTester($application);
872+
873+
$tester->run(array('command' => 'foo'), array('decorated' => false));
874+
$this->assertContains('Dummy type "@anonymous" is invalid.', $tester->getDisplay(true));
875+
}
876+
852877
public function testRun()
853878
{
854879
$application = new Application();

src/Symfony/Component/Translation/Translator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ public function trans($id, array $parameters = array(), $domain = null, $locale
226226
*/
227227
public function transChoice($id, $number, array $parameters = array(), $domain = null, $locale = null)
228228
{
229-
@trigger_error(sprintf('The "%s()" method is deprecated since Symfony 4.2, use the trans() one instead with a "%count%" parameter.', __METHOD__), E_USER_DEPRECATED);
229+
@trigger_error(sprintf('The "%s()" method is deprecated since Symfony 4.2, use the trans() one instead with a "%%count%%" parameter.', __METHOD__), E_USER_DEPRECATED);
230230

231231
if (!$this->formatter instanceof ChoiceMessageFormatterInterface) {
232232
throw new LogicException(sprintf('The formatter "%s" does not support plural translations.', \get_class($this->formatter)));

0 commit comments

Comments
 (0)
0