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

History and Logbook should respect the server's timezone instead of the client's #4421

Closed
melyux opened this issue Jan 5, 2020 · 6 comments
Labels
Bug Current Bug in UI - Extra Attention stale

Comments

@melyux
Copy link

melyux commented Jan 5, 2020

Checklist:

  • [Yes] I updated to the latest version available
  • [Yes] I cleared the cache of my browser

Home Assistant release with the issue: 0.103.5

Last working Home Assistant release (if known): N/A

UI (States or Lovelace UI?): 20191204.1 - latest

Browser and Operating System: Safari client, Debian (docker) server

Description of problem:

The history graphs and the logbook should be respecting the server's timezone instead of the client's.

Expected behaviour:

The history graphs and the logbook show times in the browser/app's local timezone instead of the actual server site's.

Relevant config:

Default config

Steps to reproduce this problem:

Just have any accessories that show up in the logbook and history, and have the server be in a different timezone than the accessing client.

Javascript errors shown in the web inspector (if applicable):


Additional information:

@melyux melyux added the Bug Current Bug in UI - Extra Attention label Jan 5, 2020
@bramkragten
Copy link
Member

I think it makes more sense to have it using the client time zone, why would you not want it to do that?

@melyux
Copy link
Author

melyux commented Jan 6, 2020

Why would it make more sense to use the client time zone? Automations run using the server time. Especially for the History view, where state changes are shown on a day-to-day basis (instead of the last 24 hours), it doesn’t make sense to show events since midnight based on the client’s timezone since it’s not at all relevant to the server.

It’s also strange to look at the Logbook and see “Turn lights off at 9 pm triggered” happening at 7 pm.

Everything Home Assistant does is based on server time. Every remote management software I’ve seen either defaults to server time or allows a choice between site and browser time (UniFi, Blue Iris, AlarmDecoder, etc.).

@bramkragten
Copy link
Member

Maybe I don't understand you, but I assume your client time is the right time, as in, the time zone you are in at the moment? So you want so see when the events happen relative to that time?

@melyux
Copy link
Author

melyux commented Jan 6, 2020

I don’t understand. The client time is the time zone of the browser you access Home Assistant with, and the server time is the time zone of the actual server Home Assistant is running on. Right now, events and time stamps and charts on the client are based in the client’s timezone. I think it makes more sense for them to be based in the server’s timezone.

@drthanwho
Copy link

I'm also experiencing the same issue. In my use case HA runs on a +2 time zone, whereas I live abroad at a +1 timezone so when I'm on lovelace everything I see even though correct are adjusted for my timezone, which makes is complicated. It's easier for the brain to workout things knowing the time you see it's the time at home rather than having to calculate what time is at home given the time you see on your browser

@stale
Copy link

stale bot commented Jun 23, 2020

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍
This issue now has been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Jun 23, 2020
@stale stale bot closed this as completed Jul 3, 2020
@github-actions github-actions bot locked and limited conversation to collaborators Jul 5, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug Current Bug in UI - Extra Attention stale
Projects
None yet
Development

No branches or pull requests

3 participants