Page 1 of 1

API/Attach To Process

PostPosted: March 16th, 2017, 7:45 pm
by silas2
I'm trying to debug a REST API (Magento), say I'm running an instance of that localhost:1234/, then from another instance of VS, I'm firing my REST calls, with a native .Net app, you can Attach to Process and step into the API instance, can I do that with remote debugging?

Re: API/Attach To Process

PostPosted: March 20th, 2017, 12:28 pm
by Miloslav Beno
Hello,

Attach to Process workflow doesn't work with PHP Debugging in VS. You need to have PHP Project setup, start the debugging usual way (F5) and make sure xdebug initiates the debug session. In case of REST API, the best way would be to setup remote_autostart https://docs.devsense.com/debugging/troubleshooting#debugger-wont-work-when-dont-open-a-page-wait-for-a-request-from

Please let me know if that helped.

Thanks,

Re: API/Attach To Process

PostPosted: March 20th, 2017, 2:42 pm
by silas2
Yeees!!! It works. Thanks.

Re: API/Attach To Process

PostPosted: March 22nd, 2017, 11:29 am
by Miloslav Beno
Perfect! Happy to help ;-)

Have a good one,