[RELEASE] OzWeather - Australian Weather Addon using BOM data

  Thread Rating:
  • 3 Votes - 4.33 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
bossanova808 Offline
Donor
Posts: 2,206
Joined: Sep 2009
Reputation: 33
Location: Melbourne, Australia
Post: #451
And my bit too - http://wiki.xbmc.org/index.php?title=Add...in_Changes

Thanks!

My XBMC stuff:
find quote
runey71 Offline
Junior Member
Posts: 9
Joined: Jan 2011
Reputation: 0
Location: Mount Barker, South Australia
Post: #452
Thank you for an excellent Australian weather app Smile

There are a few things I think I would like to tinker with if that is ok with you.

Changes
- Option to zoom in / out of the 128km, 256km, 512km, national radar images (So for my local radar IDR46 a 3 is appended for 128km (IDR463), 2 for 256km (IDR462), and 1 for 512k (IDR461)
- View Options Location as a drop down box
- Loading animation whilst waiting for data to load
- Add mini weather to Weather tab (So when the Weather tab is highlighted but not entered into then todays weather is displayed)
- Preload weather data for all suburbs in settings and buffer (to minimise waiting time for weather data to be loaded)

I'm a total XBMC noob. Figured making a few tweaks to an existing addon will give me a good introduction before I start writing my own addons. Hope you don't mind Smile
find quote
bossanova808 Offline
Donor
Posts: 2,206
Joined: Sep 2009
Reputation: 33
Location: Melbourne, Australia
Post: #453
It's fine with me, and I certainly don't have the time, so go for it.

If you fork off:
https://github.com/bossanova808/weather.ozweather

...just submit a pull request when you're done & tested and we'll get it happening. Make sure you support all features in Confluence at a minimum, though - other skins are nice but it has to work properly with the default for me/xbmc team to consider it for the master repo.

My XBMC stuff:
find quote
runey71 Offline
Junior Member
Posts: 9
Joined: Jan 2011
Reputation: 0
Location: Mount Barker, South Australia
Post: #454
Thanks boss Smile

I've roughly done the zooming of radars and mini weather on home screen. It's a shame that overwriting xml files in the skin is required. Trying to figure out if there is some way to do that as an override from within the addon. Lots of reading to be done to see what can and can't be done.
find quote
bossanova808 Offline
Donor
Posts: 2,206
Joined: Sep 2009
Reputation: 33
Location: Melbourne, Australia
Post: #455
It would be scriptable as part of the addon install I believe, but I think you will want to be very cautious with over-writing default skin files in Confluence!

Another approach would be give to the addon a dependency on a version of Confluence with this integrated, but I very much doubt team xbmc would host that, so it would com eout of the master repo which is not going to happen...so I think, in all, that just getting people to install a few skin files is the way to go...but if you can come up with another method that they will go for that would of course be pretty great & make it easier for everyone.

My XBMC stuff:
find quote
runey71 Offline
Junior Member
Posts: 9
Joined: Jan 2011
Reputation: 0
Location: Mount Barker, South Australia
Post: #456
Agreed. A dependency is probably not the best way to go. The way you are already doing it seems good. The basic weather is usable without any modifications. The advanced features require some files to be replaced. If I can find a more automated way of achieving it then that's great Smile if not then that's life.
find quote
ozviewer Offline
Junior Member
Posts: 10
Joined: Apr 2014
Reputation: 0
Post: #457
Hi,
I am having trouble on this Oz Weather app on android gotham.

I get the message saying
X Error Script failed Oz Weather

I have also tried the alternative, Yahoo Weather, but this returns the same script error message.

Is this a known bug, or is there a work around to enable it to work on the android?

Here is a report I have tried to upload

http://xbmclogs.com/show.php?id=267468

I only have my "L" plates on, so please allow for that in any response.

Thank you
find quote
bossanova808 Offline
Donor
Posts: 2,206
Joined: Sep 2009
Reputation: 33
Location: Melbourne, Australia
Post: #458
Yep just as I expected - the Python Image Library (PIL) is missing

Code:
14:34:25 T:1860648792   DEBUG: ### Oz Weather-0.7.2 ### Importing PIL as extra features are activated.
14:34:25 T:1860648792   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                            Error Type: <type 'exceptions.ImportError'>
                                            Error Contents: No module named PIL
                                            Traceback (most recent call last):
                                              File "/mnt/sdcard/Android/data/org.xbmc.xbmc/files/.xbmc/addons/weather.ozweather/default.py", line 751, in <module>
                                                forecast(location, radar)
                                              File "/mnt/sdcard/Android/data/org.xbmc.xbmc/files/.xbmc/addons/weather.ozweather/default.py", line 264, in forecast
                                                buildImages(radarCode)
                                              File "/mnt/sdcard/Android/data/org.xbmc.xbmc/files/.xbmc/addons/weather.ozweather/default.py", line 425, in buildImages
                                                prepareBackgrounds(radarCode)
                                              File "/mnt/sdcard/Android/data/org.xbmc.xbmc/files/.xbmc/addons/weather.ozweather/default.py", line 367, in prepareBackgrounds
                                                downloadBackground(radarCode, "IDR.legend.0.png")
                                              File "/mnt/sdcard/Android/data/org.xbmc.xbmc/files/.xbmc/addons/weather.ozweather/default.py", line 323, in downloadBackground
                                                from PIL import Image
                                            ImportError: No module named PIL
                                            -->End of Python script error report<--

I believe that this is a known thing but I am nt sure of current status - you might want to ask here:
http://forum.xbmc.org/showthread.php?tid...id=1653538

Note if you turn off the extended features, you should at least get a basic forecast without errors (and based on BOM data) - you just won't have access to radars etc (but I doubt you've installed the skin files for those anyway).

