zyronix / auto-sub

Automatically exported from code.google.com/p/auto-sub
0 stars 0 forks source link

Unicode bug, variable error #102

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
when processing my dir with episodes autosub crashes.

AutoSub: Initializing variables and loading config
AutoSub: Changing output to log. Bye!
[28/May/2012:20:01:08] ENGINE Serving on 0.0.0.0:8083
Traceback (most recent call last):
  File "/volume1/@appstore/auto-sub/autosub/Scheduler.py", line 21, in __init__
    self.command.run()
  File "/volume1/@appstore/auto-sub/autosub/scanDisk.py", line 35, in run
    for dirname, dirnames, filenames in os.walk(os.path.join(autosub.ROOTPATH)):
  File "/opt/lib/python2.6/os.py", line 294, in walk
    for x in walk(path, topdown, onerror, followlinks):
  File "/opt/lib/python2.6/os.py", line 294, in walk
    for x in walk(path, topdown, onerror, followlinks):
  File "/opt/lib/python2.6/os.py", line 284, in walk
    if isdir(join(top, name)):
  File "/opt/lib/python2.6/posixpath.py", line 70, in join
    path += '/' + b
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 35: 
ordinal not in range(128)

this is the log file of autosubservice:

2012-05-28 20:01:07,970 INFO  AutoSub: Starting threads
2012-05-28 20:01:07,976 INFO  AutoSub: Starting CherryPy webserver
2012-05-28 20:01:08,218 INFO  AutoSub: Starting scanDisk thread
2012-05-28 20:01:08,271 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E18 - Beware My Cheating Bart.mkv and added to wantedQueue
2012-05-28 20:01:08,276 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E22 - Lisa Goes Gaga.mkv and added to wantedQueue
2012-05-28 20:01:08,281 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E20 - The Spy Who Learned Me.mkv and added to wantedQueue
2012-05-28 20:01:08,286 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E15 - Exit Through the Kwik-E-Mart.mkv and added to wantedQueue
2012-05-28 20:01:08,291 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E16 - How I Wet Your Mother.mkv and added to wantedQueue
2012-05-28 20:01:08,296 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E14 - At Long Last Leave.mkv and added to wantedQueue
2012-05-28 20:01:08,301 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E17 - Them, Robot.mkv and added to wantedQueue
2012-05-28 20:01:08,306 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E13 - The Daughter Also Rises.mkv and added to wantedQueue
2012-05-28 20:01:08,312 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E19 - A Totally Fun Thing That Bart Will Never Do Again.mkv and added to 
wantedQueue
2012-05-28 20:01:08,317 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E21 - Ned 'N' Edna's Blend.mkv and added to wantedQueue

Original issue reported on code.google.com by Fighting...@gmail.com on 28 May 2012 at 6:05

GoogleCodeExporter commented 8 years ago
Hi Thanks for reporting the issue.
Which version of autosub are you using?

Original comment by romke.va...@gmail.com on 28 May 2012 at 6:48

GoogleCodeExporter commented 8 years ago
Hi,

this one was with 0.5.4 but ill have the same issue on 0.5.5. 

here is the error of version 0.5.5:

AutoSub: Initializing variables and loading config
AutoSub: Changing output to log. Bye!
[28/May/2012:21:54:20] ENGINE Serving on 0.0.0.0:8083
Traceback (most recent call last):
  File "/volume1/@appstore/auto-sub/autosub/Scheduler.py", line 21, in __init__
    self.command.run()
  File "/volume1/@appstore/auto-sub/autosub/scanDisk.py", line 101, in run
    walkDir(str(autosub.ROOTPATH))
  File "/volume1/@appstore/auto-sub/autosub/scanDisk.py", line 40, in walkDir
    srtfileeng = os.path.join(filename[:-4] + "." + autosub.SUBENG + ".srt")
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 34: 
ordinal not in range(128)

and this is in the log file:

