[RELEASE] Weather Underground (default xbmc weather addon)

  Thread Rating:
  • 1 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
dnairb Offline
Donor
Posts: 99
Joined: Dec 2009
Reputation: 4
Post: #181
(2012-05-06 22:43)ronie Wrote:  i'll try if i can use some trickery in the script to handle the conversion for UK based locations.

Not wanting to add to the work, but perhaps a better way would be to allow the user to set mph/kmh/Bft, °C/°F, etc. That way the user can set their own preferences rather than conform to the country's localisation setting (for example if a Brit is living in the US, but wants to use °C rather than °F)
find quote
dnairb Offline
Donor
Posts: 99
Joined: Dec 2009
Reputation: 4
Post: #182
(2012-05-05 22:06)ronie Wrote:  weather.wunderground-0.1.6.zip
added:
- provide 3 day weekend forecast <- just to get everyone off my back ;-p

@pkscuot: sorry, you'll have to adjust the weekend code in your mod again...

Not wanting to step on anybody's toes here, but this requires merely 2 edits in WeekendForecast.xml:

Line 48, change:
Code:
<label>$LOCALIZE[16]</label>
to
Code:
<label>$INFO[Window.Property(Weekend.2.LongDay)]</label>

and line 135, change:
Code:
<label>$LOCALIZE[17]</label>
to
Code:
<label>$INFO[Window.Property(Weekend.3.LongDay)]</label>
(This post was last modified: 2012-05-11 08:07 by dnairb.)
find quote
pkscout Offline
Posting Freak
Posts: 1,045
Joined: Jan 2011
Reputation: 22
Location: Honolulu, HI
Post: #183
(2012-05-11 00:25)dnairb Wrote:  
(2012-05-05 22:06)ronie Wrote:  weather.wunderground-0.1.6.zip
added:
- provide 3 day weekend forecast <- just to get everyone off my back ;-p

@pkscuot: sorry, you'll have to adjust the weekend code in your mod again...

Not wanting to step on anybody's toes here, but this requires merely 2 edits in WeekendForecast.xml:

Line 48, change:
Code:
<label>$LOCALIZE[16]</label>
to
Code:
<label>$INFO[Window.Property(Weekend.2.LongDay)]</label>

and line 135, change:
Code:
<label>$LOCALIZE[17]</label>
to
Code:
<label>$INFO[Window.Property(Weekend.3.LongDay)]</label>

I did notice, however, that with my weekend set as Saturday/Sunday, the displayed "Chance of Precipitation" was as displayed for Friday/Saturday in the 10 day forecast. I couldn't see anything obvious in the default.py and skin files to explain this.

Sorry folks. I've been away on some family business. I should be able to look at this tomorrow. I'll also update the map display (the map fetched now is a different aspect ratio then the old one).
find quote
dnairb Offline
Donor
Posts: 99
Joined: Dec 2009
Reputation: 4
Post: #184
(2012-05-11 00:25)dnairb Wrote:  Line 48, change:
Code:
<label>$LOCALIZE[16]</label>
to
Code:
<label>$INFO[Window.Property(Weekend.2.LongDay)]</label>

and line 135, change:
Code:
<label>$LOCALIZE[17]</label>
to
Code:
<label>$INFO[Window.Property(Weekend.3.LongDay)]</label>

In addition to this (which I did and forgot to post):

Lines 50-113:
Change all instances of Weekend.1 to Weekend.2

Lines 137-200
Change all instances of Weekend.2 to Weekend.3
find quote
pkscout Offline
Posting Freak
Posts: 1,045
Joined: Jan 2011
Reputation: 22
Location: Honolulu, HI
Post: #185
I've updated the confluence mods for the weather underground beta plugin. Available for both confluence and confluence vertical here. This includes support for the three day weekend as well as the new map.

Two things with the maps.
1- If you change the zoom setting on the map, you are going to get this odd transition where you have some images that are at one zoom level and some at others. If possible it would be nice for the addon to delete all cached images if I change the zoom setting.
2- There is no way to tell what time the loop covers. With the paid map loop it had embedded time/date codes. I'm wondering if the addon could provide a pair of info labels that give the date/time of the first and last image so that at least a skinner could display that information.

And one thing with the weekend forecast. Weekend.1 is no longer always the first day of the weekend, and Weekend.2 is no longer always the second day of the weekend. Let me see if I can explain. Assuming "weekend" is defined as Saturday and Sunday, the three day weekend is Friday, Saturday, Sunday.

