aws / aws/aws-sdk-php-v3-bridge
SimpleDB::select does not deserialize the Items list even though the response XML is valid.
- Dominant language
- PHP
- Stars
- 9
- Forks
- 14
- PR merge metrics
- No merged PRs in 30d
Description
### Describe the bug
SimpleDB::Select does not deserialize the Items list even though the response XML is valid.
NextToken is parsed correctly, but Items is always missing from the resulting Aws\Result.
# Environment
* aws/aws-sdk-php-v3-bridge: 0.4.0
* AWS SDK for PHP: 3.387.2
* PHP: 8.2.31
### Regression Issue
- [ ] Select this option if this issue appears to be a regression.
### Expected Behavior
```php
[
'Items' => [
[
'Name' => 'exmaple@example.com',
'Attributes' => [
:
],
],
],
]
```
### Current Behavior
```php
[
'@metadata' => [...],
]
```
### Reproduction Steps
```php
use Aws\SimpleDb\SimpleDbClient;
$client = new SimpleDbClient([
:
]);
$result = $client->select([
'SelectExpression' => "select * from users where itemName() = 'exmaple@example.com' limit 1",
]);
var_dump($result->toArray());
```
### Possible Solution
_No response_
### Additional Information/Context
# AWS CLI
The same query executed with the AWS CLI returns the expected result.
```shell
aws sdb select \
--select-expression "select * from users where itemName() = 'exmaple@example.com' limit 1"
```
Response:
```json
{
"Items": [
{
"Name": "exmaple@example.com",
"Attributes": [
:
]
}
]
}
```
⸻
Response XML
The SDK receives the following XML (trimmed):
```xml
exmaple@example.com
...
```
The XML appears to be valid and matches the SimpleDB API documentation.
### SDK version used
0.4.0
### Environment details (OS name and version, etc.)
macOS
Contributor guide
Research direction
Start at SimpleDbClient::select and follow the response deserialization path using the supplied XML and reproduction query. Compare how NextToken and Item/Attribute elements are mapped, then verify that the resulting Aws\Result contains Items with Name and Attributes as shown in the expected behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, php
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 58/100