Closed ofir-ov closed 9 years ago
Time is definitely accepted, but it looks like there might be a regression in handling the miliseconds portion of the timestamp. I'll have the team take a look.
@Ofir-Purple, a fix for this went out at the end of last week, and the timestamps are being properly parsed now. Can you give it another shot?
Closing old PRs. If it's indeed not fixed in the current version, please let us know!
UrbanAirship's feedback API documentation clearly states that the "since" object should be of the form 2014-05-15.
When using the given example ( airship.feedback(datetime.datetime.utcnow() - datetime.timedelta(days=1)) ), the API returns a 400 bad request. The reason is that there's a time portion to the "since" parameter. E.g. 2014-05-15T15:23:45.238315 .
This fix ensures that even if a datetime object is received, the request to UA's server will only have the date portion of "since".
The fix was made inside the feedback function instead of to the documentation in order to maintain backwards compatibility.