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

How best to get timezone data for imported records #515

Open
gene1wood opened this issue Dec 4, 2024 · 1 comment
Open

How best to get timezone data for imported records #515

gene1wood opened this issue Dec 4, 2024 · 1 comment

Comments

@gene1wood
Copy link

gene1wood commented Dec 4, 2024

I'm in the process of migrating from Google Timeline to Owntracks Recorder. It sounds like using the importer isn't ideal and so I've been following that blog entry (and others who are doing the same) to extend and improve that python import code to consume the Google Timeline JSON and render it into Owntracks rec files.

This has worked well. And I want to acknowledge that this method of importing historical data is not supported (as it's not going through the recorder API and instead just being written to the store files directly)

My question is, what would the best way be to get timezones working on this historical data. I've noticed that data points that are in the same timezone that I'm in do render correctly. I'm assuming this is because

  • I'm adding new records from the Android app through the recorder API
  • The recorder is doing the correct reverse geocoding and capturing in the LMDB database timezone information on those new records
  • The recorder API understands that these historical data points are "near" to the new data points and so they must have the same timezone

or maybe the recorder just shows times in the browser's local timezone when it doesn't know the timezone of the data point?

(correct me if I'm wrong)

The problem with missing this timezone data for historical records is that it looks like they just display in my local timezone which makes the time of day for the data points displayed incorrect.

I know I can't do reverse geocoding on 13 years of data. I'm wondering if there's a way to seed the minimal number of historical reverse geocoded data points in other timezones so that all of the other historical data points in those timezones show up with the correct timezone correction.

@jpmens
Copy link
Member

jpmens commented Dec 4, 2024

As long as you write the .rec files correctly, there is no reason why you shouldn't be creating them programmatically, that is perfectly acceptable.

That said, I am wondering whether there is a confusion between time zone data and reverse Geo coding. To respond to your second question first you could direct bulk reverse Geo code the date that you are importing into the rec files if you find a service which is willing to provide the data. We have had very very good experiences with OpenCage; you might want to look into their service offerings.

As for the time zone issue, I need a different explanation, please. There is no relationship between time zone and the LMDB database. The latter is used for reverse geocoded information

@jpmens jpmens transferred this issue from owntracks/talk Dec 5, 2024
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

No branches or pull requests

2 participants