deadlock when using print_r( debug_backtrace( false, 2), true )

in reference to this:

https://stackoverflow.com/a/2146171/533426

Read More

the line:

  $trace = print_r( debug_backtrace( false, 2), true );

actually deadlocks my php script. That is, the whole application becomes unresponsive, the browser keeps spinning, the debug just jumps into nothing, like, goodbye debug. I can still open the phpmyadmin that runs on the same server, but not the application any longer. The application is actually a slim application that runs in a wordpress installation. Both is unresponsive, no response.

is that eventually because the the variables are too complex to be output?

i have some very complex objects, mainly because i use a plugin that has very complex objects see pods.io and those pods objects are known to crash things when tried to get output having said that, i think it is quite likely too that slim is causing the crash, because their objects and function call chains are not super short neither.

is there a way to avoid the deadlock?

Related posts

Leave a Reply