Skip to content
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

Item in GetItemResponse is not optional #895

Closed
kokobd opened this issue Feb 17, 2023 · 2 comments · Fixed by #896
Closed

Item in GetItemResponse is not optional #895

kokobd opened this issue Feb 17, 2023 · 2 comments · Fixed by #896
Milestone

Comments

@kokobd
Copy link
Contributor

kokobd commented Feb 17, 2023

The item in GetItemResponse is declared as

item :: Prelude.HashMap Prelude.Text AttributeValue

But the AWS Doc says:

If there is no matching item, GetItem does not return any data and there will be no Item element in the response.

Currently when an item is not found, I need to use resp ^. #item == mempty to check for that. Will it be better to use Maybe, or document this behavior?

@endgame
Copy link
Collaborator

endgame commented Feb 17, 2023

We have limited control over the documentation because it is generated from service definitions, and not worth overriding in configs. See #739 for how to resolve spurious Maybes in requests/responses.

@endgame endgame added this to the 2.0 milestone Feb 17, 2023
@endgame
Copy link
Collaborator

endgame commented Feb 17, 2023

Adding to 2.0 because it should be a quick fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants