Bug #66860 [Com]: Stack traces are unreadable
Edit report at https://bugs.php.net/bug.php?id=66860&edit=1
ID: 66860
Comment by: phpmpan at mpan dot pl
Reported by: eldmannen+php at gmail dot com
Summary: Stack traces are unreadable
Status: Open
Type: Bug
Package: *General Issues
PHP Version: Irrelevant
Block user comment: N
Private report: N
New Comment:
The stack trace is properly formatted and broken into lines. You don't see it probably because
you view it in a browser which treats this plain-text data as HTML and strips newlines.
Previous Comments:
------------------------------------------------------------------------
[2014-03-09 13:00:13] eldmannen+php at gmail dot com
Description:
------------
The stack traces are unreadable.
They already contain some markup such as <b> but are still pretty much unreadable due to all
text on one line.
Wrap the stack trace in <pre> tags, or use <br> at the end of the lines.
Test script:
---------------
<?php
function a() {
b();
}
function b() {
c();
}
function c() {
throw new Exception;
}
a();
Expected result:
----------------
Fatal error: Uncaught exception 'Exception' in /var/www/test.php:12
Stack trace:
#0 /var/www/test.php(8): c()
#1 /var/www/test.php(4): b()
#2 /var/www/test.php(15): a()
#3 {main}
thrown in /var/www/test.php on line 12
Actual result:
--------------
Fatal error: Uncaught exception 'Exception' in /var/www/test.php:12 Stack trace: #0
/var/www/test.php(8): c() #1 /var/www/test.php(4): b() #2 /var/www/test.php(15): a() #3 {main}
thrown in /var/www/test.php on line 12
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=66860&edit=1
Thread (7 messages)