View Issue Details

IDProjectCategoryView StatusLast Update
0000577XdebugUncategorizedpublic2010-07-23 23:48
Reportermigajek Assigned Toderick  
PrioritynormalSeveritymajorReproducibilityhave not tried
Status resolvedResolutionno change required 
Summary0000577: $_POST complex type sub-items unavailable
Description

Hi,
when at break state [caused by breakpoint hit] I'm requesting "superglobals" by calling

context_get -i 9 -c 1

in response I get an array of superglobals together with their values, however only "simple" types ... when an array has nested array, it is returned empty (which seems to be OK, as we don't want to transfer tons of data when unnecessary). Here's the part of data which represents $_POST array:

<property name="_POST" fullname="$_POST" address="151453160" type="array" children="1" numchildren="2" page="0" pagesize="32">
<property name="Comment" fullname="$_POST['Comment']" address="151454340" type="array" children="1" numchildren="3">
</property>
<property name="ajax" fullname="$_POST['ajax']" address="151454604" type="string" size="12" encoding="base64">
<![CDATA[Y29tbWVudC1mb3Jt]]>
</property>
</property>

which is of course correct ... but, then I want to see values of $_POST['Comment'] array, thus I'm calling

property_get -i 11 -n $_POST['Comment']

in response I get an error ...

<response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug&quot; command="property_get" transaction_id="11" status="break" reason="ok"><error code="300"><message><![CDATA[can not get property]]></message></error></response>

I'm using XDebug svn revision 3274 ... is there any (undocumented) change in protocol (which requires for example base64 encoding variable name or something) or am I simply doing something wrong?

PHP Version 5.2.10-2ubuntu6.4
PHP API 20041225
PHP Extension 20060613
Zend Extension 220060519

TagsNo tags attached.
Operating System
PHP Version5.3.2

Activities

derick

2010-05-16 13:01

administrator   ~0001479

You're not specifiying the context (-c) for superglobals with property_get. It's possible that this worked before, but that was not meant so. Can you try adding -c 1 ?

migajek

2010-05-16 14:07

reporter   ~0001481

Hi,
indeed, specifying context each time solved the problem. So far it worked fine without that (possibly windows builds still do work correctly? I'll check it ASAP).
However the current behavior makes it a bit tricky to implement "Watches" feature, which now will require user to specify context (local/global) or to implement some kind of auto-guessing ...
Is there any possible solution for that?

derick

2010-07-23 23:48

administrator   ~0001545

I can't think of a solution here actually; so closing as this works as how it's supposed to.

Issue History

Date Modified Username Field Change
2010-05-09 18:12 migajek New Issue
2010-05-09 18:12 migajek PHP Version => 5.3.2
2010-05-09 18:12 migajek Xdebug Version => 2.1.0-dev
2010-05-16 13:01 derick Note Added: 0001479
2010-05-16 13:01 derick Status new => feedback
2010-05-16 14:07 migajek Note Added: 0001481
2010-07-23 23:48 derick Note Added: 0001545
2010-07-23 23:48 derick Status feedback => resolved
2010-07-23 23:48 derick Resolution open => no change required
2010-07-23 23:48 derick Assigned To => derick
2016-07-31 12:36 derick Category Usage problems => Usage problems (Crashes)
2016-07-31 12:38 derick Category Usage problems (Crashes) => Usage problems (Wrong Results)
2020-03-12 16:35 derick Category Usage problems (Wrong Results) => Variable Display
2020-03-12 16:38 derick Category Variable Display => Uncategorized