Closed LuWey closed 2 years ago
Will try to reproduce, but you are using quite an outdated version of Xdebug and well, PHP.
What I see is that Xdebug reports no children in the DateTime object.
[3088] <- context_get -i 13 -d 0 -c 0
[3088] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_get" transaction_id="13" context="0"><property name="$TestDateTime" fullname="$TestDateTime" type="object" classname="DateTime" children="0" numchildren="0" page="0" pagesize="100"></property></response>
This is how it looks on my setup:
xd(1) -> <?xml version="1.0" encoding="iso-8859-1"?><response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="context_get" transaction_id="20" context="0"><property name="$TestDateTime" fullname="$TestDateTime" type="object" classname="DateTime" children="1" numchildren="3" page="0" pagesize="100"><property name="date" fullname="$TestDateTime->date" facet="public" type="string" size="26" encoding="base64"><![CDATA[MjAyMi0wOC0wNCAxNToyNDoyNy44NTc1Mjg=]]></property><property name="timezone_type" fullname="$TestDateTime->timezone_type" facet="public" type="int"><![CDATA[3]]></property><property name="timezone" fullname="$TestDateTime->timezone" facet="public" type="string" size="3" encoding="base64"><![CDATA[VVRD]]></property></property></response>
PHP 8.1.2 Xdebug 3.2.0-dev
I tried it now with PHP 7.4.13 and Xdebug 2.9.5 and it also works.
However 2.8.1 does not work.
I suggest you upgrade to latest Xdebug 2 or even better to Xdebug 3, but watch for changes that happen between 2 and 3.
Best.
Although I try to avoid changing a running system at all cost, I upgraded to Xdebug 3 and problem seems to be solved. Thank you for you support!
I already placed this issue over at bmewburn / vscode-intelephense, but I was told that debugging related issues belong to here.
This is the link to the issue with all screenshots: https://github.com/bmewburn/vscode-intelephense/issues/2275#issue-1324660230
PHP version: 7.4.27 Xdebug version: 2.8.1
See also: phpinfo.txt
VS Code extension version:
Your launch.json:
Xdebug php.ini config:
Xdebug logfile (from setting
xdebug.log
in php.ini):When running this and hovering over
print_r($TestDateTime);
Then this is the content of the xdebug logfile: xdebug.txt
VS Code extension logfile (from setting
"log": true
in launch.json): Don't have that setting