influxdb icon indicating copy to clipboard operation
influxdb copied to clipboard

timezones do not work in InfluxDB 2 on Windows

Open alespour opened this issue 2 years ago • 5 comments

Steps to reproduce:

  1. run Flux query with location, eg.
import "array"
import "timezone"

array.from(rows:[ 
    {_time: 2022-03-12T00:00:00Z, _value: 10},
    {_time: 2022-03-12T06:00:00Z, _value: 20},
    {_time: 2022-03-12T12:00:00Z, _value: 30},
    {_time: 2022-03-12T18:00:00Z, _value: 40}
])
  |> aggregateWindow(every: 1d, fn:mean, location: timezone.location(name: "America/Los_Angeles"))

Expected behavior: Data are returned.

Actual behavior: Error error calling function "location" @10:52-10:98: unknown time zone America/Los_Angeles occurs.

Environment info:

  • System info: Windows 7
  • InfluxDB version: InfluxDB 2.1.1 (git: 657e1839de) build_date: 2021-11-09T03:03:48Z

Workaround is to download zoneinfo.zip from Go repo and set ZONEINFO env var. Discussed at https://community.influxdata.com/t/error-while-defining-location-parameter-for-aggregatewindow/24433.

alespour avatar Mar 31 '22 13:03 alespour

Thank you @alespour for putting this in the issues.

mutigozel avatar Mar 31 '22 16:03 mutigozel

Still an issue with InfluxDB 2.4.0

KyrumX avatar Sep 12 '22 06:09 KyrumX

Still an issue with InfluxDB 2.7.1

9000cats avatar Aug 06 '23 03:08 9000cats

Having the same problem w/ InfluxDB 2.7.1 and this is a critical issue. The none existent support is unacceptable.

alirezameftahi71 avatar Sep 05 '23 12:09 alirezameftahi71

Same in v2.7.6 with timezone "Europe/Berlin" :(

UltimateFighter avatar Apr 22 '24 06:04 UltimateFighter