Home » Language IDEs » PHP Development Tools (PDT) » XDebug and Path Mapping in RC1
XDebug and Path Mapping in RC1 [message #50325] |
Tue, 11 September 2007 11:41  |
Eclipse User |
|
|
|
RC1 now contains an automated ability to map paths when debugging web scripts for xdebug.
This means you can now debug remote server scripts within PDT.
Dave Kelsey
|
|
|
Re: XDebug and Path Mapping in RC1 [message #50353 is a reply to message #50325] |
Tue, 11 September 2007 15:17   |
Eclipse User |
|
|
|
"Dave Kelsey" <dkel50@hotmail.com> wrote in message
news:fc6cuh$hbo$1@build.eclipse.org...
> RC1 now contains an automated ability to map paths when debugging web
> scripts for xdebug. This means you can now debug remote server scripts
> within PDT.
I'm seeing some inconsistent behavior with xdebug, but maybe I'm doing it
wrong. In Debug > PHP Web Page > Server, what's the relationship between
File/Project and URL? Or more specifically, what exactly does the
File/Project setting do?
I've found that if they both refer to the same PHP file, the debug session
starts correctly, and the server sends the XDEBUG_SESSION cookie back. From
then on, I'm able to set breakpoints in other files, go to other URLs in the
browser, and the debugger will become active.
But it doesn't seem to work if they refer to different files. For example,
if File/Project just has a project name in it, Eclipse won't debug anything.
And if URL contains a URL that redirects somewhere else on the same server,
it also doesn't work. In both cases, the XDEBUG_SESSION cookie *does* get
sent back to the browser, but Eclipse must be ignoring it.
Any ideas?
Jacob
|
|
| |
Re: XDebug and Path Mapping in RC1 [message #50685 is a reply to message #50353] |
Wed, 12 September 2007 07:12   |
Eclipse User |
|
|
|
In the launch, the URL defines the initial URL to be invoked when you
want to debug your web environment. Once debugging you then control the
application from the web browser.
If your web server document root points to your PDT workspace, then the
content of the File/Project field is not important.
If however your server document root points to a different location and
you have a copy of the scripts in your PDT workspace, then the File/Project
field is very important as it is required to setup the path mapping information
internally between the scripts which are running on the web server and
the where these scripts exist within your PDT workspace. In this scenario the
URL you specify will invoke the initial PHP script. You specify in File / Project
this script that is located in your PDT workspace so that path mapping will
work. (specifying just a project will not work, although it could be made to work
in the future as an enhancement).
I hope to publish this info in a better place at some point, but I hope it
helps you understand what is going on.
Dave Kelsey
Jacob Weber wrote:
> "Dave Kelsey" <dkel50@hotmail.com> wrote in message
> news:fc6cuh$hbo$1@build.eclipse.org...
>> RC1 now contains an automated ability to map paths when debugging web
>> scripts for xdebug. This means you can now debug remote server scripts
>> within PDT.
>
> I'm seeing some inconsistent behavior with xdebug, but maybe I'm doing it
> wrong. In Debug > PHP Web Page > Server, what's the relationship between
> File/Project and URL? Or more specifically, what exactly does the
> File/Project setting do?
>
> I've found that if they both refer to the same PHP file, the debug session
> starts correctly, and the server sends the XDEBUG_SESSION cookie back. From
> then on, I'm able to set breakpoints in other files, go to other URLs in the
> browser, and the debugger will become active.
>
> But it doesn't seem to work if they refer to different files. For example,
> if File/Project just has a project name in it, Eclipse won't debug anything.
> And if URL contains a URL that redirects somewhere else on the same server,
> it also doesn't work. In both cases, the XDEBUG_SESSION cookie *does* get
> sent back to the browser, but Eclipse must be ignoring it.
>
> Any ideas?
> Jacob
>
>
|
|
| | |
Re: XDebug and Path Mapping in RC1 [message #51749 is a reply to message #50685] |
Fri, 14 September 2007 10:04   |
Eclipse User |
|
|
|
Yey! Great work to add path mapping on this short notice :D.
Unfortunately it's not yet working for me :(. The weird thing is that
initially it did work. As far as I know I didn't change any settings
between the last working run and the one after that.
I have set my File / Project to: /project/trunk/index.php
Break at First Line is on.
The URL is auto generated to http://remote/trunk/index.php
The thing though is that index.php does include files outside of the
project however on my initial working run I'd just get a message stating
that the file could not be found.
Pretty weird. Is there a possibility to view some logs somewhere and
debug information to find out what exactly happens.
Regards,
Marijn.
Dave Kelsey wrote:
> In the launch, the URL defines the initial URL to be invoked when you
> want to debug your web environment. Once debugging you then control the
> application from the web browser.
>
> If your web server document root points to your PDT workspace, then the
> content of the File/Project field is not important.
>
> If however your server document root points to a different location and
> you have a copy of the scripts in your PDT workspace, then the File/Project
> field is very important as it is required to setup the path mapping
> information
> internally between the scripts which are running on the web server and
> the where these scripts exist within your PDT workspace. In this
> scenario the
> URL you specify will invoke the initial PHP script. You specify in File
> / Project
> this script that is located in your PDT workspace so that path mapping will
> work. (specifying just a project will not work, although it could be
> made to work
> in the future as an enhancement).
>
> I hope to publish this info in a better place at some point, but I hope it
> helps you understand what is going on.
>
> Dave Kelsey
>
> Jacob Weber wrote:
>> "Dave Kelsey" <dkel50@hotmail.com> wrote in message
>> news:fc6cuh$hbo$1@build.eclipse.org...
>>> RC1 now contains an automated ability to map paths when debugging web
>>> scripts for xdebug. This means you can now debug remote server
>>> scripts within PDT.
>>
>> I'm seeing some inconsistent behavior with xdebug, but maybe I'm doing
>> it wrong. In Debug > PHP Web Page > Server, what's the relationship
>> between File/Project and URL? Or more specifically, what exactly does
>> the File/Project setting do?
>>
>> I've found that if they both refer to the same PHP file, the debug
>> session starts correctly, and the server sends the XDEBUG_SESSION
>> cookie back. From then on, I'm able to set breakpoints in other files,
>> go to other URLs in the browser, and the debugger will become active.
>>
>> But it doesn't seem to work if they refer to different files. For
>> example, if File/Project just has a project name in it, Eclipse won't
>> debug anything. And if URL contains a URL that redirects somewhere
>> else on the same server, it also doesn't work. In both cases, the
>> XDEBUG_SESSION cookie *does* get sent back to the browser, but Eclipse
>> must be ignoring it.
>>
>> Any ideas?
>> Jacob
>>
>>
|
|
|
Re: XDebug and Path Mapping in RC1 [message #51781 is a reply to message #51749] |
Fri, 14 September 2007 12:21   |
Eclipse User |
|
|
|
No, there is no way to debug the interactions currently without
downloading the source and running in a runtime workbench.
Could you provide some more details about your environment, ie
web server, and platform, PDT platform etc.
Cheers
Marijn van Zon wrote:
> Yey! Great work to add path mapping on this short notice :D.
>
> Unfortunately it's not yet working for me :(. The weird thing is that
> initially it did work. As far as I know I didn't change any settings
> between the last working run and the one after that.
>
> I have set my File / Project to: /project/trunk/index.php
> Break at First Line is on.
> The URL is auto generated to http://remote/trunk/index.php
>
> The thing though is that index.php does include files outside of the
> project however on my initial working run I'd just get a message stating
> that the file could not be found.
>
> Pretty weird. Is there a possibility to view some logs somewhere and
> debug information to find out what exactly happens.
>
> Regards,
>
> Marijn.
>
> Dave Kelsey wrote:
>> In the launch, the URL defines the initial URL to be invoked when you
>> want to debug your web environment. Once debugging you then control the
>> application from the web browser.
>>
>> If your web server document root points to your PDT workspace, then the
>> content of the File/Project field is not important.
>>
>> If however your server document root points to a different location and
>> you have a copy of the scripts in your PDT workspace, then the
>> File/Project
>> field is very important as it is required to setup the path mapping
>> information
>> internally between the scripts which are running on the web server and
>> the where these scripts exist within your PDT workspace. In this
>> scenario the
>> URL you specify will invoke the initial PHP script. You specify in
>> File / Project
>> this script that is located in your PDT workspace so that path mapping
>> will
>> work. (specifying just a project will not work, although it could be
>> made to work
>> in the future as an enhancement).
>>
>> I hope to publish this info in a better place at some point, but I
>> hope it
>> helps you understand what is going on.
>>
>> Dave Kelsey
>>
>> Jacob Weber wrote:
>>> "Dave Kelsey" <dkel50@hotmail.com> wrote in message
>>> news:fc6cuh$hbo$1@build.eclipse.org...
>>>> RC1 now contains an automated ability to map paths when debugging
>>>> web scripts for xdebug. This means you can now debug remote server
>>>> scripts within PDT.
>>>
>>> I'm seeing some inconsistent behavior with xdebug, but maybe I'm
>>> doing it wrong. In Debug > PHP Web Page > Server, what's the
>>> relationship between File/Project and URL? Or more specifically, what
>>> exactly does the File/Project setting do?
>>>
>>> I've found that if they both refer to the same PHP file, the debug
>>> session starts correctly, and the server sends the XDEBUG_SESSION
>>> cookie back. From then on, I'm able to set breakpoints in other
>>> files, go to other URLs in the browser, and the debugger will become
>>> active.
>>>
>>> But it doesn't seem to work if they refer to different files. For
>>> example, if File/Project just has a project name in it, Eclipse won't
>>> debug anything. And if URL contains a URL that redirects somewhere
>>> else on the same server, it also doesn't work. In both cases, the
>>> XDEBUG_SESSION cookie *does* get sent back to the browser, but
>>> Eclipse must be ignoring it.
>>>
>>> Any ideas?
>>> Jacob
>>>
>>>
|
|
|
Re: XDebug and Path Mapping in RC1 [message #52945 is a reply to message #51749] |
Wed, 19 September 2007 04:01  |
Eclipse User |
|
|
|
Actually sending the email was a mistake. I wanted to reply to the newsgroup
but only afterwards found out that I replied to you directly :). Anyways the
sysadmin of the server is on vacation at the moment and I have to wait until
he gets back (+/- two weeks :\) before xdebug can be upgraded. I think I did
locate part of the problem though. The server switches to https and I had
http configured. After changing that in the Web Server settings debug was
working again however still now fully. If I add a breakpoint debugging stops
working. Firefox hangs on "Waiting for server..." and the debugger doesn't
react. The same happens when I then remove the breakpoint. I have to restart
Eclipse to get debugging to work again.
On a positive note the path mapping works very well.
The PHP application is a collection of modules and I have a seperate project
for each of the modules as to be able to close projects if I don't need them
so that the Tasks and Problems are not cluttered, however the cross project
includes are picked up by the path mapper and the debugger displays the
relevant files :).
This is my Eclipse installation:
dtp-sdk_1.5.1_N091207.zip
eclipse-SDK-M20070913-1500-win32.zip
eclipse-test-framework-M20070913-1500.zip
emf-sdo-xsd-SDK-M200709120130.zip
GEF-SDK-M20070814-1555.zip
mylyn-2.1M1-e3.4.zip
org.eclipse.php_feature-incubation-S20070910_RC1.zip
RSE-SDK-I20070906-0800.zip
wtp-sdk-M-2.0.1RC2-20070913200918.zip
The server is running apache 2.0.59 and php 5.2.3 and xdebug 2.0.0RC4.
I use PuTTY to setup a remote ssh tunnel that forwards the remote port X to
local port 9000.
Regards,
Marijn.
From: Dave Kelsey [mailto:dkel50@hotmail.com]
Sent: 18 September 2007 21:53
To: Marijn van Zon
Subject: RE: XDebug and Path Mapping in RC1
Sorry Marijn, just saw the email. Did upgrading to 2.0.0 fix your problem ?
I must admit I
would have thought it would work with rc4, but I didn't do any testing with
it.
Cheers
Dave
> From: marijn@suninet.org
> To: dkel50@hotmail.com
> Subject: Re: XDebug and Path Mapping in RC1
> Date: Sat, 15 Sep 2007 00:27:51 +0200
>
> While going through all the software I found out that the remote server is
> running xdebug 2.0.0RC4 instead of the final release 2.0.0 *shrug*. Going
> to upgrade and test again to see if that fixes the problem...
>
> Regards,
>
> Marijn.
>
> ----- Original Message -----
> From: "Dave Kelsey" <dkel50@hotmail.com>
> Newsgroups: eclipse.tools.pdt
> Sent: Friday, September 14, 2007 6:21 PM
> Subject: Re: XDebug and Path Mapping in RC1
>
>
> > No, there is no way to debug the interactions currently without
> > downloading the source and running in a runtime workbench.
> >
> > Could you provide some more details about your environment, ie
> > web server, and platform, PDT platform etc.
> >
> > Cheers
> >
> >
> > Marijn van Zon wrote:
> >> Yey! Great work to add path mapping on this short notice :D.
> >>
> >> Unfortunately it's not yet working for me :(. The weird thing is that
> >> initially it did work. As far as I know I didn't change any settings
> >> between the last working run and the one after that.
> >>
> >> I have set my File / Project to: /project/trunk/index.php
> >> Break at First Line is on.
> >> The URL is auto generated to http://remote/trunk/index.php
> >>
> >> The thing though is that index.php does include files outside of the
> >> project however on my initial working run I'd just get a message
> >> stating that the file could not be found.
> >>
> >> Pretty weird. Is there a possibility to view some logs somewhere and
> >> debug information to find out what exactly happens.
> >>
> >> Regards,
> >>
> >> Marijn.
> >>
> >> Dave Kelsey wrote:
> >>> In the launch, the URL defines the initial URL to be invoked when you
> >>> want to debug your web environment. Once debugging you then control
> >>> the
> >>> application from the web browser.
> >>>
> >>> If your web server document root points to your PDT workspace, then
> >>> the
> >>> content of the File/Project field is not important.
> >>>
> >>> If however your server document root points to a different location
> >>> and
> >>> you have a copy of the scripts in your PDT workspace, then the
> >>> File/Project
> >>> field is very important as it is required to setup the path mapping
> >>> information
> >>> internally between the scripts which are running on the web server and
> >>> the where these scripts exist within your PDT workspace. In this
> >>> scenario the
> >>> URL you specify will invoke the initial PHP script. You specify in
> >>> File / Project
> >>> this script that is located in your PDT workspace so that path mapping
> >>> will
> >>> work. (specifying just a project will not work, although it could be
> >>> made to work
> >>> in the future as an enhancement).
> >>>
> >>> I hope to publish this info in a better place at some point, but I
> >>> hope it
> >>> helps you understand what is going on.
> >>>
> >>> Dave Kelsey
> >>>
> >>> Jacob Weber wrote:
> >>>> "Dave Kelsey" <dkel50@hotmail.com> wrote in message
> >>>> news:fc6cuh$hbo$1@build.eclipse.org...
> >>>>> RC1 now contains an automated ability to map paths when debugging
> >>>>> web scripts for xdebug. This means you can now debug remote server
> >>>>> scripts within PDT.
> >>>>
> >>>> I'm seeing some inconsistent behavior with xdebug, but maybe I'm
> >>>> doing it wrong. In Debug > PHP Web Page > Server, what's the
> >>>> relationship between File/Project and URL? Or more specifically, what
> >>>> exactly does the File/Project setting do?
> >>>>
> >>>> I've found that if they both refer to the same PHP file, the debug
> >>>> session starts correctly, and the server sends the XDEBUG_SESSION
> >>>> cookie back. From then on, I'm able to set breakpoints in other
> >>>> files, go to other URLs in the browser, and the debugger will become
> >>>> active.
> >>>>
> >>>> But it doesn't seem to work if they refer to different files. For
> >>>> example, if File/Project just has a project name in it, Eclipse won't
> >>>> debug anything. And if URL contains a URL that redirects somewhere
> >>>> else on the same server, it also doesn't work. In both cases, the
> >>>> XDEBUG_SESSION cookie *does* get sent back to the browser, but
> >>>> Eclipse must be ignoring it.
> >>>>
> >>>> Any ideas?
> >>>> Jacob
> >>>>
> >>>>
>
|
|
|
Goto Forum:
Current Time: Mon May 12 05:28:59 EDT 2025
Powered by FUDForum. Page generated in 0.04915 seconds
|