View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0000517||Xdebug||Profiling||public||2010-01-08 11:41||2020-03-12 17:14|
|Summary||0000517: Add a function trace trigger like for the profiler|
|Description||xdebug.trace_enable_trigger in config.|
?XDEBUG_TRACE=1 to activate.
|Tags||No tags attached.|
||Patch available at: http://pallaert.pastebin.com/f4ab1dee0|
||New patch at: http://pallaert.pastebin.com/f958e72|
This is exactly what I need for debugging issues on live servers.
I've adapted this for use with xdebug 2.0.5, which is working well. Line numbers in the patch are different, and there's no distributed php.ini file, but otherwise the patch here works without substantive modification.
This remains awkward on some of the servers I deal with though due to policy that everything needs to be installed from repositories.
What's the chance of this being added to the next version of xdebug?
||This is an excellent idea... Can't wait for this to reach stable on Debian! Thanks guys!|
I've just managed to backport the patch to Debian stable and it works perfectly. The problem was that I could not find the source version to which the patch applies so I patched it manually (just a few lines needed change so I'm pretty confident I didn't introduce any bugs) and compiled it against the current stable. So beware that this is a heuristic (hope for the best) patch.
Deb package: http://www.evorion.hr/fileadmin/Debian_contrib/php5-xdebug_2.1.0-1_i386.deb
Patched source: http://www.evorion.hr/fileadmin/Debian_contrib/xdebug-2.1.0-patched.tgz
/etc/php5/conf.d/xdebug.ini example: http://www.evorion.hr/fileadmin/Debian_contrib/xdebug.ini
xdebug.sh - a tiny BASH script to toggle debuger for production servers: http://www.evorion.hr/fileadmin/Debian_contrib/xdebug.sh
I also have a line in crontab to turn the debugger off every evening in case I forgot but this is a double edged sword since it can break a site if you accidentally leave an xdebug_break() in the source:
# Turn off xdebug if it is active
25 4 * * * root /root/bin/xdebug.sh off > /dev/null
The advantage of installing the Debian package is that the package manager will warn you that the dependencies of the manually built Xdebug will be broken when you try to upgrade any of the packages on which it depends. This way your system will stay in dependence perfect state if you maintain it through apt, even though we patched it manually. Once any of the depending packages gets a new version in stable we will have to recompile Xdebug.
||I've just noticed that this backport enables the xdebug.remote_connect_back (available since 2.1) which is VERY handy if you're debugging from more than one machine.|
The company I work for uses a patched version of XDebug with this feature added. Without this feature we could not consider using XDebug to identify issues on live servers.
Can I therefore ask for the 'severity' of this feature to be reviewed?
||This is now implemented in SVN for 2.2.0-dev. Thanks for the patch Patrick!|
|2010-01-08 11:41||patrickallaert||New Issue|
|2010-01-08 11:41||patrickallaert||PHP Version||=> 5.3.2|
|2010-01-08 11:41||patrickallaert||Xdebug Version||=> 2.1.0-dev|
|2010-01-09 11:22||patrickallaert||Note Added: 0001264|
|2010-01-28 22:50||patrickallaert||Note Added: 0001289|
|2010-03-24 06:31||ngaur||Note Added: 0001410|
|2010-04-26 03:34||ngaur||Note Added: 0001465|
|2010-10-20 02:19||vlatko.surlan||Note Added: 0001585|
|2010-10-27 01:37||vlatko.surlan||Note Added: 0001591|
|2010-10-28 06:41||vlatko.surlan||Note Added: 0001592|
|2011-03-30 02:52||ngaur||Note Added: 0001698|
|2011-03-30 20:37||derick||Note Added: 0001699|
|2011-03-30 20:37||derick||Status||new => closed|
|2011-03-30 20:37||derick||Assigned To||=> derick|
|2011-03-30 20:37||derick||Resolution||open => fixed|
|2011-03-30 21:47||derick||Relationship added||has duplicate 0000671|
|2016-12-04 19:13||derick||Relationship added||has duplicate 0000675|
|2020-03-12 16:55||derick||Severity||minor => feature|
|2020-03-12 17:14||derick||Category||Feature/Change request => Profiling|