Skip to content
This repository was archived by the owner on Mar 6, 2026. It is now read-only.

fix: Handle int for DateTimeProperty#285

Merged
chrisrossi merged 2 commits intogoogleapis:masterfrom
chrisrossi:fix-261
Jan 9, 2020
Merged

fix: Handle int for DateTimeProperty#285
chrisrossi merged 2 commits intogoogleapis:masterfrom
chrisrossi:fix-261

Conversation

@chrisrossi
Copy link
Contributor

In Datastore, projection queries involving entities with DateTime
properties return integer timestamps instead of datetime.datetime
objects. This fix handles that case and returns datetime.datetime
objects regardless of the query type.

Fixes #261.

In Datastore, projection queries involving entities with DateTime
properties return integer timestamps instead of `datetime.datetime`
objects. This fix handles that case and returns `datetime.datetime`
objects regardless of the query type.

Fixes googleapis#261.
@chrisrossi chrisrossi requested a review from cguardia January 9, 2020 16:17
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Jan 9, 2020
Copy link
Contributor

@cguardia cguardia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

DateTimeProperty returns "AttributeError: 'int' object has no attribute 'tzinfo'" in projection query

3 participants