Skip to content

Conversation

@janepie
Copy link
Member

@janepie janepie commented Apr 16, 2025

We can now ask for connections in the future.

The requested time is interpreted in the timezone of the origin ("now" is still now). All time values in the response are returned in the timezone of each location.

@janepie janepie force-pushed the feat/future-trains branch from c2bbac0 to 1ee739a Compare April 17, 2025 09:09
@janepie janepie requested a review from marcelklehr April 17, 2025 09:09
Copy link
Member

@julien-nc julien-nc left a comment

Choose a reason for hiding this comment

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

Which timezone is used by the here API? Since no timezone is specified in the departureTime GET param, it might use UTC.
It would be nice to pass the user timezone (if that is supported by the API) or check if we need to convert the departure time to UTC.

@janepie
Copy link
Member Author

janepie commented Apr 17, 2025

If nothing is specified, it's using the local timezone at the origin location what I actually think is quite nice

@marcelklehr
Copy link
Member

Yeah, I think that makes sense, no?

@marcelklehr
Copy link
Member

Although, if departure_time is None, context agent sends a UTC time, which might be interpreted as local time, if we're departing from, say, Bejing

@janepie
Copy link
Member Author

janepie commented Apr 17, 2025

It adds the timezone in that case so the API knows it's in UTC

@janepie
Copy link
Member Author

janepie commented Apr 23, 2025

See here, next train in local time

image

@janepie janepie requested a review from julien-nc April 23, 2025 12:24
Copy link
Member

@julien-nc julien-nc left a comment

Choose a reason for hiding this comment

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

👍 🚂

@janepie janepie force-pushed the feat/future-trains branch from 1ee739a to 1ae36b7 Compare April 23, 2025 12:28
@marcelklehr marcelklehr merged commit b28c474 into main Apr 24, 2025
2 checks passed
@marcelklehr marcelklehr deleted the feat/future-trains branch April 24, 2025 13:52
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 this pull request may close these issues.

4 participants