#Person location to timezone
1 messages · Page 1 of 1 (latest)
Hi @edgy pewter , do you mean something like that?
https://www.geeksforgeeks.org/get-time-zone-of-a-given-location-using-python/
does that library support DST stuff do you know?
Looks like that example just returns the zone. If you wanted any type of actual time output, you'd probably just use zoneinfo with that result and do what you need.
Looks like Google (and others) offer a service you can use too that has similar functionality where you can pull out the zone id. All depends what you're ultimately looking to do: https://developers.google.com/maps/documentation/timezone/requests-timezone#responses
ideally want local only tracking of multiple countries/city time that knows about dst and stuff
Just tracking the current time itself? Given the zone ID, you should be able to just run the date command and that'll give you the current date/time
yeah probably, it was for a silly idea I had months ago. i cant even remember half of it. just saw this and thought that it might be a thing i could use
Get the location based on the timezone? You need latitude also.
Get the timezone of some user at some location. Atleast you can tell an AI with a script that gets the location of the active user and indeed with some python get the timezone
the library linked above takes lat/long