View Issue Details

IDProjectCategoryView StatusLast Update
0002195XdebugStacktracespublic2023-11-30 14:49
Reporterderick Assigned Toderick  
PrioritynormalSeverityfeatureReproducibilityhave not tried
Status closedResolutionfixed 
Target Version3.3devFixed in Version3.3.0 
Summary0002195: Add 'from_exception' option to 'xdebug_get_function_stack' to return the stack trace where an exception was thrown
Description

The xdebug_get_function_stack() method returns the stack trace where it was called. Inside an exception handler, set with set_exception_handler() this then returns the stack trace from within that handler, but not the stack trace from where the exception was called, which is much more interesting.

Add a new option to xdebug_get_function_stack() called from_exception that takes a Throwable as argument, and if a stack trace is available when this throwable was created, return it, instead of the stack trace from where it was called. This stack trace will always have local_vars and params_as_values set, so that these argument and local variable values can be accessed.

TagsNo tags attached.
Operating System
PHP Version8.2.0-8.2.9

Activities

Issue History

Date Modified Username Field Change
2023-08-16 13:39 derick New Issue
2023-08-23 08:29 derick Severity minor => feature
2023-08-23 11:37 derick Assigned To => derick
2023-08-23 11:37 derick Status new => closed
2023-08-23 11:37 derick Resolution open => fixed
2023-08-23 11:37 derick Fixed in Version => 3.3dev
2023-08-23 11:37 derick Note Added: 0006637
2023-09-05 17:46 derick Fixed in Version 3.3dev => 3.3.0alpha1
2023-11-30 14:49 derick Fixed in Version 3.3.0alpha1 => 3.3.0