SABIN "Turns out it's a problem at line 362, where it checks for errors from Yahoo:
if (yahoo_woeid_result['ResultSet']['Error'] != 0) and (yahoo_woeid_result['ResultSet']['Results'] != None):
is always true because yahoo_woeid_result['ResultSet']['Error'] is a string; I fixed it by comparing with a string as well:
if (yahoo_woeid_result['ResultSet']['Error'] != '0') and (yahoo_woeid_result['ResultSet']['Results'] != None):
so it's an easy fix"
Thanks! :)
SABIN
"Turns out it's a problem at line 362, where it checks for errors from Yahoo:
if (yahoo_ woeid_result[ 'ResultSet' ]['Error' ] != 0) and (yahoo_ woeid_result[ 'ResultSet' ]['Results' ] != None):
is always true because yahoo_woeid_ result[ 'ResultSet' ]['Error' ] is a string; I fixed it by comparing with a string as well:
if (yahoo_ woeid_result[ 'ResultSet' ]['Error' ] != '0') and (yahoo_ woeid_result[ 'ResultSet' ]['Results' ] != None):
so it's an easy fix"
Thanks! :)