[ErrorHandler] Rework fatal errors#33053
Merged
Tobion merged 1 commit intosymfony:4.4from Oct 11, 2019
Merged
Conversation
0a610ae to
fa9c9cb
Compare
fancyweb
commented
Aug 8, 2019
src/Symfony/Component/ErrorHandler/Error/ClassNotFoundFatalError.php
Outdated
Show resolved
Hide resolved
5 tasks
Tobion
reviewed
Aug 8, 2019
fa9c9cb to
5eb1bc5
Compare
Member
|
(rebase needed) |
Contributor
Author
|
Impossible to resolve conflicts, because of 1st commit. |
5eb1bc5 to
b44845f
Compare
d8cc931 to
b3c53c4
Compare
Member
|
@fancyweb Thanks a lot for this PR, great job so far! There are still some pending failures, let me know when this is ready for you and I will take a deeper look. |
468e40a to
62f60ef
Compare
stof
reviewed
Sep 10, 2019
| } | ||
| } | ||
|
|
||
| if ($function[0] instanceof ComposerClassLoader || $function[0] instanceof SymfonyClassLoader) { |
Member
There was a problem hiding this comment.
SymfonyClassLoader is a dead component in 4.x. Do we still need to account for it in the new ErrorHandler component ?
Contributor
Author
There was a problem hiding this comment.
Talked about this with @nicolas-grekas a while ago, and he told me we can eventually stop supporting it on 5.0. But I didn't do it yet.
764e6ac to
d5c3f7e
Compare
Member
9d4bf35 to
56295e0
Compare
fancyweb
commented
Sep 27, 2019
src/Symfony/Component/ErrorHandler/Tests/phpt/decorate_exception_handler_lt_74.phpt
Show resolved
Hide resolved
Contributor
Author
|
@fabpot Rebase is done and CI is green. |
src/Symfony/Component/ErrorHandler/ErrorEnhancer/ErrorEnhancerInterface.php
Outdated
Show resolved
Hide resolved
Tobion
reviewed
Sep 27, 2019
src/Symfony/Component/ErrorHandler/Error/ClassNotFoundError.php
Outdated
Show resolved
Hide resolved
Tobion
reviewed
Sep 27, 2019
src/Symfony/Component/ErrorHandler/Error/FatalErrorInterface.php
Outdated
Show resolved
Hide resolved
Tobion
reviewed
Sep 27, 2019
src/Symfony/Component/ErrorHandler/FatalErrorHandler/FatalErrorHandlerInterface.php
Outdated
Show resolved
Hide resolved
Tobion
reviewed
Sep 27, 2019
src/Symfony/Component/ErrorHandler/FatalErrorHandler/FatalErrorHandlerInterface.php
Outdated
Show resolved
Hide resolved
Tobion
reviewed
Sep 27, 2019
src/Symfony/Component/ErrorHandler/ErrorEnhancer/ErrorEnhancerInterface.php
Outdated
Show resolved
Hide resolved
0dd5e9f to
a4c93a6
Compare
Contributor
Author
|
Just repushed to take comments into account:
|
a4c93a6 to
aaa0cdf
Compare
Tobion
approved these changes
Oct 11, 2019
Contributor
|
Thanks @fancyweb for working on this feature, this is much appreciated. |
Tobion
added a commit
that referenced
this pull request
Oct 11, 2019
This PR was merged into the 4.4 branch. Discussion ---------- [ErrorHandler] Rework fatal errors | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | #32605 | License | MIT | Doc PR | - Built on top of #33038 so review only the second commit : d5c3f7e The goals of this PR is to replace current "fatal error handlers" with "error enhancers" since all our current fatal error handlers works on \Error since PHP7. That means we won't use the FatalErrorException anymore, so we will be able to remove it (once we don't need it in the rest of the codebase). The final goal btw is to handle \Throwable everywhere in the code so we can remove FatalThrowableError & FatalErrorException classes. Commits ------- aaa0cdf [ErrorHandler] Rework fatal error handlers
yceruto
reviewed
Oct 23, 2019
| use Symfony\Component\ErrorHandler\FatalErrorHandler\UndefinedFunctionFatalErrorHandler; | ||
| use Symfony\Component\ErrorHandler\FatalErrorHandler\UndefinedMethodFatalErrorHandler; | ||
| use Symfony\Component\ErrorRenderer\ErrorRenderer\HtmlErrorRenderer; | ||
| use Symfony\Component\ErrorRenderer\Exception\FlattenException; |
chalasr
added a commit
that referenced
this pull request
Oct 23, 2019
This PR was merged into the 4.4 branch. Discussion ---------- [ErrorHandler] Import missing classes | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | - | License | MIT | Doc PR | - Fix #33053 (comment) Commits ------- e07a3d7 Import missing classes
nicolas-grekas
added a commit
that referenced
this pull request
Nov 8, 2019
…error enhancer (fancyweb) This PR was merged into the 5.0-dev branch. Discussion ---------- [ErrorHandler] Remove Symfony ClassLoader support in an error enhancer | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | no | Deprecations? | no | Tickets | #33053 (comment) | License | MIT | Doc PR | - Throwing a deprecation for this on 4.4 looks useless to me as the component was deprecated 2 years ago and stopping its support will not break anything. Commits ------- e745654 [ErrorHandler] Remove Symfony ClassLoader support in an error enhancer
This was referenced Nov 12, 2019
Merged
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Built on top of #33038 so review only the second commit : d5c3f7e
The goals of this PR is to replace current "fatal error handlers" with "error enhancers" since all our current fatal error handlers works on \Error since PHP7.
That means we won't use the FatalErrorException anymore, so we will be able to remove it (once we don't need it in the rest of the codebase).
The final goal btw is to handle \Throwable everywhere in the code so we can remove FatalThrowableError & FatalErrorException classes.