2012-05-28 21:54:20,124 INFO  AutoSub: Starting threads
2012-05-28 21:54:20,129 INFO  AutoSub: Starting CherryPy webserver
2012-05-28 21:54:20,374 INFO  AutoSub: Starting scanDisk thread
2012-05-28 21:54:20,430 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E18 - Beware My Cheating Bart.mkv and added to wantedQueue
2012-05-28 21:54:20,435 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E22 - Lisa Goes Gaga.mkv and added to wantedQueue
2012-05-28 21:54:20,441 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E20 - The Spy Who Learned Me.mkv and added to wantedQueue
2012-05-28 21:54:20,447 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E15 - Exit Through the Kwik-E-Mart.mkv and added to wantedQueue
2012-05-28 21:54:20,452 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E16 - How I Wet Your Mother.mkv and added to wantedQueue
2012-05-28 21:54:20,458 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E14 - At Long Last Leave.mkv and added to wantedQueue
2012-05-28 21:54:20,463 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E17 - Them, Robot.mkv and added to wantedQueue
2012-05-28 21:54:20,468 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E13 - The Daughter Also Rises.mkv and added to wantedQueue
2012-05-28 21:54:20,476 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E19 - A Totally Fun Thing That Bart Will Never Do Again.mkv and added to 
wantedQueue
2012-05-28 21:54:20,481 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E21 - Ned 'N' Edna's Blend.mkv and added to wantedQueue
2012-05-28 21:54:20,520 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E18 - Beware My Cheating Bart.mkv and added to wantedQueue
2012-05-28 21:54:20,525 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E22 - Lisa Goes Gaga.mkv and added to wantedQueue
2012-05-28 21:54:20,530 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E20 - The Spy Who Learned Me.mkv and added to wantedQueue
2012-05-28 21:54:20,535 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E15 - Exit Through the Kwik-E-Mart.mkv and added to wantedQueue
2012-05-28 21:54:20,541 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E16 - How I Wet Your Mother.mkv and added to wantedQueue
2012-05-28 21:54:20,546 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E14 - At Long Last Leave.mkv and added to wantedQueue
2012-05-28 21:54:20,551 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E17 - Them, Robot.mkv and added to wantedQueue
2012-05-28 21:54:20,556 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E13 - The Daughter Also Rises.mkv and added to wantedQueue
2012-05-28 21:54:20,563 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E19 - A Totally Fun Thing That Bart Will Never Do Again.mkv and added to 
wantedQueue
2012-05-28 21:54:20,568 INFO  scanDir: Dutch subtitle wanted for The Simpsons - 
S23E21 - Ned 'N' Edna's Blend.mkv and added to wantedQueue
2012-05-28 21:54:20,589 INFO  scanDir: Dutch subtitle wanted for Hawaii Five-0 
- S02E03 - Kame'e.mkv and added to wantedQueue
2012-05-28 21:54:20,593 INFO  scanDir: Dutch subtitle wanted for Hawaii Five-0 
(2010) - S02E16 - I Helu Pu.mkv and added to wantedQueue
2012-05-28 21:54:20,598 INFO  scanDir: Dutch subtitle wanted for Hawaii Five-0 
- S02E08 - Lapa'au.mkv and added to wantedQueue
2012-05-28 21:54:20,603 INFO  scanDir: Dutch subtitle wanted for Hawaii Five-0 
- S02E07 - Ka Iwi Kapu.mkv and added to wantedQueue
2012-05-28 21:54:20,608 INFO  scanDir: Dutch subtitle wanted for Hawaii Five-0 
- S02E19 - Kalele.mkv and added to wantedQueue
2012-05-28 21:54:20,612 INFO  scanDir: Dutch subtitle wanted for Hawaii Five-0 
- S02E22 - Ua Hopu.mkv and added to wantedQueue

Original comment by Fighting...@gmail.com on 28 May 2012 at 7:57

GoogleCodeExporter commented 8 years ago
Ah k, got enough info to work on this issue. Thanks for reporting! I will try 
to fix this before the upcoming release.

Original comment by romke.va...@gmail.com on 29 May 2012 at 7:12

GoogleCodeExporter commented 8 years ago
Didn't had enough time to test and fixes this. A known workaround is there to 
search for a file containing a weird character and rename it. But I am finally 
able to reproduce this issue! :)

Original comment by romke.va...@gmail.com on 1 Jun 2012 at 6:26

GoogleCodeExporter commented 8 years ago
Issue 95 has been merged into this issue.

Original comment by romke.va...@gmail.com on 2 Jun 2012 at 10:10

GoogleCodeExporter commented 8 years ago
looking forward to the final sollution

Original comment by Fighting...@gmail.com on 2 Jun 2012 at 11:02

GoogleCodeExporter commented 8 years ago
Issue 106 has been merged into this issue.

Original comment by romke.va...@gmail.com on 9 Jun 2012 at 1:28

GoogleCodeExporter commented 8 years ago
Issue 135 has been merged into this issue.

Original comment by romke.va...@gmail.com on 8 Oct 2012 at 7:18

GoogleCodeExporter commented 8 years ago

Original comment by romke.va...@gmail.com on 8 Nov 2012 at 5:45

GoogleCodeExporter commented 8 years ago
Issue 157 has been merged into this issue.

Original comment by romke.va...@gmail.com on 3 Dec 2012 at 8:17

