View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0001721 | Xdebug | Step Debugging | public | 2019-12-04 14:07 | 2023-08-01 10:36 |
Reporter | mlocati | Assigned To | derick | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | resolved | Resolution | won't fix | ||
Platform | PC | OS | Windows 10 | OS Version | 1909 |
Product Version | 2.8.1 | ||||
Summary | 0001721: Unablt to stop debug session - XDEBUG_SESSION cookie not deleted | ||||
Description | I use Eclipse + PDT. When starting a web debug session, PDT calls the website URL with an URL like this: http://my.site/?XDEBUG_SESSION_START=ECLIPSE_DBGP&KEY=15754677630784 The server response contains this header: Set-Cookie: XDEBUG_SESSION=ECLIPSE_DBGP; expires=Thu, 05-Dec-2019 01:56:03 GMT; Max-Age=43200; path=/ and I can do a step-by-step debugging in Eclipse. When I stop the debugging session, PDT calls this URL: http://localhost:121/?XDEBUG_SESSION_STOP_NO_EXEC=ECLIPSE_DBGP&KEY=15754677630784 In previous Xdebug versions I had no issues, but now the response to that second URL is: HTTP/1.1 200 OK
And the XDEBUG_SESSION cookie is not deleted (so, the debug session remains active). | ||||
Tags | XDEBUG_SESSION | ||||
Operating System | |||||
PHP Version | 7.4.0-7.4.4 | ||||
|
PS; PHP version is actually 7.4.0, but it's not available in the dropdown list |
|
I've fixed the warning through https://github.com/xdebug/xdebug/pull/539, and I can indeed reproduce your problem. For some reason, although Xdebug sets the cookie with PHPs internal php_setcookie function, it never makes it into the headers that are sent out. That's going to take more investigation. However, I would recommend that instead of these two GET/POST parameters, you use one of the browser extensions to activate an Xdebug session instead: https://xdebug.org/docs/remote#browser-extensions — that way, you can click on an icon in your browser without having to press "Go" in your IDE. |
|
I just updated to xdebug 2.9.2 and the issue is still there: C:>php -v When browsing to my local development server to stop the Xdebug session (eg to http://localhost:11031/?XDEBUG_SESSION_STOP_NO_EXEC=ECLIPSE_DBGP&KEY=15807217074863) the browser sends this request: GET http://localhost:11031/?XDEBUG_SESSION_STOP_NO_EXEC=ECLIPSE_DBGP&KEY=15807217074863 HTTP/1.1 And the server still answers with HTTP/1.1 200 OK
As you can see, the cookie is not deleted, and the warning is still there. |
|
i'm having the same problem in xdebug 3.0.4 (php_xdebug-3.0.4-7.4-vc15-x86_64.dll): $ ./php -v |
|
It seems that the XDEBUG_SESSION_STOP_NO_EXEC Get/Post parameter is no longer valid. Instead, we should use the XDEBUG_SESSION_STOP. With XDebug V2 this was working without problems :( The workaround for me, every time I need to finish a debug session is: Change de URL opened by Netbeans IDE to close debug session and change the param XDEBUG_SESSION_STOP_NO_EXEC to XDEBUG_SESSION_STOP https://localhost/?XDEBUG_SESSION_STOP_NO_EXEC=netbeans-xdebug That makes XDebug delete the XDEBUG_SESSION Cookie. |
|
I don't think I will be spending more time on this. These extra GET parameters were always a workaround for IDEs that don't really play nice with the way how the debugger works. |
Date Modified | Username | Field | Change |
---|---|---|---|
2019-12-04 14:07 | mlocati | New Issue | |
2019-12-04 14:07 | mlocati | Tag Attached: XDEBUG_SESSION | |
2019-12-04 14:13 | mlocati | Note Added: 0005193 | |
2020-01-12 16:06 | derick | Note Added: 0005211 | |
2020-01-12 16:06 | derick | Status | new => confirmed |
2020-01-12 16:06 | derick | Target Version | => 3.0dev |
2020-01-12 16:06 | derick | PHP Version | 7.4alpha => 7.4.0-7.4.4 |
2020-02-03 10:14 | mlocati | Note Added: 0005234 | |
2020-03-12 16:35 | derick | Category | Usage problems (Wrong Results) => Variable Display |
2020-03-12 16:37 | derick | Category | Variable Display => Step Debugging |
2021-03-15 16:32 | derick | Target Version | 3.0dev => |
2021-05-06 14:45 | engelj | Note Added: 0005872 | |
2022-02-04 20:49 | xavi.portell@hotmail.com | Note Added: 0006200 | |
2023-08-01 10:36 | derick | Assigned To | => derick |
2023-08-01 10:36 | derick | Status | confirmed => resolved |
2023-08-01 10:36 | derick | Resolution | open => won't fix |
2023-08-01 10:36 | derick | Note Added: 0006625 |