Closed falconws closed 3 years ago
Hi! Indeed, there currently is no way to specify this. I'm in Germany and still use UTC myself. I don't remember exactly why but I think that the dates that speedtest-cli output in the JSON results were always in UTC.
I like using a TZ environment variable. Is this standard practice otherwise?
@ansemjo https://github.com/ansemjo/speedtest-plotter/blob/master/speedtest-plotter#L60 Is this your code specify UTC?
Is this standard practice otherwise?
I think it's right.
@ansemjo https://github.com/ansemjo/speedtest-plotter/blob/master/speedtest-plotter#L60 Is this your code specify UTC?
Yes, here I am using a timestamp in UTC. But that is for compatability with the previous speedtest-cli
measurement tool, that always returned UTC timestamps.
Furthermore, gnuplot
does not seem to easily allow for timezones either but I am looking for workarounds now.
I have added a number of commits to add some timezone transformations with dateutil.tz.gettz()
.
The DockerHub build has just finished, so you can pull the latest image now and start your container with:
docker run -d -p 8000:8000 -e TZ=Asia/Tokyo ansemjo/speedtest
Using -e TZ=JST
directly does not seem to work; it needs to be a string from tzselect
.
Another sidenote: the timestamps are still explicitly stored as UTC in the database to a) be backwards compatible without any jumps and b) avoid any confusion on daylight savings time.
Thank you very much. I'll try after job.
speedtest-plotter result graph Measurement Date is
UTC
. I want specifyJST
(I'm Japanese). How to specify local timezone?TZ
environment doesn't work.