Kodi Community Forum
mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Supplementary Tools for Kodi (https://forum.kodi.tv/forumdisplay.php?fid=116)
+--- Thread: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings (/showthread.php?tid=65644)



RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - outleradam - 2012-05-22

(2012-05-09, 22:59)djroketboy Wrote: What's the easiest way to fully remove/uninstall mythicalLibrarian?

Code:
sudo su
rm `which mythicalLibrarian`
rm `which librarian-notify-send`
rm `which MythDataGrabber`
rm -rf ~/.mythicalLibrarian
rm /etc/mythicalLibrarian

(2012-05-09, 05:13)TechnoSwiss Wrote: MythDataGrabber is having a problem doing a DB lookup with a recent Episode of CSI: NY.

http://thetvdb.com/?tab=episode&seriesid=73696&seasonid=468787&id=4297315

I originally tried 'mythicalLibrarian 2061_20120427210000.mpg CSI\ NY Slainte', when I do 'mythicalLibrarian --doover' to bring the error back up I get...

Moving 2061_20120427210000.mpg to original location
Revision 946 Tue May 8 10:43:59 PDT 2012
Attemting to pull database information on 2061_20120427210000.mpg
Traceback (most recent call last):
File "/usr/local/bin/MythDataGrabber", line 272, in <module>
writeData()
File "/usr/local/bin/MythDataGrabber", line 226, in writeData
f.write('%s = "%s"\n' % x)
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe1' in position 14: ordinal not in range(128)
RECSTART:2012-04-27 21:00:00 DATE:
PROGRAMID: ShowCategory:
PLOT:
PERFORMING MAINTENANCE ROUTINE...
REMOVING ORPHAN FOLDER:/recordings/Episodes/CSI NY/Season 7
SEARCHING: www.TheTvDb.com SHOW NAME: CSI NY EPISODE: Slainte
TESTING FOR ZAP2ITID MATCH:EP00679714 CSI: NY
agrep: 1 word matches within 1 error
FOUND:CSI: NY ID#:73696 WITH CONFIDENCE:-2
Parsing Downloaded information: CSI: NY.xml
AIRDATE FAILED. TITLE MATCH ON ABSOLUTE EPISODE NUMBER:
AIRDATE/SANDARD LOGIC FAILED. FUZZY LOGIC ABSOLUTE:
agrep: 2 words match within 2 errors
TOTAL MATCHES:2509 TOTAL VERIFIED FUZZY ERRORS:2908
EPISODE:Vigilante EPISODE NUMBER:156 S07E15 WITH CONFIDENCE: -2
CONFIDENCE:-4 LOGIC PATH: Attempted Match On Zap2itID: Failed; Attemted match on Standard Logic: Failed; Attemted Title match on Fuzzy Logic: Sucessful; Attemped match on OriginalAirDate: Failed; Attemted SubTitle match on Standard logic: Failed; Attemted SubTitle match on Fuzzy logic: Sucessful;
JOB: mythicalLibrarian '2061_20120427210000.mpg' 'CSI NY' 'Slainte'
TARGET SET:/recordings/Episodes/CSI NY/Season 7/CSI NY S07E15 (Vigilante).mpg
CREATING SYMLINK IN MOVE MODE
MOVED: 2061_20120427210000.mpg
TO: /recordings/Episodes/CSI NY/Season 7/CSI NY S07E15 (Vigilante).mpg
RSS ENTRY SUCCESSFULLY CREATED: /var/www/mythical-rss/rss.xml
SUCCESSFUL COMPLETEION TYPE: MoveModeSuccessful
done.

I contacted Mike. He is much better with the python than I am.


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - barney_1 - 2012-05-23

(2012-05-09, 05:13)TechnoSwiss Wrote: MythDataGrabber is having a problem doing a DB lookup with a recent Episode of CSI: NY.

http://thetvdb.com/?tab=episode&seriesid=73696&seasonid=468787&id=4297315

I originally tried 'mythicalLibrarian 2061_20120427210000.mpg CSI\ NY Slainte', when I do 'mythicalLibrarian --doover' to bring the error back up I get...

Moving 2061_20120427210000.mpg to original location
Revision 946 Tue May 8 10:43:59 PDT 2012
Attemting to pull database information on 2061_20120427210000.mpg
Traceback (most recent call last):
File "/usr/local/bin/MythDataGrabber", line 272, in <module>
writeData()
File "/usr/local/bin/MythDataGrabber", line 226, in writeData
f.write('%s = "%s"\n' % x)
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe1' in position 14: ordinal not in range(128)
RECSTART:2012-04-27 21:00:00 DATE:
PROGRAMID: ShowCategory:
PLOT:
PERFORMING MAINTENANCE ROUTINE...
REMOVING ORPHAN FOLDER:/recordings/Episodes/CSI NY/Season 7
SEARCHING: www.TheTvDb.com SHOW NAME: CSI NY EPISODE: Slainte
TESTING FOR ZAP2ITID MATCH:EP00679714 CSI: NY
agrep: 1 word matches within 1 error
FOUND:CSI: NY ID#:73696 WITH CONFIDENCE:-2
Parsing Downloaded information: CSI: NY.xml
AIRDATE FAILED. TITLE MATCH ON ABSOLUTE EPISODE NUMBER:
AIRDATE/SANDARD LOGIC FAILED. FUZZY LOGIC ABSOLUTE:
agrep: 2 words match within 2 errors
TOTAL MATCHES:2509 TOTAL VERIFIED FUZZY ERRORS:2908
EPISODE:Vigilante EPISODE NUMBER:156 S07E15 WITH CONFIDENCE: -2
CONFIDENCE:-4 LOGIC PATH: Attempted Match On Zap2itID: Failed; Attemted match on Standard Logic: Failed; Attemted Title match on Fuzzy Logic: Sucessful; Attemped match on OriginalAirDate: Failed; Attemted SubTitle match on Standard logic: Failed; Attemted SubTitle match on Fuzzy logic: Sucessful;
JOB: mythicalLibrarian '2061_20120427210000.mpg' 'CSI NY' 'Slainte'
TARGET SET:/recordings/Episodes/CSI NY/Season 7/CSI NY S07E15 (Vigilante).mpg
CREATING SYMLINK IN MOVE MODE
MOVED: 2061_20120427210000.mpg
TO: /recordings/Episodes/CSI NY/Season 7/CSI NY S07E15 (Vigilante).mpg
RSS ENTRY SUCCESSFULLY CREATED: /var/www/mythical-rss/rss.xml
SUCCESSFUL COMPLETEION TYPE: MoveModeSuccessful
done.

I pushed a fix to the repository. It should sanitize all Unicode now. I tested to make sure it won't crash anymore, but I can't test to make sure it plays nicely with MythicalLibrarian because I don't have anything in my database with Unicode characters. Can you give it a try and let me know if there are any issues?




RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - leighchallinor - 2012-06-09

Hi
I've changed my directorys in mythicalLibrarian.sh but the script seems to default to the directory it is running from ~/.mythicalLibrarian
I do have permissions for the directories I have specified which are on a NFS that mythtv uses to write it'srecordings to

Is this a bug or am I getting something completely wrong?


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - ubuntite - 2012-06-26

Hi,

I've been away for a while. My old version of mythicalLibrarian has been running just fine for a long time, but just yesterday I needed to install from scratch. Now I am having some problems.

Here are my questions:

1. What is the difference between mythicalLibrarian.sh and mythicalLibrarian (in /usr/local/bin)?

I tried installing manually on linux using the instructions on the wiki, but it only mentioned downloading mythicalLibrarian to /usr/local/bin. It didn't mention mythicalLibrarian.sh.

2. It seems the wiki neglects to mention downloading librarian-notify-send and MythDataGrabber to /usr/local/bin. Is that just an oversight?

3. Should I be using /home/mythtv/mythicalLibrarian or /home/mythtv/.mythicalLibrarian?

The wiki is confusing because it references both directories in different places.


So, it would be helpful for me to know what a final installation looks like. Let me know if this is correct. I will be running mythicalLibrarian as a user job from myth as user mythtv. Is this what a full installation should look like?

/usr/local/bin/mythicalLibrarian
/usr/local/bin/librarian-notify-send
/usr/local/bin/MythDataGrabber
/home/mythtv/mythicalLibrarian/_all_files_here_get_created_automatically_by_the_script_


If this is correct, what is the best way to set this up? Using mythicalSetup seems messy because of the permissions problems and having to run as multiple users.

Thanks.


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - GregoryK - 2012-06-27

(2012-06-26, 23:00)ubuntite Wrote: Hi,

I've been away for a while. My old version of mythicalLibrarian has been running just fine for a long time, but just yesterday I needed to install from scratch. Now I am having some problems.

[snip]

If this is correct, what is the best way to set this up? Using mythicalSetup seems messy because of the permissions problems and having to run as multiple users.

Thanks.

I just upgraded from 10.04 to 12.04 so went through the same process as you, a clean install from scratch after having mythicalLibrarian running fine for some time. Running as mythtv.

Why do you want to install manually? My steps were:

(1) delete the script completely using the commands outleradam listed about 3 or 4 posts up.
(2) 'sudo su mythtv'
(3) 'cd ~'
(4) follow the steps for Automatic Installation on the wiki page
(5) the last of those three commands will run the (pretty slick) installer that will download what you need and set everything up and then test it before exiting, including permissions.

Got me up and running quickly. Hope that helps.

/Greg



RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - ubuntite - 2012-06-27

Thanks. Worked for me as well. I think the manual installation instructions on the wiki are broken Confused

By the way, why did you install as root? Why not as your regular user?


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - GregoryK - 2012-06-27

(2012-06-27, 06:33)ubuntite Wrote: By the way, why did you install as root? Why not as your regular user?

I just wanted to be logged in as user <mythtv>, not my regular login user, to make sure the permissions worked out.

/Greg


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - ubuntite - 2012-06-27

Good idea. It worked!


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - Fozz - 2012-07-12

I has a pretty easy feature request I can help code if needed

When moving/lnking a video, also move or link the thumbnails.

Motivation: I use this to set up minidlna instead of the inbuilt mythtv upnp server and passing coverat/thumbnails would be nice.

It would be simple to implement
Whenever a file is moved or link also move or link $filename.*.png as cover.png, thumb.png or some other name.

I stuck a link of code in my mythicalLib file to do this for my use case.


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - divingmule - 2012-07-17

Hi, I wanted to do some editing with MythTV Frontend on recordings that ML had already moved and linked. What I came up with is a modified commercialremover.sh from the MythTV wiki.

Thought I'd share it here, if anyone is interested -> http://ubuntuone.com/5A3HZkTxMims3SzNlCtJXV

Use MythTV Frontend edit(add cutlist) run as userjob or command line
Code:
/PATH/TO/commercialremover.sh %DIR% %FILE% %CHANID% %STARTTIME%

This basically runs like the commercialremover.sh except we move the newly transcoded file to overwrite the real file instead of the link.
This only works with 0.25 and likely only with the lossless transcode profile.
Would be easy to edit for 0.24 or to-do commercial flagging>import cutlist.


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - jblasius - 2012-08-20

First of all, thank you for your work on this product. I just got my new system up and running and this is a fundamental part of how we use MythTV and XBMC together.

One question I cannot find the answer to: How can I prevent mythicalLibrarian from trying to move my Live TV recordings? Is there a MythTV setting that I have missed? Whenever I change Live TV channels, ML kicks on and attempts to move the files to my NAS and then fails. I cannot find the failed recording details in the output.log file.

Thanks in advance.


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - outleradam - 2012-08-20

(2012-08-20, 20:06)jblasius Wrote: First of all, thank you for your work on this product. I just got my new system up and running and this is a fundamental part of how we use MythTV and XBMC together.

One question I cannot find the answer to: How can I prevent mythicalLibrarian from trying to move my Live TV recordings? Is there a MythTV setting that I have missed? Whenever I change Live TV channels, ML kicks on and attempts to move the files to my NAS and then fails. I cannot find the failed recording details in the output.log file.

Thanks in advance.

What do you mean? You have mythicalLibrarian running on Live TV? I don't know how that will work since it's not recorded and there's no database information. You probly want to figure out why it's running on Live TV. I need more information. Why are you changing the channel while it's recording?


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - jblasius - 2012-08-21

Here are the output.log entries created while channel surfing live TV.

@@@@@@@@@@@NEW SEARCH INITIATED AT Mon Aug 20 20:32:09 MST 2012@@@@@@@@@@@@@@
Revision 947 Fri Aug 17 09:44:42 MST 2012 on Linux
%%%NO DATABASE INFORMATION. CHECK LOGIN/PASS OR FILE %%%%%
@@@@@@@@@@@NEW SEARCH INITIATED AT Mon Aug 20 20:32:19 MST 2012@@@@@@@@@@@@@@
Revision 947 Fri Aug 17 09:44:42 MST 2012 on Linux
%%%NO DATABASE INFORMATION. CHECK LOGIN/PASS OR FILE %%%%%
@@@@@@@@@@@NEW SEARCH INITIATED AT Mon Aug 20 20:32:34 MST 2012@@@@@@@@@@@@@@
Revision 947 Fri Aug 17 09:44:42 MST 2012 on Linux
%%%NO DATABASE INFORMATION. CHECK LOGIN/PASS OR FILE %%%%%
@@@@@@@@@@@NEW SEARCH INITIATED AT Mon Aug 20 20:33:49 MST 2012@@@@@@@@@@@@@@
Revision 947 Fri Aug 17 09:44:42 MST 2012 on Linux
%%%NO DATABASE INFORMATION. CHECK LOGIN/PASS OR FILE %%%%%
@@@@@@@@@@@NEW SEARCH INITIATED AT Mon Aug 20 20:33:59 MST 2012@@@@@@@@@@@@@@
Revision 947 Fri Aug 17 09:44:42 MST 2012 on Linux
%%%NO DATABASE INFORMATION. CHECK LOGIN/PASS OR FILE %%%%%

I also have a screenshot of the MythWeb Backend Status page that shows errors for each show I watched during my surfing.


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - outleradam - 2012-08-21

Run
Code:
sudo mythicalLibrarian --update
until there are no errors.


RE: mythicalLibrarian - a tool to build Movie and TV Show library from MythTV recordings - XBMCUser4657 - 2012-08-22

edit