File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -86,6 +86,10 @@ C/C++ standard.::
86
86
The ``ConsoleEvents::EXCEPTION `` Event
87
87
--------------------------------------
88
88
89
+ .. versionadded :: 3.3
90
+ The ``ConsoleEvents::EXCEPTION `` event was deprecated in Symfony 3.3. Use
91
+ the ``ConsoleEvents::ERROR `` event instead.
92
+
89
93
**Typical Purposes **: Handle exceptions thrown during the execution of a
90
94
command.
91
95
@@ -113,6 +117,19 @@ Listeners receive a
113
117
$event->setException(new \LogicException('Caught exception', $exitCode, $event->getException()));
114
118
});
115
119
120
+ The ``ConsoleEvents::ERROR `` Event
121
+ ----------------------------------
122
+
123
+ .. versionadded :: 3.3
124
+ The ``ConsoleEvents::ERROR `` event was introduced in Symfony 3.3.
125
+
126
+ **Typical Purposes **: Handle exceptions thrown during the execution of a
127
+ command.
128
+
129
+ This event is an improved version of the ``ConsoleEvents::EXCEPTION `` event,
130
+ because it can handle every exception thrown during the execution of a command,
131
+ including those triggered from event listeners.
132
+
116
133
The ``ConsoleEvents::TERMINATE `` Event
117
134
--------------------------------------
118
135
You can’t perform that action at this time.
0 commit comments