Bugs item #1584589, was opened at 2006-10-25 09:54
Message generated for change (Comment added) made by sf-robot
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=446895&aid=1584589&group_id=46652

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: plugins
Group: 1.6.0
>Status: Closed
Resolution: Fixed
Priority: 5
Private: No
Submitted By: Frank Naude (naudefj)
Assigned to: Nobody/Anonymous (nobody)
Summary: Weather download fails - empty barometer reading

Initial Comment:
ERROR parsing forecast data for 'SFXX0044'
        This could indicate a failed download of
weather data from msnbc.  You can confirm this by
examining the contents of the file
'/var/cache/freevo/weather_SFXX0044/data'.  Below is
also the traceback indicating where we discovered the
problem with the weather file.  If the weather file
appears intact, please report this to the
'[email protected]'

Traceback (most recent call last):
  File
"/usr/lib/python2.4/site-packages/freevo/plugins/weather.py",
line 317, in getForecast
    self.convertWeatherData()
  File
"/usr/lib/python2.4/site-packages/freevo/plugins/weather.py",
line 441, in convertWeatherData
    self.barometer = toBarometer( self.barometer )
  File
"/usr/lib/python2.4/site-packages/freevo/plugins/weather.py",
line 111, in toBarometer
    tTemp = float( baro )
ValueError: empty string for float()


----------------------------------------------------------------------

>Comment By: SourceForge Robot (sf-robot)
Date: 2006-11-08 19:20

Message:
Logged In: YES 
user_id=1312539

This Tracker item was closed automatically by the system. It was
previously set to a Pending status, and the original submitter
did not respond within 14 days (the time period specified by
the administrator of this Tracker).

----------------------------------------------------------------------

Comment By: Duncan Webb (duncanwebb)
Date: 2006-10-25 10:46

Message:
Logged In: YES 
user_id=104395

Thank you, the patch you sent has been applied to rel-1-6 in
r8476.

I also did the two functions above in the same way.

----------------------------------------------------------------------

Comment By: Frank Naude (naudefj)
Date: 2006-10-25 10:21

Message:
Logged In: YES 
user_id=143611

Patch to solve this problem:

--- freevo-1.6/src/plugins/weather.py   (revision 8475)
+++ freevo-1.6/src/plugins/weather.py   (working copy)
@@ -108,7 +108,11 @@
     return "%d" % ( int(nTemp),)

 def toBarometer( baro ):
-    tTemp = float( baro )
+    try:
+      tTemp = float( baro )
+    except ValueError:
+      tTemp = 0.0
+
     nTemp = tTemp*3.386
     return "%.1f" % (nTemp,)


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=446895&aid=1584589&group_id=46652

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Freevo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freevo-devel

Reply via email to