Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix collection resource hydration path #61

Merged
merged 2 commits into from
Feb 10, 2015
Merged

Conversation

danielgtaylor
Copy link
Member

This fixes #57 by hydrating resources from a collection with a JMESPath
query that is at collection.resource.path instead of collection.path
in the resource model.

import boto3

for o in boto3.resource('s3').Bucket('boto3').objects.all():
    # `o.meta.data` is set now, so the following succeeds.
    print(o.size)

cc @jamesls @kyleknap

This fixes #57 by hydrating resources from a collection with a JMESPath
query that is at `collection.resource.path` instead of `collection.path`
in the resource model.

```python
import boto3

for o in boto3.resource('s3').Bucket('boto3').objects.all():
    # `o.meta.data` is set now, so the following succeeds.
    print(o.size)
```
@danielgtaylor danielgtaylor added the bug This issue is a confirmed bug. label Feb 9, 2015
@danielgtaylor danielgtaylor self-assigned this Feb 9, 2015
@coveralls
Copy link

Coverage Status

Changes Unknown when pulling f4a2e72 on collection-path-fix into * on develop*.

@kyleknap
Copy link
Contributor

LGTM 🚢

danielgtaylor added a commit that referenced this pull request Feb 10, 2015
Fix collection resource hydration path.
@danielgtaylor danielgtaylor merged commit 28ae6a8 into develop Feb 10, 2015
@danielgtaylor danielgtaylor deleted the collection-path-fix branch February 10, 2015 00:25
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug This issue is a confirmed bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

S3 object property "size" not available
3 participants