core: now().timestamp() not returning correct value
Home Assistant release with the issue:
0.91.4
Last working Home Assistant release (if known): Unknown
Operating environment (Hass.io/Docker/Windows/etc.):
Hassio NUC image
Component/platform:
https://www.home-assistant.io/docs/configuration/templating/
Description of problem: The following two templates return the same value:
{{ utcnow().timestamp() }}
{{ now().timestamp() }}
1556243287.686556 1556243287.686613
These however do not return the same value:
{{ utcnow() }}
{{ now() }}
2019-04-26 01:48:07.686663+00:00 2019-04-26 11:48:07.686674+10:00
This has rendered my previously functional time templates incorrect and I now have to add my timezone offset in seconds to the now() timestamp.
Problem-relevant configuration.yaml
entries and (fill out even if it seems unimportant):
Traceback (if applicable):
Additional information:
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 20 (12 by maintainers)
@awarecan, @MartinHjelmare Is it a bug or desired behaviour?