Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

解决报错:WARNING A possible infinite logging loop was detected and abort… #125

Merged
merged 1 commit into from
Feb 23, 2023

Conversation

quhaowk
Copy link
Contributor

@quhaowk quhaowk commented Feb 20, 2023

…ed. It appears some of your handler code is triggering logging, see the previous log record for a hint as to what may be the cause.

…d. It appears some of your handler code is triggering logging, see the previous log record for a hint as to what may be the cause.
@onanying
Copy link
Member

onanying commented Feb 22, 2023

出处:https://php.libhunt.com/monolog-latest-version Seldaek/monolog#1681

Previous changes from v3.1.0
Added $datetime parameter to Logger::addRecord as low level API to allow logging into the past or future (#1682)
Added Logger::useLoggingLoopDetection to allow disabling cyclic logging detection in concurrent frameworks (#1681)
Fixed handling of fatal errors if callPrevious is disabled in ErrorHandler (#1670)
Fixed interop issue by removing the need for a return type in ProcessorInterface (#1680)
Marked the reusable Monolog\Test\TestCase class as @internal to make sure PHPStorm does not show it above PHPUnit, you may still use it to test your own handlers/etc though (#1677)
Fixed RotatingFileHandler issue when the date format contained slashes (#1671)

@onanying
Copy link
Member

@quhaowk 感觉加到对应的 bin 目录下 swoole.php swooleco.php swoolecopool.php swow.php 更加合适,可以改一下么?

就加一行,加到 Error::register(); 下面

Logger::instance()->useLoggingLoopDetection(false);

@onanying onanying merged commit b9a0030 into mix-php:master Feb 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants