Hello Kodi developers,
I must say I’m really impressed with the beta versions of Kodi 17 and 18 I’ve been testing here on my new CentOS 7 mediacenter PC. Many libraries and codecs need to be built manually because of CentOS minimalistic library support, but okay I am used to doing that for many years 😉
My question is: Wouldn’t it be an option to have a weather plugin in Kodi which does not query a weather service directly, but uses a (Python or even shell scripting based) proxy kind of system which translates the results of a web based global weather service (like Yahoo and others) into a standard format which the Kodi common weather plugin understands ?
Since programming plugins for Kodi is quite tricky for a programmer without any info on how the system is designed and without any on screen debug info (or standard output terminal) showing debug output it is almost impossible for me to program or modify a plugin.
I tried modifying the Yahoo Weather plugin many years ago in Kodi 13 or 14 I believe to not crash on strange humidity values (and the related calculated dew point), it took me 2 days to modify it so it didn’t crash on the dew point calculation !
Since maybe 3 years the Yahoo weather plugin is very unreliable, some days it works but many others it doesn’t work. Since we have fiber it should not be the Internet access which is causing the trouble.
As far as I can see the Yahoo weather plugin is the only one which does actually work sometimes here in Sweden.
Even in the latest Kodi 18 I am still getting the unreliable weather forecast issues (saying 0 degrees for all next 7 days). Though I do like the graphical weather forecast in Kodi it is best to switch it off as it mostly doesn’t work.
If it would have been a standalone script just supporting a few parameters for retrieving the weather location IDs and weather data itselves everyone can modify and create these scripts in a few hours or less for their local weather service !
I would say it basically needs these arguments:
./getweather.py getids “Stockholm” : Returns a text based list containing: “LocationID”,”Description”, user selects one in Kodi.
./getweather.py getdata <LocationID> day <-1..7> : Returns:
daynr -1..7 : Day number or NULL if no actual or predicted forecast is available. -1 gives the actual measured weather condition, 0 gives the prediction for the remainder of the current day and so on for the next days.
temperature -100..100 : Of course in degrees centrigrade, we -do- have SI standards nowadays.
humidity 0..100 : Expected relative relative humidity
rainmm 0..X : Expected rainfall in millimeters
windkmh 0..X : Wind speed in km/hour
predict 0..X : The weather prediction, and that is a tricky one to make a Kodi standard weather prediction list of the known X weather types which need to be translated from the weather service’s version to Kodi’s version.
I think by standardising the weather plugin request/response system it would make it much and much easier for people to write a standalone translation script for their local weather service (like here in Sweden SMHI.SE) and many people would love to do that 😉
Greetings and keep up the good work on Kodi,
Arno