Jump to content

Photo

Moksha Weather forecast module bug


  • Please log in to reply
3 replies to this topic

#1 Wolfgang

Wolfgang

    Member

  • Members
  • 9 posts

Posted 20 April 2017 - 09:12 AM

The weather forecast module reports windchill  in Fahrenheit even when the general setting is Celsius. Stupid, and I mean really stupid bug. Embarrassing.





A big thank you to everyone who contributes to Bodhi Linux


#2 The waiter

The waiter

    Module Master

  • Developer
  • 1542 posts
  • LocationBanska Bystrica, Slovakia

Posted 20 April 2017 - 11:15 AM

We will check it and fix if possible...



#3 ylee

ylee

    King of the Software Page

  • Moderators
  • 1559 posts
  • LocationSouth Carolina, USA

Posted 22 April 2017 - 06:35 PM

The weather forecast module reports windchill  in Fahrenheit even when the general setting is Celsius. Stupid, and I mean really stupid bug. Embarrassing.

 
Well thanks for reporting this. 
 
For the record no bug is stupid to me, stuff happens and all non trivial software has bugs.
 
I have alot of bodhi related stuff I am working on at the moment and my current project of adding font support to ePad takes priority at the moment. But I did take some time today to look at this issue. It is not as far as I can tell a bug with our forecast module. Our module simply reads an xml file fetched from yahoos weather site. The windchill field being reported in F regardless of a request for Celsius is on their end. Our module simply displays what it reads from their xml file. For my location with Celsius settings the xml file is found at:
 
<a data-ipb="nomediaparse" data-cke-saved-href="http://query.yahooap...2770197 and u="href="http://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20weather.forecast%20where%20woeid%3D12770197%20and%20u%3D" c'"="">http://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20weather.forecast%20where%20woeid%3D12770197%20and%20u%3D'c'
 
In the event Yahoo fixes this bug the contents of this xml on Apr 22 2017:
Spoiler

 
Notice I have requested Celsius:
 
 <yweather:units xmlns:yweather="http://xml.weather.y...com/ns/rss/1.0"  distance="km" pressure="mb" speed="km/h" temperature="C"/>

but windchill clearly is in F:
 
<yweather:wind xmlns:yweather="http://xml.weather.y...com/ns/rss/1.0"  chill="84" direction="210" speed="22.53"/>

even tho temperature is reported in Celsius:
 
<yweather:condition xmlns:yweather="http://xml.weather.y...com/ns/rss/1.0"  code="30" date="Sat, 22 Apr 2017 01:00 PM EDT" temp="29"  text="Partly Cloudy"/>

Hence what the forecast module displays IS accurate in the sense it displays what was reported to it by Yahoo.
 

hmm the weird part is sometimes Yahoo actually reports the window chill correctly in C. SO the problem is intermittent ...
 
My whole point being with all this is
  • This bug is not our fault
  • I am not going to fix this issue at this time (add a hack to detect yahoo incorrectly reporting wind chill in the wrong units and convert the field to the right units).
  • I expect in time Yahoo will fix said issue
┼átefan may feel different and if he patches the module more power to him. BTW patches are accepted so if this bugs you enough Wolfgang you are certainly free to patch it yourself.

"No technology can ever be too arcane or complicated for the black t-shirt crowd."


#4 The waiter

The waiter

    Module Master

  • Developer
  • 1542 posts
  • LocationBanska Bystrica, Slovakia

Posted 22 April 2017 - 06:54 PM

Yes, exactly. I can confirm these words. I spent some time with this module and can say the same. This bug is on the Yahoo side. I am not sure I will fix this issue because if Yahoo will fix it, it will need another fix again. Let's give it some time and then we will see.

 

Maybe the good idea is to report this bug somewhere if possible...

 

Anyway. I have fixed another part of the forecast module. If you change the units in the settings dialog, the values on the right side don't respect it. Now it works properly. Wait for the new package in the repository...






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users