Kodi Community Forum
[DEPRECIATED] XBMC Subtitles - Addon Script (previously OpenSubtitles OSD) - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Subtitle Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=143)
+---- Thread: [DEPRECIATED] XBMC Subtitles - Addon Script (previously OpenSubtitles OSD) (/showthread.php?tid=75437)



- mr_blobby - 2010-08-17

XmemphistoX Wrote:So I've tried this twice so far. It works for a few tries, downloads subtitles fine then it starts to crash. It freezes until I hit back and it gives me the error "error script failed! : script.xbmc.subtitles." I have the newest version.

I reformatted my machine and the subtitles started to work again but only for a short while. I'm getting the same error message after 3 subtitle downloads. I pasted my log file on the following link if anyone can spare a few minutes to take a look for me. Thanks!

http://pastebin.com/NJuMv4ES
It is the same problem with the special characters, but this time not in the username, but in the subtitle filename:
Code:
214.02:57:15 T:208 M:2528444416   ERROR: Error Contents: (2, 'No such file or directory', 'C:\\Users\\mediacenter\\AppData\\Roaming\\XBMC\\cache\\sub_tmp\\M\xe2\x80\x9cme La.srt')
When the scrip starts, it first tries to clear the cache, before it will search for subtitles. I believe this is what causes the problem: the script is trying to delete a temporary subtitle from the cache, but the special characters causes the script error.
Workaround is to clear the cache manually: C:\Users\mediacenter\AppData\Roaming\XBMC\\cache


- XmemphistoX - 2010-08-17

mr_blobby Wrote:It is the same problem with the special characters, but this time not in the username, but in the subtitle filename:
Code:
214.02:57:15 T:208 M:2528444416   ERROR: Error Contents: (2, 'No such file or directory', 'C:\\Users\\mediacenter\\AppData\\Roaming\\XBMC\\cache\\sub_tmp\\M\xe2\x80\x9cme La.srt')
When the scrip starts, it first tries to clear the cache, before it will search for subtitles. I believe this is what causes the problem: the script is trying to delete a temporary subtitle from the cache, but the special characters causes the script error.
Workaround is to clear the cache manually: C:\Users\mediacenter\AppData\Roaming\XBMC\\cache

Thanks! Works perfectly again! Really appreciate you taking the time to look for me.


- amet - 2010-08-17

mr_blobby Wrote:Nope, you forgot to update the line
__version__ = "1.7.4"
in all versions after 1.7.4 of default.py Laugh

hehe, true that Laugh

I will try to remember for next time :p


- awarin - 2010-08-20

Hello im having problems downloading subtitles from undertexter.se.
Its only undertexter.se i have the problem with all other sources work.

im using Xbmcfreak 10.08 svn livecd. - XBMC svn32696 with latest features
- Linux Kernel 2.6.32-24.

ive checked the log and it d/l the subtitles correct and puts it under /sub_tmp but then it just stops. What does No archive given mean?.

Note. if i move undertexter.rar to my windows 7 machine i have no problem extracting it with winrar.



Saving subtitles to '/home/xbmc/.xbmc/temp/sub_tmp/undertexter.rar'
13:53:01 T:3056265088 M:2579767296 ERROR: XBMC.Extract, No archive given
13:53:17 T:2161273712 M:2579808256 DEBUG: Thread 2161273712 terminating (autodelete)
13:53:17 T:2688527216 M:2579808256 DEBUG: Thread 2688527216 terminating



- mr_blobby - 2010-08-20

awarin Wrote:Hello im having problems downloading subtitles from undertexter.se.
Its only undertexter.se i have the problem with all other sources work.

im using Xbmcfreak 10.08 svn livecd. - XBMC svn32696 with latest features
- Linux Kernel 2.6.32-24.

ive checked the log and it d/l the subtitles correct and puts it under /sub_tmp but then it just stops. What does No archive given mean?.

Note. if i move undertexter.rar to my windows 7 machine i have no problem extracting it with winrar.



