mirror of
https://github.com/Seldaek/monolog.git
synced 2026-04-25 23:55:56 +03:00
[GH-ISSUE #1511] Fatal error: Uncaught TypeError: substr() #642
Labels
No labels
Bug
Documentation
Feature
Needs Work
Support
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/monolog#642
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @HendrikCromboom on GitHub (Nov 5, 2020).
Original GitHub issue: https://github.com/Seldaek/monolog/issues/1511
Monolog version 2.1.1
Repeatable on multiple devices with fresh version:
When using BrowserConsoleHandler:
Fatal error: Uncaught TypeError: substr() expects parameter 3 to be int, null given in /var/www/html/monolog-php/vendor/monolog/monolog/src/Monolog/Utils.php:34 Stack trace: #0 /var/www/html/monolog-php/vendor/monolog/monolog/src/Monolog/Utils.php(34): substr() #1 /var/www/html/monolog-php/vendor/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php(179): Monolog\Utils::substr() #2 /var/www/html/monolog-php/vendor/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php(153): Monolog\Handler\BrowserConsoleHandler::handleStyles() #3 /var/www/html/monolog-php/vendor/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php(70): Monolog\Handler\BrowserConsoleHandler::generateScript() #4 [internal function]: Monolog\Handler\BrowserConsoleHandler::send() #5 {main} thrown in /var/www/html/monolog-php/vendor/monolog/monolog/src/Monolog/Utils.php on line 34
@HendrikCromboom commented on GitHub (Nov 5, 2020):
Substr can be hardcoded towards a non-null value to solve this part of the issue.
@HendrikCromboom commented on GitHub (Nov 5, 2020):
Rolling back to previous stable candidate solves the issue.
@grubolsch commented on GitHub (Nov 5, 2020):
I provided a bugfix for this that was merged a while again.
https://github.com/Seldaek/monolog/pull/1490
Was this revert for some reason, can I help out with this?
@Seldaek commented on GitHub (Dec 10, 2020):
Nope the issue is that I did not release a bugfix release since it was merged. Will try and get that done soon. You can require
^2.1@devin the meantime.