If you look at the data on Monday, Tuesday, Wednesday, Thursday, or Friday:
Weekend.1 is this Friday
Weekend.2 is this Saturday
Weekend.3 is this Sunday

On Saturday:
Weekend.1 is this Saturday
Weekend.2 is this Sunday
Weekend.3 is next Friday

On Sunday:
Weekend.1 is this Sunday
Weekend.2 is next Friday
Weekend.3 is next Saturday

My feeling is that without any changes, a user is likely to get confused when they see a weekend forecast that goes Saturday, Sunday, Friday. So for my mods I set it up so that on Monday - Friday you get the three day weekend forecast. Saturday you get just Saturday and Sunday. Sunday you get just Sunday. If you have your weekend set to one of the other options other than Saturday/Sunday in the advanced settings, this should still work.

To achieve this I used the following visibility logic:

Slot 1
Always Visible

Slot 2
<visible>![StringCompare(Window.Property(Weekend.2.LongDay),$LOCALIZE[13]) | StringCompare(Window.Property(Weekend.2.LongDay),$LOCALIZE[14]) | StringCompare(Window.Property(Weekend.2.LongDay),$LOCALIZE[15])]</visible>

Slot 3
<visible>![StringCompare(Window.Property(Weekend.3.LongDay),$LOCALIZE[13]) | StringCompare(Window.Property(Weekend.3.LongDay),$LOCALIZE[14]) | StringCompare(Window.Property(Weekend.3.LongDay),$LOCALIZE[15]) | StringCompare(Window.Property(Weekend.2.LongDay),$LOCALIZE[13]) | StringCompare(Window.Property(Weekend.2.LongDay),$LOCALIZE[14]) | StringCompare(Window.Property(Weekend.2.LongDay),$LOCALIZE[15])]</visible>

Skinners will need to pay attention to this (unless things change before this goes into production). I gotta be honest and say I don't like the fact that Weekend.1 is not always the first day of the weekend. I think it would be easier for skinners if Weekend.1 was always the first day of the three day weekend. If we're in the middle of the weekend, Weekend.1 would ideally either be empty or the addon would cache the forecast so that we still have access to display the data from the past. Ditto for Weekend.2 if we're at the end of the weekend.
(This post was last modified: 2012-05-13 16:25 by pkscout.)
find quote
ronie Offline
Team-XBMC Member
Posts: 9,097
Joined: Jan 2009
Reputation: 157
Post: #186
(2012-05-13 16:23)pkscuot Wrote:  Skinners will need to pay attention to this (unless things change before this goes into production). I gotta be honest and say I don't like the fact that Weekend.1 is not always the first day of the weekend. I think it would be easier for skinners if Weekend.1 was always the first day of the three day weekend. If we're in the middle of the weekend, Weekend.1 would ideally either be empty or the addon would cache the forecast so that we still have access to display the data from the past. Ditto for Weekend.2 if we're at the end of the weekend.

i thought about the possibility of caching too, and it *may* work if your htpc is up and running 24/7.
if it's not, there no guarantee we have any useful cached data available.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not PM or e-mail Team-XBMC members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
find quote
nessus Offline
Skilled Skinner
Posts: 777
Joined: Apr 2009
Reputation: 22
Post: #187
I was thinking about a different approach for showing the info on the weekend page.
The "Weekend Forecast" it is a forecast for the upcoming weekend and IMO should be available only until that time comes. So... instead to have blank days or double days why don't the script show the forecast for the upcoming weekend on Monday's, Tuesdays, Wednesdays, Thursdays and (starting from Friday) on Friday's, Saturday's and Sunday's to show the forecast for the next weekend ?. Even better (I don't now if that is doable) the script could add a "Next" indicator to every "Weekend.%i.LongDay" for Fridays, Saturdays and Sundays to show something like "Next Friday".

I think in this way there is no confusion or blank days. As for the weekend forecast on the current day of the weekend i think is not needed. The 36hour forecast and the Hourly forecast covers all the needs.

Last... since now we have three days forecast in weekend IMO the option to choose the weekend days in scripts settings is obsolete.