Saving subtitles to '/home/xbmc/.xbmc/temp/sub_tmp/undertexter.rar'
13:53:01 T:3056265088 M:2579767296 ERROR: XBMC.Extract, No archive given
13:53:17 T:2161273712 M:2579808256 DEBUG: Thread 2161273712 terminating (autodelete)
13:53:17 T:2688527216 M:2579808256 DEBUG: Thread 2688527216 terminating
I had to use the XBMC builtin function 'extract' because there is no platform-independent python module for unpacking rar files.
This 'XBMC.Extract' function produces the error.
Which subtitle were you trying to download?


- awarin - 2010-08-20

mr_blobby Wrote:I had to use the XBMC builtin function 'extract' because there is no platform-independent python module for unpacking rar files.
This 'XBMC.Extract' function produces the error.
Which subtitle were you trying to download?

seems it doesnt matter what subtitle i choice it saves it as undertexter.rar here is an example. Tried maybe 10-15 diffrent movies all of them downloads with the .rar extention. Im guessing the other sites saves it in .zip

d/l subs for The.Final.2010.1080P.Blurip.x26-SSF.



14:23:46 T:2131995504 M:2547793920 DEBUG: In 'On click' selected : [10]
14:23:46 T:2131995504 M:2547793920 DEBUG: Selected : [10]
14:23:46 T:2131995504 M:2547793920 DEBUG: [Undertexter subtitle service]: Fetching subtitles using url http://www.undertexter.se/utext.php?id=21676
14:23:46 T:2131995504 M:2547793920 DEBUG: [Undertexter subtitle service]: Getting url: http://www.undertexter.se/utext.php?id=21676
14:23:46 T:2131995504 M:2547793920 DEBUG: [Undertexter subtitle service]: Saving subtitles to '/home/xbmc/.xbmc/temp/sub_tmp/undertexter.rar'
14:23:46 T:3056265088 M:2547793920 ERROR: XBMC.Extract, No archive given
14:24:06 T:2817522544 M:2547802112 DEBUG: Received request to serve 'DeviceDescription.xml'
14:24:06 T:2131995504 M:2547675136 DEBUG: [Undertexter subtitle service]: Failed to unpack subtitles in '/home/xbmc/.xbmc/temp/sub_tmp'


- mr_blobby - 2010-08-20

awarin Wrote:seems it doesnt matter what subtitle i choice it saves it as undertexter.rar here is an example. Tried maybe 10-15 diffrent movies all of them downloads with the .rar extention. Im guessing the other sites saves it in .zip

d/l subs for The.Final.2010.1080P.Blurip.x26-SSF.



14:23:46 T:2131995504 M:2547793920 DEBUG: In 'On click' selected : [10]
14:23:46 T:2131995504 M:2547793920 DEBUG: Selected : [10]
14:23:46 T:2131995504 M:2547793920 DEBUG: [Undertexter subtitle service]: Fetching subtitles using url http://www.undertexter.se/utext.php?id=21676
14:23:46 T:2131995504 M:2547793920 DEBUG: [Undertexter subtitle service]: Getting url: http://www.undertexter.se/utext.php?id=21676
14:23:46 T:2131995504 M:2547793920 DEBUG: [Undertexter subtitle service]: Saving subtitles to '/home/xbmc/.xbmc/temp/sub_tmp/undertexter.rar'
14:23:46 T:3056265088 M:2547793920 ERROR: XBMC.Extract, No archive given
14:24:06 T:2817522544 M:2547802112 DEBUG: Received request to serve 'DeviceDescription.xml'
14:24:06 T:2131995504 M:2547675136 DEBUG: [Undertexter subtitle service]: Failed to unpack subtitles in '/home/xbmc/.xbmc/temp/sub_tmp'
It seems the 'Xbmcfreak 10.08 svn livecd' doesn't support rarfiles at all.
It's not just the xbmc.extract function that doesn't work for rars but videofiles packed as rars are not recognized either.
XBMC should support rar files as it is one of the features according to this wiki page:
Quote:Supported physical input media formats and devices:
..
Stream media STORED, (NOT COMPRESSED) directly from RAR and ZIP archives
The windows-version has no problem with rar-files.
Since there is no official nightly build of live-cd's, I recommend asking the creator of the live-cd why there is no rar support in his live-cd.