My XBMC stuff:
find quote
ozviewer Offline
Junior Member
Posts: 10
Joined: Apr 2014
Reputation: 0
Post: #459
Thanks bossanova808...I'll move along to there...
find quote
Martijn Offline
Team Kodi
Posts: 11,235
Joined: Jul 2011
Reputation: 162
Location: Dawn of time
Post: #460
@bossanova808
if PR5201 goes in you need to make sure you add PIL to the dependencies list. (which you actually should already have done).

Always read the XBMC online-manual, FAQ and search the forums before posting.
Do NOT e-mail Team-XBMC members asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting, make sure you read this first

For your mediacenter artwork go to
[Image: fanarttv.png]
find quote
bossanova808 Offline
Donor
Posts: 2,206
Joined: Sep 2009
Reputation: 33
Location: Melbourne, Australia
Post: #461
@martijn - must have missed that memo Wink

so script.module.pil?

version 1.1.7 I take it?

My XBMC stuff:
(This post was last modified: 2014-08-13 09:06 by bossanova808.)
find quote
Martijn Offline
Team Kodi
Posts: 11,235
Joined: Jul 2011
Reputation: 162
Location: Dawn of time
Post: #462
(2014-08-13 09:03)bossanova808 Wrote:  @martijn - must have missed that memo Wink

so script.module.pil?

version 1.1.7 I take it?

correct Smile
well you don't need it for the normal function but do for the advanced, so you should rely on it. It will prevent people from installing it if they don't have PIL. At least they won't get the error then Wink

Normally it "should" already be installed by default so not relying on it wouldn't be an issue. Hopefully it gets fixed soon

Always read the XBMC online-manual, FAQ and search the forums before posting.
Do NOT e-mail Team-XBMC members asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting, make sure you read this first

For your mediacenter artwork go to
[Image: fanarttv.png]
(This post was last modified: 2014-08-13 09:16 by Martijn.)
find quote
bossanova808 Offline
Donor
Posts: 2,206
Joined: Sep 2009
Reputation: 33
Location: Melbourne, Australia
Post: #463
Ok, no probs, will update and send pull request thingy

My XBMC stuff:
find quote
Post Reply