View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002049 | Xdebug | Step Debugging | public | 2021-12-02 23:28 | 2022-02-01 16:34 |
Reporter | Zobo | Assigned To | derick | ||
Priority | normal | Severity | major | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Product Version | 3.1.2 | ||||
Fixed in Version | 3.1.3 | ||||
Summary | 0002049: evaling broken code (still) causes unhandled exception in PHP 7.4 | ||||
Description | This issue is directly related https://bugs.xdebug.org/view.php?id=1993 . | ||||
Steps To Reproduce | Crate file <?php xdebug_break(); Stop execution on breakpoint and run eval. Step next and it sould eval -i 17 -- bmFtZXNwYWNl step_over -i 21 | ||||
Additional Information | Fix tested on PHP 7.4.3 Provided https://github.com/xdebug/xdebug/pull/811 | ||||
Tags | No tags attached. | ||||
Operating System | Win, Linux... | ||||
PHP Version | 7.4.20-7.4.29 | ||||
|
I can't reproduce this with the information provided: https://github.com/xdebug/xdebug/pull/812 — Can you provide the full xdebug log and script that you use please? |
|
Here is the, code, xd2.log that show stepping through it without executing evaluate, and xd3.log that adds the eval command in the middle. See the lineno in stack, how it jumps to 0. xd3.log (5,683 bytes)
[33708] Log opened at 2021-12-08 21:37:01.962513 [33708] [Step Debug] INFO: Connecting to configured address/port: localhost:51831. [33708] [Step Debug] INFO: Connected to debugging client: localhost:51831 (through xdebug.client_host/xdebug.client_port). :-) [33708] [Step Debug] -> <init xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" fileuri="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" language="PHP" xdebug:language_version="7.4.26" protocol_version="1.0" appid="33708"><engine version="3.1.1"><![CDATA[Xdebug]]></engine><author><![CDATA[Derick Rethans]]></author><url><![CDATA[https://xdebug.org]]></url><copyright><![CDATA[Copyright (c) 2002-2021 by Derick Rethans]]></copyright></init> [33708] [Step Debug] <- feature_set -i 1 -n resolved_breakpoints -v 1 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="1" feature="resolved_breakpoints" success="1"></response> [33708] [Step Debug] <- feature_set -i 2 -n notify_ok -v 1 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="2" feature="notify_ok" success="1"></response> [33708] [Step Debug] <- feature_set -i 3 -n extended_properties -v 1 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="3" feature="extended_properties" success="1"></response> [33708] [Step Debug] <- run -i 4 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="run" transaction_id="4" status="break" reason="ok"><xdebug:message filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="5"></xdebug:message></response> [33708] [Step Debug] <- stack_get -i 5 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="stack_get" transaction_id="5"><stack where="{main}" level="0" type="file" filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="5"></stack></response> [33708] [Step Debug] <- context_names -i 6 -d 0 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_names" transaction_id="6"><context name="Locals" id="0"></context><context name="Superglobals" id="1"></context><context name="User defined constants" id="2"></context></response> [33708] [Step Debug] <- context_get -i 7 -d 0 -c 0 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_get" transaction_id="7" context="0"></response> [33708] [Step Debug] <- eval -i 8 -- bmFtZXNwYWNl [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="eval" transaction_id="8" status="break" reason="ok"><error code="206"><message><![CDATA[error evaluating code]]></message></error></response> [33708] [Step Debug] <- context_names -i 9 -d 0 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_names" transaction_id="9"><context name="Locals" id="0"></context><context name="Superglobals" id="1"></context><context name="User defined constants" id="2"></context></response> [33708] [Step Debug] <- context_get -i 10 -d 0 -c 0 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_get" transaction_id="10" context="0"></response> [33708] [Step Debug] <- step_over -i 11 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="step_over" transaction_id="11" status="break" reason="ok"><xdebug:message filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="5"></xdebug:message></response> [33708] [Step Debug] <- stack_get -i 12 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="stack_get" transaction_id="12"><stack where="{main}" level="0" type="file" filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="0"></stack></response> [33708] [Step Debug] <- context_names -i 13 -d 0 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_names" transaction_id="13"><context name="Locals" id="0"></context><context name="Superglobals" id="1"></context><context name="User defined constants" id="2"></context></response> [33708] [Step Debug] <- context_get -i 14 -d 0 -c 0 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_get" transaction_id="14" context="0"></response> [33708] [Step Debug] <- step_over -i 15 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="step_over" transaction_id="15" status="stopping" reason="ok"></response> [33708] [Step Debug] <- stop -i 16 [33708] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="stop" transaction_id="16" status="stopped" reason="ok"></response> [33708] Log closed at 2021-12-08 21:37:08.733266 xd2.log (7,419 bytes)
[2792] Log opened at 2021-12-08 21:36:15.213550 [2792] [Step Debug] INFO: Connecting to configured address/port: localhost:62939. [2792] [Step Debug] INFO: Connected to debugging client: localhost:62939 (through xdebug.client_host/xdebug.client_port). :-) [2792] [Step Debug] -> <init xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" fileuri="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" language="PHP" xdebug:language_version="7.4.26" protocol_version="1.0" appid="2792"><engine version="3.1.1"><![CDATA[Xdebug]]></engine><author><![CDATA[Derick Rethans]]></author><url><![CDATA[https://xdebug.org]]></url><copyright><![CDATA[Copyright (c) 2002-2021 by Derick Rethans]]></copyright></init> [2792] [Step Debug] <- feature_set -i 1 -n resolved_breakpoints -v 1 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="1" feature="resolved_breakpoints" success="1"></response> [2792] [Step Debug] <- feature_set -i 2 -n notify_ok -v 1 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="2" feature="notify_ok" success="1"></response> [2792] [Step Debug] <- feature_set -i 3 -n extended_properties -v 1 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="3" feature="extended_properties" success="1"></response> [2792] [Step Debug] <- run -i 4 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="run" transaction_id="4" status="break" reason="ok"><xdebug:message filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="5"></xdebug:message></response> [2792] [Step Debug] <- stack_get -i 5 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="stack_get" transaction_id="5"><stack where="{main}" level="0" type="file" filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="5"></stack></response> [2792] [Step Debug] <- context_names -i 6 -d 0 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_names" transaction_id="6"><context name="Locals" id="0"></context><context name="Superglobals" id="1"></context><context name="User defined constants" id="2"></context></response> [2792] [Step Debug] <- context_get -i 7 -d 0 -c 0 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_get" transaction_id="7" context="0"></response> [2792] [Step Debug] <- step_over -i 8 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="step_over" transaction_id="8" status="break" reason="ok"><xdebug:message filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="5"></xdebug:message></response> [2792] [Step Debug] <- stack_get -i 9 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="stack_get" transaction_id="9"><stack where="{main}" level="0" type="file" filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="5"></stack></response> [2792] [Step Debug] <- context_names -i 10 -d 0 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_names" transaction_id="10"><context name="Locals" id="0"></context><context name="Superglobals" id="1"></context><context name="User defined constants" id="2"></context></response> [2792] [Step Debug] <- context_get -i 11 -d 0 -c 0 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_get" transaction_id="11" context="0"></response> [2792] [Step Debug] <- step_over -i 12 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="step_over" transaction_id="12" status="break" reason="ok"><xdebug:message filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="6"></xdebug:message></response> [2792] [Step Debug] <- stack_get -i 13 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="stack_get" transaction_id="13"><stack where="{main}" level="0" type="file" filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="6"></stack></response> [2792] [Step Debug] <- context_names -i 14 -d 0 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_names" transaction_id="14"><context name="Locals" id="0"></context><context name="Superglobals" id="1"></context><context name="User defined constants" id="2"></context></response> [2792] [Step Debug] <- context_get -i 15 -d 0 -c 0 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_get" transaction_id="15" context="0"></response> [2792] [Step Debug] <- step_over -i 16 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="step_over" transaction_id="16" status="break" reason="ok"><xdebug:message filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="7"></xdebug:message></response> [2792] [Step Debug] <- stack_get -i 17 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="stack_get" transaction_id="17"><stack where="{main}" level="0" type="file" filename="file:///C:/local_disk/zobo/Projects/vscode-php-debug/vscode-php-debug/testproject/watch2.php" lineno="7"></stack></response> [2792] [Step Debug] <- context_names -i 18 -d 0 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_names" transaction_id="18"><context name="Locals" id="0"></context><context name="Superglobals" id="1"></context><context name="User defined constants" id="2"></context></response> [2792] [Step Debug] <- context_get -i 19 -d 0 -c 0 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_get" transaction_id="19" context="0"></response> [2792] [Step Debug] <- step_over -i 20 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="step_over" transaction_id="20" status="stopping" reason="ok"></response> [2792] [Step Debug] <- stop -i 21 [2792] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="stop" transaction_id="21" status="stopped" reason="ok"></response> [2792] Log closed at 2021-12-08 21:36:18.696398 |
|
|
|
Fixed for Xdebug 3.1.3. I've removed the version define check altogether, as it was needed for PHP 7.2 and up, but also had to adjust the patch due to a new compiler warning. |
Date Modified | Username | Field | Change |
---|---|---|---|
2021-12-02 23:28 | Zobo | New Issue | |
2021-12-08 17:47 | derick | Assigned To | => derick |
2021-12-08 17:47 | derick | Status | new => feedback |
2021-12-08 17:47 | derick | Note Added: 0006173 | |
2021-12-08 21:42 | Zobo | Note Added: 0006174 | |
2021-12-08 21:42 | Zobo | File Added: xd3.log | |
2021-12-08 21:42 | Zobo | File Added: xd2.log | |
2021-12-08 21:42 | Zobo | File Added: watch2.php | |
2021-12-08 21:42 | Zobo | Status | feedback => assigned |
2021-12-15 11:29 | derick | Note Added: 0006175 | |
2021-12-15 15:31 | derick | Status | assigned => closed |
2021-12-15 15:31 | derick | Resolution | open => fixed |
2021-12-15 15:31 | derick | Fixed in Version | => 3.2dev |
2021-12-15 15:31 | derick | Note Added: 0006176 | |
2022-02-01 16:34 | derick | Fixed in Version | 3.2dev => 3.1.3 |