Release - service.subtitles.subscene

  Thread Rating:
  • 5 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
Momberg Offline
Junior Member
Posts: 11
Joined: Aug 2014
Reputation: 0
Post: #136
Hey CrowleyAJ.

i have some trouble with the subscene addon as it only return a script error when trying to get a list of subs.

here is the debug log as you usually request it when people have trouble : http://xbmclogs.com/show.php?id=427916
also of what i can see the problem is around line 1054, just to make it easier for you just in case.

thank you for your support for this app, and keep up the good work Smile
find quote
CrowleyAJ Offline
Member
Posts: 70
Joined: Aug 2013
Reputation: 4
Post: #137
Hi kaitaba and Momberg,
I'm not quite sure how to handle that issue, since I can't reproduce it on my system. It seems to only affect OpenELEC installations.
I made a new test version. Could you please install that zip file an tell me if it helps?
https://github.com/manacker/service.subt...master.zip
find quote
kataiba Offline
Junior Member
Posts: 35
Joined: Oct 2012
Reputation: 0
Location: London
Post: #138
I've installed your github version and now i can search fine everything appears but when i try downloading i get script failed and failed to download subtitle log here thank you

[Image: all-thin-banner.jpg]
(This post was last modified: 2015-02-16 20:43 by kataiba.)
find quote
CrowleyAJ Offline
Member
Posts: 70
Joined: Aug 2013
Reputation: 4
Post: #139
Hi kataiba, thanks for your assistance. I think we're getting there. Would you please get the current version from github and try again?
find quote
Momberg Offline
Junior Member
Posts: 11
Joined: Aug 2014
Reputation: 0
Post: #140
Hi crowleyAJ

Thank You for looking in to it that fast.
Although I'm a novice in kodi/xbmc/openelec I'll try to install it. If I can make the time I will do it tomorrow.
find quote
kataiba Offline
Junior Member
Posts: 35
Joined: Oct 2012
Reputation: 0
Location: London
Post: #141
Hi CrowleyAJ. I've installed the latest github release and getting same errors as before . Log. Thank you

[Image: all-thin-banner.jpg]
find quote
Momberg Offline
Junior Member
Posts: 11
Joined: Aug 2014
Reputation: 0
Post: #142
hi again.

sorry for the long wait. had alot to do the last couple of days and had trouble with xbmc log uploader app.

here is the new log. atleast i think this is the one. i had to upload it manually and im not sure i have chosen the correct language (chose python)
http://xbmclogs.com/pe3rvl7wy
its there for a week from now.
find quote
Momberg Offline
Junior Member
Posts: 11
Joined: Aug 2014
Reputation: 0
Post: #143
it starts at line 1217
find quote
kooroshtaha Offline
Junior Member
Posts: 2
Joined: Feb 2015
Reputation: 0
Post: #144
Hey CrowleyAJ.

i have some trouble with the subscene addon as it only return a script error when trying to get a list of subs.

it was working well but sense last week it dose not working at all.

thank you for your support for this app, and keep up the good work Smile
find quote
CrowleyAJ Offline
Member
Posts: 70
Joined: Aug 2013
Reputation: 4
Post: #145
Hi kooroshtaha,

as always, I have to ask you for a debug log (wiki). Also it would help if you describe your setup a bit. What distribution are you using, on what hardware.
I'm still struggling to fix some issues on OpenELEC and couldn't reproduce them yet.
find quote
Momberg Offline
Junior Member
Posts: 11
Joined: Aug 2014
Reputation: 0
Post: #146
hey crowleyAJ.

please tell me if you need a new debug log to adress the problems on openelec.
i hasve installed the zip as you suggested as in my previous debug log.

thanks again.
find quote
parcel Offline
Junior Member
Posts: 1
Joined: Mar 2015
Reputation: 0
Post: #147
There is a unicode relate error at log(...), it simply fixed by removing that. script line 369.
And fix invalid subtitle file is assigned at zip file archive type downloading.

(edit) more correction in file time comparision.
(edit) create unique filename based on url.

