AnsweredAssumed Answered

Problem with Python piwebapi client - time_zone parameter

Question asked by gavin.strack Champion on Jun 25, 2018
Latest reply on Jun 26, 2018 by gavin.strack

Hi PI^2,

 

I'm having some difficulty with extracting interpolated values using the time_zone argument. I've tried using the Windows and IANA time zone format but all timestamps are given in GMT.

 

e.g.

dfs = client.data.get_multiple_interpolated_values(paths, start_time="y", end_time="t", interval="5s", time_zone="Australia/Perth")
dfs = client.data.get_multiple_interpolated_values(paths, start_time="y", end_time="t", interval="5s", time_zone="W. Australia Standard Time")

 

Both of these return datetime strings of the UTC format:

2018-06-23T06:42:58.0007825Z

 

Has anyone else encountered this issue or can suggest a solution? I'd prefer not to manually slice and dice the string to get the local time if avoidable.

 

TIA!

Gav

Outcomes