GoogleCodeExporter commented 8 years ago
Traceback (most recent call last):
  File "/opt/sybhttpd/localhost.drives/USB_DRIVE/Apps/autosub/autosub/Scheduler.py", line 21, in __init__
    self.command.run()
  File "/opt/sybhttpd/localhost.drives/USB_DRIVE/Apps/autosub/autosub/scanDisk.py", line 102, in run
    walkDir(str(autosub.ROOTPATH))
  File "/opt/sybhttpd/localhost.drives/USB_DRIVE/Apps/autosub/autosub/scanDisk.py", line 40, in walkDir
    srtfile = os.path.splitext(filename)[0] + u".srt"
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 63: 
ordinal not in range(128)

I think this is because the filename has a - in it. 'Re-entry'.

Original comment by carstenk...@gmail.com on 9 Dec 2012 at 3:26

GoogleCodeExporter commented 8 years ago
Same issue here

Original comment by bliz...@gmail.com on 23 Dec 2012 at 2:46

GoogleCodeExporter commented 8 years ago
[/share/HDA_DATA/.qpkg/auto-sub] # python AutoSub.py
AutoSub: Initializing variables and loading config
AutoSub: Starting output to log. Bye!
[24/Feb/2013:22:09:45] ENGINE Serving on 0.0.0.0:8003
Traceback (most recent call last):
  File "/share/HDA_DATA/.qpkg/auto-sub/autosub/Scheduler.py", line 21, in __init__
    self.command.run()
  File "/share/HDA_DATA/.qpkg/auto-sub/autosub/scanDisk.py", line 102, in run
    walkDir(str(autosub.ROOTPATH))
  File "/share/HDA_DATA/.qpkg/auto-sub/autosub/scanDisk.py", line 38, in walkDir
    srtfile = os.path.splitext(filename)[0] + u"." + autosub.SUBNL + u".srt"
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 21: 
ordinal not in range(128)

Same problem here. This is after setting the TV download dir and restarting. 

Original comment by michelb...@gmail.com on 24 Feb 2013 at 10:11

GoogleCodeExporter commented 8 years ago

Original comment by romke.va...@gmail.com on 19 Apr 2013 at 5:16

GoogleCodeExporter commented 8 years ago
Issue 190 has been merged into this issue.

Original comment by romke.va...@gmail.com on 12 May 2013 at 12:55

GoogleCodeExporter commented 8 years ago
Issue 191 has been merged into this issue.

Original comment by romke.va...@gmail.com on 15 May 2013 at 7:20

GoogleCodeExporter commented 8 years ago

Original comment by romke.va...@gmail.com on 20 Jun 2013 at 1:01

GoogleCodeExporter commented 8 years ago
Hai, same here, i attached my script, its a nicer way for auto-subs startup.
( its a copy of sabnzbdplus script ) 

I only have the error at boot, afer boot, i login and manualy start it up and 
it words. 
This looks like a coding problem, so the simpel solution is which locales is 
needed as default, of which locales is this programmed in. 

If we are able to set the locale in the startup script, than its fixed i think.

Original comment by thc...@gmail.com on 23 Aug 2013 at 7:05

Attachments:

GoogleCodeExporter commented 8 years ago
( correction of the startup script, this should be in it. 
# Required-Start:    $local_fs $network
# Required-Stop:     $local_fs $network

Original comment by thc...@gmail.com on 23 Aug 2013 at 7:08

GoogleCodeExporter commented 8 years ago
Hi there i also got the same problem and don't know how to fix it.
her's the error log:

[root@zfsguru /home/ssh]# service autosub onestart
Starting autosub.
[root@zfsguru /home/ssh]# AutoSub: Initializing variables and loading config
AutoSub: Starting output to log. Bye!
[28/Aug/2013:18:11:17] ENGINE Serving on 0.0.0.0:8083
Traceback (most recent call last):
  File "/schijf1/zfsguru/services/9.1-006/sabnzbdplus/data/autosub/autosub/Sched
uler.py", line 21, in __init__
    self.command.run()
  File "/schijf1/zfsguru/services/9.1-006/sabnzbdplus/data/autosub/autosub/scanD
isk.py", line 106, in run
    walkDir(str(autosub.ROOTPATH))
  File "/schijf1/zfsguru/services/9.1-006/sabnzbdplus/data/autosub/autosub/scanD
isk.py", line 42, in walkDir
    srtfile = os.path.splitext(filename)[0] + u"." + autosub.SUBNL + u".srt"
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 20: ordinal
 not in range(128)

Original comment by ikkeenji...@gmail.com on 28 Aug 2013 at 6:11