Code:
--- E:/download/service.subtitles.subscene-master/service.py    Mon Feb 16 12:34:02 2015
+++ E:/download/service.subtitles.subscene-master/service.subtitles.subscene-master/service.py    Sun Mar 15 11:28:36 2015
@@ -14,6 +14,7 @@
import string
import difflib
import HTMLParser
+import time

__addon__ = xbmcaddon.Addon()
__author__ = __addon__.getAddonInfo('author')
@@ -289,6 +290,13 @@
     downloadlink_pattern = "...<a href=\"(.+?)\" rel=\"nofollow\" onclick=\"DownloadSubtitle"

     content, response_url = geturl(link)
+    # get unique name of file based on link
+    base_file_idx = link.rfind('/')
+    if base_file_idx != -1:
+        local_base_file = link[base_file_idx+1:]
+    else:
+        local_base_file = "subscene"
+
     match = re.compile(downloadlink_pattern).findall(content)
     if match:
         downloadlink = main_url + match[0]
@@ -319,7 +327,7 @@
                 shutil.rmtree(__temp__.encode('utf-8'))
         xbmcvfs.mkdirs(__temp__)

-        local_tmp_file = os.path.join(__temp__, "subscene.xxx")
+        local_tmp_file = os.path.join(__temp__, local_base_file + ".xxx")
         packed = False

         try:
@@ -346,8 +354,8 @@
                     packed = False
                     log(__name__, "Discovered a non-archive file")
             myfile.close()
-            local_tmp_file = os.path.join(__temp__, "subscene." + typeid)
-            os.rename(os.path.join(__temp__, "subscene.xxx"), local_tmp_file)
+            local_tmp_file = os.path.join(__temp__, local_base_file + "." + typeid)
+            os.rename(os.path.join(__temp__, local_base_file + ".xxx"), local_tmp_file)
             log(__name__, "Saving to %s" % local_tmp_file)
         except:
             log(__name__, "Failed to save subtitle to %s" % local_tmp_file)
@@ -356,6 +364,8 @@
             xbmc.sleep(500)
             xbmc.executebuiltin(('XBMC.Extract("%s","%s")' % (local_tmp_file, __temp__,)).encode('utf-8'), True)

+        packfile_time = os.stat(local_tmp_file).st_mtime
+
         for file in xbmcvfs.listdir(__temp__)[1]:
             if sys.platform.startswith('win'):
                 file = os.path.join(__temp__, file)
@@ -364,8 +374,10 @@
             if os.path.splitext(file)[1] in exts:
                 if search_string and string.find(string.lower(file), string.lower(search_string)) == -1:
                     continue
-                log(__name__, "=== returning subtitle file %s" % file)
-                subtitle_list.append(file)
+                ## log(__name__, "=== returning subtitle file %s" % file.decode('utf-8'))
+                cfile_time = os.stat(file).st_mtime
+                if cfile_time >= packfile_time and cfile_time <= time.time():
+                    subtitle_list.append(file)

         if len(subtitle_list) == 0:
             if search_string:

service.subtitles.subscene-master_(12).zip
(This post was last modified: 2015-03-15 04:50 by parcel.)
find quote
kooroshtaha Offline
Junior Member
Posts: 2
Joined: Feb 2015
Reputation: 0
Post: #148
(2015-02-27 17:36)CrowleyAJ Wrote:  Hi kooroshtaha,

as always, I have to ask you for a debug log (wiki). Also it would help if you describe your setup a bit. What distribution are you using, on what hardware.
I'm still struggling to fix some issues on OpenELEC and couldn't reproduce them yet.

HI CrowleyAj.

thanks for your answer,i found something about how should i fix it and it worked.
File manager: profile directory/addon_data/service.subtitles.subscene/temp

in this location delete all the information there

cheers .
(This post was last modified: 2015-03-15 15:30 by kooroshtaha.)
find quote
ztrust Offline
Senior Member
Posts: 166
Joined: Sep 2013
Reputation: 0
Post: #149
hey
for the longest time NCIS subtitle search comes back as family guy ?
just to report
find quote
CrowleyAJ Offline
Member
Posts: 70
Joined: Aug 2013
Reputation: 4
Post: #150
Hi ztrust,

can you provide a debug log (wiki) please?
find quote
Post Reply