Cheers
Nessus
find quote
pkscout Offline
Posting Freak
Posts: 1,045
Joined: Jan 2011
Reputation: 22
Location: Honolulu, HI
Post: #188
(2012-05-14 09:57)nessus Wrote:  I was thinking about a different approach for showing the info on the weekend page.
The "Weekend Forecast" it is a forecast for the upcoming weekend and IMO should be available only until that time comes. So... instead to have blank days or double days why don't the script show the forecast for the upcoming weekend on Monday's, Tuesdays, Wednesdays, Thursdays and (starting from Friday) on Friday's, Saturday's and Sunday's to show the forecast for the next weekend ?. Even better (I don't now if that is doable) the script could add a "Next" indicator to every "Weekend.%i.LongDay" for Fridays, Saturdays and Sundays to show something like "Next Friday".

For me this would be even more confusing. If I get up Friday morning and want to check the weekend forecast, I'm more interested in this weekend (since it has just started). And on Saturday I'll probably be more interested in a quick look at Saturday and Sunday than next weekend. It isn't until Monday that I really start thinking about "next" weekend. Big Grin
find quote
dallasnights Offline
Fan
Posts: 486
Joined: Jan 2011
Reputation: 0
Post: #189
Mine only shows One day for the weekend with update
Is there a FIX
find quote
dnairb Offline
Donor
Posts: 99
Joined: Dec 2009
Reputation: 4
Post: #190
Weekend page showed Sunday only yesterday (as it should) and today shows Friday, Saturday and Sunday, also as it should.
Many thanks pkscuot.
find quote
ronie Offline
Team-XBMC Member
Posts: 9,097
Joined: Jan 2009
Reputation: 157
Post: #191
hehe, a typical case of 'put three people in a room and you'll get six different opinions' :-)

(2012-05-14 09:57)nessus Wrote:  Last... since now we have three days forecast in weekend IMO the option to choose the weekend days in scripts settings is obsolete.

according to the 'all knowing' wiki, there are a few countries that have a thursday/friday weekend.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not PM or e-mail Team-XBMC members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
find quote
nessus Offline
Skilled Skinner
Posts: 777
Joined: Apr 2009
Reputation: 22
Post: #192
(2012-05-14 16:09)pkscuot Wrote:  If I get up Friday morning and want to check the weekend forecast, I'm more interested in this weekend (since it has just started). And on Saturday I'll probably be more interested in a quick look at Saturday and Sunday than next weekend. It isn't until Monday that I really start thinking about "next" weekend. Big Grin
You have three options for that (Current, 36hour & Hourly) even with hour-by-hour forecast. Is not enough ?

(2012-05-14 19:15)ronie Wrote:  according to the 'all knowing' wiki, there are a few countries that have a thursday/friday weekend.
I didn't now that.

(2012-05-14 19:15)ronie Wrote:  hehe, a typical case of 'put three people in a room and you'll get six different opinions' :-)
lol Rofl

Cheers
Nessus
find quote
Nuka1195 Offline
Skilled Python Coder
Posts: 3,910
Joined: Dec 2004
Reputation: 18
Post: #193
Ronie can i get you to comment on this trac ticket
http://trac.xbmc.org/ticket/13024

and while off topic. do you experience this one.
http://trac.xbmc.org/ticket/13030

For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
find quote
pkscout Offline
Posting Freak
Posts: 1,045
Joined: Jan 2011
Reputation: 22
Location: Honolulu, HI
Post: #194
(2012-05-14 20:05)nessus Wrote:  
(2012-05-14 16:09)pkscuot Wrote:  If I get up Friday morning and want to check the weekend forecast, I'm more interested in this weekend (since it has just started). And on Saturday I'll probably be more interested in a quick look at Saturday and Sunday than next weekend. It isn't until Monday that I really start thinking about "next" weekend. Big Grin
You have three options for that (Current, 36hour & Hourly) even with hour-by-hour forecast. Is not enough ?

But using your thoughts, you can already see next weekend with the 10 day forecast. In terms of duplication, the weekend forecast is redundant. That information can be found a bunch of other places. It comes down to how people are likely to use it and what they are likely to expect. And that's hard for any of us to guess for sure much past our own usage. Here's the really funny thing. I basically never look at the weekend forecast myself. Until I had to make these changes I hadn't really thought about how it gets used.

Ronie might just have to leave it be and let the skinners figure it out.
(This post was last modified: 2012-05-14 21:46 by pkscout.)
find quote
BigNoid Offline
Team-XBMC Member
Posts: 3,084
Joined: Jul 2010
Reputation: 99
Location: Below sea level
Post: #195
-nvm-
(This post was last modified: 2012-05-16 22:32 by BigNoid.)
find quote
Post Reply