Open pitsi opened 4 weeks ago
@pitsi
Google says http://download.finance.yahoo.com/d/quotes.csv
has not worked since 2017...
So that code in there is old, and the info on conky.cc is out dated as well.
A kind Gentleman on the internet I found pointed out the new url and format which goes like this
https://query1.finance.yahoo.com/v7/finance/download/^GSPC?period1=1459468800&period2=1494028800&interval=1d&events=history&crumb=yt6hjEL5Tx8
That will get csv files, but I currently don't know what the period interval numbers mean.
I will see what I can do about the Conky code and also try to figure out how the period numbers correspond to dates.
(EDIT: Those are seconds since 1-1-1970. I get it now)
Yes, when you see timestamps that are more than a billion, they are on unix epoch time, which starts on that date, counts in seconds and you can get the current one with date +%s
.
As for the code being old, just imagine that until less than a year ago, I was checking conky's variables and configuration settings on these pages on sourceforge! That is why I asked if the weather variable stil exists. https://conky.sourceforge.net/variables.html https://conky.sourceforge.net/config_settings.html
Oh I knew about the epoch time. It's just that the url the confused me. I thought it was some fancy finance thing that accountants understood lol. (I know nothing about stocks or finance)
As for the weather variable, I am not currently seeing it anywhere in the source code. I have the latest git clone.
I did manage to get conky to retrieve the csv file from Yahoo though. The rest of the code works, just had to change the url a bit. However, it's ugly looking right now :)
And from what I am seeing, its always the same kind of data. Can only change the time period and interval like daily or weekly. Can't seem to get the fancier stuff. Maybe it's my lack of knowledge about this stuff...Or perhaps Yahoo only wants to show it on their website now.
What happened?
I am on debian testing/unstable x64 and I got the upgrade to 1.20.2 yesterday (from 1.19.6). And although I have a very specific conky layout for more than a decade now, I check for variables that may have changed or for new ones. And I came accross the stock variable, so I wanted to try it and I just put it on my .conkyrc (seen below). https://conky.cc/variables#stock
As it seems, it does not work, because when launcing conky from the terminal, curl tries again and again to parse something that is not there. I have no idea about programming, but I had a look at the source code and it seems this is the url it tries to parse.
http://download.finance.yahoo.com/d/quotes.csv
And it just can not open on my end. I do not know if it is geoblocked, but I asked a friend to test it with a vpn and a US ip, but it still fails.
p.s. Can someone please inform me if the weather variables have been removed? I do not want to open a new issue just for it.
Version
1.20.2
Which OS/distro are you seeing the problem on?
Debian
Conky config
Stack trace
No response
Relevant log output