Creating breakpoints when remote debugging using fastcgi does not break
- Start a hhvm instance using -m server -v Server.Type=fastcgi -v Server.Port=9000 -v Eval.Debugger.EnableDebugger=true -v Eval.Debugger.EnableDebuggerServer=true -v Eval.Debugger.Port=8089
- Connect using hphpd on localhost:8089
- break on any file running in the hhvm
- continue
- skips breakpoints completely.
I'm currently trying to run Drupal 7 in this manner; its unit tests are not working. Specifically, when I use break with an absolute path in step 3, loading the file does using the server does not cause a breakpoint to trigger. I tested using includes/bootstrap.inc.
(CC @mikemag)
Thanks for reporting this. Feel free to submit a PR if you (or someone else reading this) gets to this before we do.
This works for me.
me too! yay.
I can still repro. Now with new hhvm updates, what is the correct way to link hphpd to hhvm? Should we still start a new hhvm instance like above?
$sudo vim /usr/share/hhvm/install_fastcgi.sh Running above command doesn't actually start the debugger and here is my /etc/hhvm/server.ini hhvm.Eval.Debugger.EnableDebugger = true hhvm.Eval.Debugger.EnableDebuggerServer = true hhvm.Eval.Debugger.Port = 8089 hhvm.Eval.Debugger.DefaultSandboxPath = "/home/prognew/www"
I found the hphpd default the sandbox to {home}/www
$ hphpd -h localhost Welcome to HipHop Debugger! Type "help" or "?" for a complete list of commands.
Connecting to localhost:8089... Attaching to prognew's default sandbox and pre-loading, please wait... localhost> m l m l 1 prognew's default sandbox at /home/prognew/www/
I can also reproduce this, exactly as stated in first:
A) Start server: hhvm --no-config -m server -v Server.Type=fastcgi -v Server.Port=9000 -v Eval.Debugger.EnableDebugger=true -v Eval.Debugger.EnableDebuggerServer=true -v Eval.Debugger.Port=8089
B) Start debugger: hhvm -m debug --debug-host localhost --debug-port 8089 C) Enter debugger command: break start D) Enter debugger command: continue E) Issue http request curl http://localhost/wiki/Main_Page
I would expect the http request issued in E to pause and for the debugger to pick up, but instead it runs to completion.
Looking through the related code, my best guess is that in source-root-info.cpp the constructor SourceRootInfo::SourceRootInfo(Transport* transport) is seeing that my web server set a DocumentRoot parameter, and as such skips the entire sandbox configuration? Debugger depends on sandboxing, so without it the debugger is essentially disabled?
I have the same issue as this report. Im following the blog from http://miles-by-motorcycle.com/fv-b-8-657/configuring-and-using-the-hiphopvm--hhvm--remote-debugger.
The breakpoint is set, hit continue but when running the request, it just doesnt halt on my breakpoint
I am going over old issues on this repository, to see which ones apply to the current versions of hhvm.
This issue applies to the old debugger. This debugger is slated for removal.
We also plan to complete the deprecation of the old HPHPD debugger in favor of our LSP bindings from the vsdebug extension.