History log of /dokuwiki/inc/ErrorHandler.php (Results 1 – 14 of 14)
Revision Date Author Comments
# 90fb952c 31-Aug-2023 Andreas Gohr <andi@splitbrain.org>

code style: operator spacing


# 177d6836 31-Aug-2023 Andreas Gohr <andi@splitbrain.org>

coding style: control flow whitespaces


# 74981a4e 30-Aug-2023 Andreas Gohr <andi@splitbrain.org>

apply PSR-12 constant visibility rule

PSR-12 says constants need their visibility declared from PHP 7.1
onwards


# 24870174 29-Aug-2023 Andreas Gohr <andi@splitbrain.org>

Apply rector fixes to the rest of inc


# 32f53e97 27-Oct-2022 Andreas Gohr <andi@splitbrain.org>

log additional errors

Our error handler was only logging warnings, but logging other errors,
especially those that may have been triggered by 3rd party libs, is
helpful, too. This adds a few more lo

log additional errors

Our error handler was only logging warnings, but logging other errors,
especially those that may have been triggered by 3rd party libs, is
helpful, too. This adds a few more loggable errors.

This should especially help with composer trigerring a E_USER_ERROR when
the PHP version mismatches.

show more ...


# be6462f4 13-Aug-2022 Andreas Gohr <andi@splitbrain.org>

log warnings to error log

This introduces an error handler that will log warnings, including a
stack trace in the error log. This should help plugin and core authors with
identifying cases of uninit

log warnings to error log

This introduces an error handler that will log warnings, including a
stack trace in the error log. This should help plugin and core authors with
identifying cases of uninitilized variables in PHP8+ environments.

A feature flag (default off) will let users temporarily disable the
display of warnings in the frontend. This should allow the usage of not
yet upgraded plugins in many cases. In the future the flag can be
removed again.

show more ...


# 0ecde6ce 13-Aug-2020 Andreas Gohr <andi@splitbrain.org>

central logging mechanism

This introduces a logger mechanism and a new data/log directory. This is
a first proof of concept. It's built on top of the new global error
handling mechanism

Things to d

central logging mechanism

This introduces a logger mechanism and a new data/log directory. This is
a first proof of concept. It's built on top of the new global error
handling mechanism

Things to discuss:

* should we adopt PSR-3 somehow? if yes, how and should plugins be able
to drop-in other psr3 loggers?
* how to configure which facilities shall be logged?
* should we implement a log deletion feature?
* is the log format sensible?
* should we implement a log viewer admin plugin?
* should logging trigger events (it should maybe replace the
deprecation event)

show more ...


# 51c1fbb3 14-Jul-2020 Andreas Gohr <andi@splitbrain.org>

no need to convert Errors to Exceptions

we handle Throwables anyway


# dbe0790d 14-Jul-2020 Andreas Gohr <andi@splitbrain.org>

FatalException and proper plugin detection

Using our own Exception makes it easier to differentiate fatal errors
from others in the log


# cb4cefeb 13-Jul-2020 Andreas Gohr <andi@splitbrain.org>

add shutdown handler to even manage fatal errors

We can't catch some errors and they are not passed to the error_handler
either. But we can at least react to them in a shutdown function to show
a fr

add shutdown handler to even manage fatal errors

We can't catch some errors and they are not passed to the error_handler
either. But we can at least react to them in a shutdown function to show
a friendly message to the user and write our log.

show more ...


# ffa84f81 13-Jul-2020 Andreas Gohr <andi@splitbrain.org>

better exception handling on plugin loading

Now all important places where plugins are loaded are guarded by a
try/except. We're catching Throwables here to be able to catch stuff
like syntax errors

better exception handling on plugin loading

Now all important places where plugins are loaded are guarded by a
try/except. We're catching Throwables here to be able to catch stuff
like syntax errors early on (otherwise they will only be caught by our
ErrorConverter much too late). This means that this change requires PHP
7.0 minimum!

show more ...


# 0e69c9af 13-Jul-2020 Andreas Gohr <andi@splitbrain.org>

log stacktrace to error log

Ultimately the one responsible for fixing the problem will need this
anyway. Better log it right away for (hopefully) better bug reports


# 7e0b27f2 13-Jul-2020 Andreas Gohr <andi@splitbrain.org>

guess which plugin was the source of an exception

This looks at filenames and classes involved in the stacktrace to see if
a plugin is referenced.

We're only guessing plugins here, because looking

guess which plugin was the source of an exception

This looks at filenames and classes involved in the stacktrace to see if
a plugin is referenced.

We're only guessing plugins here, because looking for templates may
cause false positives where templates load plugins.

show more ...


# 642e976c 13-Jul-2020 Andreas Gohr <andi@splitbrain.org>

introduce a global error handler

This transfers old style PHP errors into Exceptions and installs a
global exception handler. All exceptions caught by this handler are
logged to an error log and a m

introduce a global error handler

This transfers old style PHP errors into Exceptions and installs a
global exception handler. All exceptions caught by this handler are
logged to an error log and a meassage is shown to the end user. This
should finally get rid of "blank page" bug reports.

show more ...