Library Auto Update addon redux
#1
Okay so ... I have taken rob webers script.libraryautoupdate which was in the official xbmc add on repo for dharma and modified/updated it to work with git head. I also added a check to see if a library update is already in progress and if so, cancel the new update. So in effect it will update (as specified in settings) the video and/or music libraries at specified intervals (currently .5, 1, 2, 4, 8, 16, 24 hrs.) as long as source is not playing and said library is not already updating.

Now the scheduled updates will be skipped and the timer reset if A. a video or music is playing (to avoid an update while playing either) or B. a scan of either library is already in progress (which is why it works best with xbmc revs from https://github.com/xbmc/xbmc/commit/9688...b9eb4c1bca (thanks vdrfan!) .

Since I am a complete n00b to xbmc addon scripting I am pretty sure it might have some holes in it for pre-eden ... but that said I rely on the script to make my xbmc installs work most like an appleTV type setup in that the library(s) are automatically updated at specified intervals.

So ... it works fine on git head for xbmc as of https://github.com/xbmc/xbmc/commit/9688...b9eb4c1bca which allows the script to discern between whether or not a music or library scan is in process. Any install from before that will fail on update.

The add on can be downloaded here: http://handbrake.dynaflashtech.net/downl...update.zip

Please note: this only works on xbmc git head as of https://github.com/xbmc/xbmc/commit/9688...b9eb4c1bca properly, as its targeted at the next xbmc eden release.

ISSUES: One of the issues I am having is that the linked zip file will not install properly from the current addon manager. it will report that is not a supported addon structure. I have no clue why this is and any info would be greatly appreciated from those 'in the know'.

So, to install it and try it out ... you have to decompress the zip file and put it in your addons directory.

Basically at this point I would love to have someone tell me how to make it install in the git head addons manager from a zip so I can get feedback for starters.

Further ... I also would like to know if this is most appropriately offered under a new addon or as a fork to rob webers most excellent work for an auto update addon for dharma as applied to xbmc eden.

Please test and advise ...

Edit: below was fixed, its was an issue with xbmc as opposed to this add on.
Note: accessing the 'changelog' causes a crash.

Thanks.
Reply
#2
this doesn't work in the latest nightly releases, at least i get an error, haven't looked into it much yet though
--
Image
Reply
#3
Worked for me using the july 29 build. I usually set a cron to run but this is much cleaner and easier to manage thanks for sharing

Also your issue with the folder structure is the additional _MACOSX folder located inside the archive. I believe this folder is hidden on the Mac which may be why you missed it. Remove and it installs fine.
--Dascmo

\\ OpenElec \ Frodo \ ASROCK 330HT \\ AEON NOX 4.0 \\


Free Online Storage: Copy

^^HIGHLY RECOMMENDED^^
Reply
#4
dascmo Wrote:Worked for me using the july 29 build. I usually set a cron to run but this is much cleaner and easier to manage thanks for sharing

Also your issue with the folder structure is the additional _MACOSX folder located inside the archive. I believe this folder is hidden on the Mac which may be why you missed it. Remove and it installs fine.

Nice thanks for the tip on the hidden folder, never gave it a thought!

There is a change coming in library.isscanning pretty quick so I will update it then (this is where it checks to see if there is a scan already in progress.

I also would ask what other time intervals folks would like added?
Reply
#5
dascmo Wrote:Worked for me using the july 29 build. I usually set a cron to run but this is much cleaner and easier to manage thanks for sharing
Just ran a fresh build on git head yesterday and it still works here.

dascmo Wrote:Also your issue with the folder structure is the additional _MACOSX folder located inside the archive. I believe this folder is hidden on the Mac which may be why you missed it. Remove and it installs fine.
You were right! Removed the hidden files and zipped and installs great right from the zip. I have replaced the one in the link above with one that installs right from the zip file. Thanks!
Reply
#6
dynaflash Wrote:Nice thanks for the tip on the hidden folder, never gave it a thought!

There is a change coming in library.isscanning pretty quick so I will update it then (this is where it checks to see if there is a scan already in progress.

I also would ask what other time intervals folks would like added?

I'm good with every 6 hours.

Is there a way to set the script to automatically schedule an update if is misses one. Basically if I happen to be watching a movie when it's supposed to run it "automagically" starts 15 minutes after the movie ends and then resumes the normal schedule.
--Dascmo

\\ OpenElec \ Frodo \ ASROCK 330HT \\ AEON NOX 4.0 \\


Free Online Storage: Copy

^^HIGHLY RECOMMENDED^^
Reply
#7
dascmo Wrote:Is there a way to set the script to automatically schedule an update if is misses one. Basically if I happen to be watching a movie when it's supposed to run it "automagically" starts 15 minutes after the movie ends and then resumes the normal schedule.

I'll take a look and see, that might make sense to try like every 30 minutes after a fail to see if it can do a successful one (which would only happen while watching a movie or listening to music).
Reply
#8
Found this thread while I was looking for something else. Thought I'd reply since there have been many updates to the addon since this was posted. The biggest of these changes is that it is now part of the pre-Eden repository so is now compatible with the Eden framework. Instead of a program it is now an XBMC service so you no longer need autoexec.py.

@dynaflash - thanks for liking the addon enough to put in some modifications. The way you had the "check for scanning" piece coded it really wasn't doing much of anything. Launching the scan command if there is already a scan running doesn't do anything, so checking before the command is nice but not really necessary. I did incorporate a type of scan checking in the new version of the addon but it is to check that you don't try to run video and music scans at the same time, and will block until they are completed. this type of checking makes more sense.

@dascmo - scanning immediately after playback as opposed to waiting the full time limit is a great idea; and one of the main reasons I rewrote this addon as a service. The service framework allows the library update check to start within seconds after your playback has completed without waiting the full 1,2 or 5 hours between scans from the user setting.

If anyone has any thoughts or ideas about this addon here is a forum post that includes a link to the google code page: http://forum.xbmc.org/showthread.php?p=985288
Reply

Logout Mark Read Team Forum Stats Members Help
Library Auto Update addon redux0