-
Notifications
You must be signed in to change notification settings - Fork 308
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deserialize meta #286
Deserialize meta #286
Conversation
cdc9a4f
to
a0a2c1d
Compare
The fields only exist on collection-returning API operations.
a0a2c1d
to
b543023
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One note about the deprecated changelog file, other than that looks good to me. Thanks @timoreimann!
@@ -1,5 +1,9 @@ | |||
# Change Log | |||
|
|||
## unreleased |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We've deprecated this changelog file in favour of using GitHub's release notes. Could you remove this entry?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay never mind, looks like Zach merged this already. I can do this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ohhh wait, I'm totally wrong, thought we did this here as well as doctl
, but it's only for doctl
. False alarm everyone 🤦♂
This change deserializes the meta field into the response, allowing easy access to the total number of objects returned by API operations yielding collections.
We also remove links and meta fields from stubbed getters that do not return collections: according to the respective documentations, links and meta fields won't be included for single element responses.
For now, I have only implemented the change for storage (volumes and snapshots). I'd appreciate getting some initial feedback on the approach, after which I'm more than happy to support all other collection-returning API operations as well.