Skip to content

Commit 707a947

Browse files
ycerutonicolas-grekas
authored andcommitted
[Debug] Restoring back the state of the Debug component (1st step)
1 parent 30bd032 commit 707a947

File tree

5 files changed

+8
-7
lines changed

5 files changed

+8
-7
lines changed

DataCollector/LoggerDataCollector.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
namespace Symfony\Component\HttpKernel\DataCollector;
1313

14-
use Symfony\Component\ErrorCatcher\Exception\SilencedErrorContext;
14+
use Symfony\Component\Debug\Exception\SilencedErrorContext;
1515
use Symfony\Component\HttpFoundation\Request;
1616
use Symfony\Component\HttpFoundation\RequestStack;
1717
use Symfony\Component\HttpFoundation\Response;

EventListener/DebugHandlersListener.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@
1515
use Symfony\Component\Console\ConsoleEvents;
1616
use Symfony\Component\Console\Event\ConsoleEvent;
1717
use Symfony\Component\Console\Output\ConsoleOutputInterface;
18-
use Symfony\Component\ErrorCatcher\ErrorHandler;
18+
use Symfony\Component\Debug\ErrorHandler;
19+
use Symfony\Component\Debug\ExceptionHandler;
1920
use Symfony\Component\ErrorCatcher\ErrorRenderer\ErrorFormatter;
2021
use Symfony\Component\ErrorCatcher\ErrorRenderer\HtmlErrorRenderer;
2122
use Symfony\Component\ErrorCatcher\Exception\ErrorRendererNotFoundException;
22-
use Symfony\Component\ErrorCatcher\ExceptionHandler;
2323
use Symfony\Component\EventDispatcher\Event;
2424
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
2525
use Symfony\Component\HttpFoundation\Request;

Tests/DataCollector/LoggerDataCollectorTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
namespace Symfony\Component\HttpKernel\Tests\DataCollector;
1313

1414
use PHPUnit\Framework\TestCase;
15-
use Symfony\Component\ErrorCatcher\Exception\SilencedErrorContext;
15+
use Symfony\Component\Debug\Exception\SilencedErrorContext;
1616
use Symfony\Component\HttpFoundation\Request;
1717
use Symfony\Component\HttpFoundation\RequestStack;
1818
use Symfony\Component\HttpFoundation\Response;
@@ -106,7 +106,7 @@ public function testCollect($nb, $logs, $expectedLogs, $expectedDeprecationCount
106106
$logs = array_map(function ($v) {
107107
if (isset($v['context']['exception'])) {
108108
$e = &$v['context']['exception'];
109-
$e = isset($e["\0*\0message"]) ? [$e["\0*\0message"], $e["\0*\0severity"]] : [$e["\0Symfony\Component\ErrorCatcher\Exception\SilencedErrorContext\0severity"]];
109+
$e = isset($e["\0*\0message"]) ? [$e["\0*\0message"], $e["\0*\0severity"]] : [$e["\0Symfony\Component\Debug\Exception\SilencedErrorContext\0severity"]];
110110
}
111111

112112
return $v;

Tests/EventListener/DebugHandlersListenerTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
use Symfony\Component\Console\Helper\HelperSet;
2020
use Symfony\Component\Console\Input\ArgvInput;
2121
use Symfony\Component\Console\Output\ConsoleOutput;
22-
use Symfony\Component\ErrorCatcher\ErrorHandler;
23-
use Symfony\Component\ErrorCatcher\ExceptionHandler;
22+
use Symfony\Component\Debug\ErrorHandler;
23+
use Symfony\Component\Debug\ExceptionHandler;
2424
use Symfony\Component\EventDispatcher\EventDispatcher;
2525
use Symfony\Component\HttpFoundation\Request;
2626
use Symfony\Component\HttpKernel\Event\KernelEvent;

composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
],
1818
"require": {
1919
"php": "^7.1.3",
20+
"symfony/debug": "^4.4|^5.0",
2021
"symfony/error-catcher": "^4.4|^5.0",
2122
"symfony/event-dispatcher": "^4.3",
2223
"symfony/http-foundation": "^4.4|^5.0",

0 commit comments

Comments
 (0)