No real version # change, but this does correct issues and add features. Every location should now work as expected. You do not need to change anything, simply download the script above. All corrections mentioned in this thread are already applied, as well as some not discussed here that were corrected. It also adds granularity to temperatures when converting. This means it doesn't strictly use integers anymore. It will use as many decimal points as you require when appropriate (yes, you can put 0 and still get integers). This makes it more accurate as well.
I like it; great as always. You might want to include document for usage for the !time command up at top near the rest of the triggers, just so people know it's included without reading changelog.
just found a bug. looks like when there's no decimal digit the script strips the last digit of the Celsius temperature.
example: when it's 86F it shows 3C, instead of 30C.
Florianopolis, Brazil (27.7°S/48.5°W) - Temperature: 86°F (3°C) - Conditions: Partly Cloudy - Wind: North at 12 MPH (18 KPH) - Humidity: 70% - Updated: 3:00 PM BRST (February 19, 2011)
when it does have a decimal digit it works fine:
Stockholm, Sweden (59.3°N/18.0°E) - Temperature: 3.6°F (-15.8°C) - Windchill: 4°F (-16°C) - Conditions: Mist - Wind: Calm - Humidity: 78% - Updated: 8:33 PM CET (February 19, 2011)
xREVx wrote:just found a bug. looks like when there's no decimal digit the script strips the last digit of the Celsius temperature.
example: when it's 86F it shows 3C, instead of 30C.
Florianopolis, Brazil (27.7°S/48.5°W) - Temperature: 86°F (3°C) - Conditions: Partly Cloudy - Wind: North at 12 MPH (18 KPH) - Humidity: 70% - Updated: 3:00 PM BRST (February 19, 2011)
when it does have a decimal digit it works fine:
Stockholm, Sweden (59.3°N/18.0°E) - Temperature: 3.6°F (-15.8°C) - Windchill: 4°F (-16°C) - Conditions: Mist - Wind: Calm - Humidity: 78% - Updated: 8:33 PM CET (February 19, 2011)
You are indeed correct. That was due to how I was stripping ending 0's and deciding whether or not to use the decimal point. It seems [string trim] is not what one should use to achieve this.. So I've rewritten entirely the logic that decides. It now splits the value into its integer value and its decimal remnants. It then scrubs only the decimal remnants of its ending 0's. If there were only 0's, then it will also remove the decimal point correctly now.
Is anyone else having issues with this in the last few days where nothing comes out of the bots on any commands? I'm having the same issue with incith-google script. Other scripts are working fine.
The only thing I can think of as a common denominator is the tcl http package requirement. I have both tcl 8.4 and 8.5 installed. I'm not sure where to go from here.
EDIT: Disregard this question. I had an issue where my userfile got corrupted and I borrowed one from another bot. This blew away my channel settings so my channels +google, +weather, etc settings got blown away and I didn't realize this.
missing close-brace: possible unbalanced brace in comment
while executing
"namespace eval incith {
namespace eval weather {
# [custom_format] : converts a string to the desired output
#
proc custom_format {htmla..."
(file "scripts/incith-weather.tcl" line 253)
invoked from within
"source scripts/incith-weather.tcl"
Last available source tested ceased functioning some time ago. Probably past its use by date now.
Add [SOLVED] to the thread title if your issue has been. Search | FAQ | RTM
Alchera wrote:Last available source tested ceased functioning some time ago. Probably past its use by date now.
Try this copy, 2.9a -> http://ereader.kiczek.com/incith-weather.tcl
It should function perfectly, and includes !time and granularity. Let me know if that doesn't cure that issue..