View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0001259 | Xdebug | Tracing | public | 2016-01-21 09:37 | 2020-03-12 16:49 |
Reporter | mindplay | Assigned To | derick | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | resolved | Resolution | won't fix | ||
Platform | Any PHP version | OS | Any OS | ||
Summary | 0001259: Stack trace print-outs in reverse order | ||||
Description | The stack-trace print-outs are in backwards order compared with PHP itself, and compared with stack-traces in other languages, including Java and C#, as well as stack-trace print-outs in a JavaScript developer console. It's very distracting and confusing to have to figure out the order of every stack trace you see during a day, and I'd like to request this be changed and made consistent with PHP itself. | ||||
Steps To Reproduce | An example stack trace from PHP 7 without xdebug: <code> Fatal error: Uncaught RuntimeException in Command line code:1 And an example stack trace with xdebug: <code> Fatal error: Uncaught RuntimeException in Command line code on line 1 RuntimeException: in Command line code on line 1 Call Stack: In the latter case, we actually have two stack traces on screen at the same time, in opposing order - pretty confusing. | ||||
Tags | No tags attached. | ||||
Operating System | |||||
PHP Version | 7.0.0-7.0.4 | ||||
|
My example was mangled by Mantis, and it seems I can't edit this issue, so here's a readable gist with the examples: |
|
Note that I have reported this issue against php-unit as well - likely taking inspiration from xdebug, php-unit also displays stack-traces in backwards order. |
|
Thanks for your request. I am not going to change this. It would render most tests invalid, all online docs and tutorials. Please just consider this a quirk of Xdebug (and PHP Unit). |
|
@derick why can we just have a config var that would allow to reverse this, with a default setting equal to current, legacy behaviour? That way all the tests would be still valid, all the online docs and tutorials too. Nb saying "please just consider this a quirk" about a behaviour that clearly violates POLA and differs from both platform (PHP's) and industry standards without providing any clear benefit to end-user is, to say the least, bizzare IMO. |
|
@vaxquis: PHP added stack traces after Xdebug had them for years, so PHP is inconsistent with Xdebug, if you must compare them. It also wouldn't mean that "the tests would be still valid", as for each feature/setting, there need to be tests. I'm not going to change this, nor add a configuration setting. |
Date Modified | Username | Field | Change |
---|---|---|---|
2016-01-21 09:37 | mindplay | New Issue | |
2016-01-21 09:43 | mindplay | Note Added: 0003430 | |
2016-01-21 10:10 | mindplay | Note Added: 0003431 | |
2016-02-08 21:12 | derick | Note Added: 0003459 | |
2016-02-08 21:12 | derick | Status | new => resolved |
2016-02-08 21:12 | derick | Resolution | open => won't fix |
2016-02-08 21:12 | derick | Assigned To | => derick |
2018-11-29 14:24 | vaxquis | Note Added: 0004728 | |
2018-11-29 14:41 | derick | Note Added: 0004729 | |
2020-03-12 16:49 | derick | Category | Feature/Change request => Tracing |