- awarin - 2010-08-20

thanks alot. just confirmed it. I´ll ask him why he has removed support for compress files in .rar.

found this

http://forum.xbmc.org/showthread.php?tid=78867&highlight=rared+files

guess rar support is disabled in latest build


- matejdro - 2010-08-20

Podnapisi.net and OpenSubtitles are not working for me. Either they stuck at "Connecting..." or give no results even when manually typing movie name.

And many times i get Visual C++ Runtime error when try searching using those two. Until i click OK on error box everything is working without problems but when i click OK, it crashes. That is the only error i was able to found:

Quote:23:25:44 T:2140 M:1145970688 ERROR: CLocalizeStrings::ClearBlock: Trying to clear non existent block C:\Program Files (x86)\XBMC\portable_data\addons\script.xbmc.subtitles

Also i can't have both manual name and parent folder options enabled. If i enable both it just shows parent folder.

Can you add option to remove year brackets if there is no year? So it won't search for "Movie name ()"


- aptalca - 2010-08-22

Hi Amet,
First of all, thanks for the great addon

I was wondering if there is a way to have this addon automatically close/hide the OSD menu when it's done downloading the subtitles?

Right now, I am accessing this addon not using a button on the remote, but through the OSD menu in Transparency. So when I select a subtitle to download, the OSD is also open. After download, the addon window automatically closes and the video starts playing, but I still have the OSD that I have to manually close.

I know I am just being lazy, but isn't it what we are all trying to achieve here with xbmc, ultimate practicality for the ultimate lazy? Smile

Thanks


- amet - 2010-08-22

aptalca Wrote:Hi Amet,
First of all, thanks for the great addon

I was wondering if there is a way to have this addon automatically close/hide the OSD menu when it's done downloading the subtitles?

Right now, I am accessing this addon not using a button on the remote, but through the OSD menu in Transparency. So when I select a subtitle to download, the OSD is also open. After download, the addon window automatically closes and the video starts playing, but I still have the OSD that I have to manually close.

I know I am just being lazy, but isn't it what we are all trying to achieve here with xbmc, ultimate practicality for the ultimate lazy? Smile

Thanks


hehe, lazy... Smile

not sure if that is possible at all. will check it out.


- amet - 2010-08-22

matejdro Wrote:Also i can't have both manual name and parent folder options enabled. If i enable both it just shows parent folder.

if you have manual name search enabled it will bring the keyboard up, if you enable parent folder search it will just search by folder name.

the script works the best if your media is scanned in to the library

matejdro Wrote:Can you add option to remove year brackets if there is no year? So it won't search for "Movie name ()"

it only displays "()" but the search is done by "Movie name" not "Movie name ()". again, scanning the movies/shows into the library will get the most out of the script.


- matejdro - 2010-08-22

Thanks for explanation, i was testing with non-library movies to test how well it works. Any idea why podnapisi.net and opensubtitles are not working for me?


- amet - 2010-08-22

matejdro Wrote:Thanks for explanation, i was testing with non-library movies to test how well it works. Any idea why podnapisi.net and opensubtitles are not working for me?

opensubtitles takes a while on my side as well, I think their server is not coping with the requests.

Podnapisi.net works without issues for me, I use it daily. you have entered username/password for podnapisi.net?

please post a debug log, it might show us something


- matejdro - 2010-08-22

OpenSubtitles seems to work now, except that i need to wait like ten years for it to load.

Here is the debug file:

http://pastebin.com/5hz4XY27

I started playing movie from the library, then activated subtitles. Default option is subscene, so after search ended, i switched to podnapisi.net. No results.