UnicodeEncodeError since upgrading to 0.55

Report & discuss bugs found in SABnzbd
Forum rules
Help us help you:
  • Are you using the latest stable version of SABnzbd? Downloads page.
  • Tell us what system you run SABnzbd on.
  • Adhere to the forum rules.
  • Do you experience problems during downloading?
    Check your connection in Status and Interface settings window.
    Use Test Server in Config > Servers.
    We will probably ask you to do a test using only basic settings.
  • Do you experience problems during repair or unpacking?
    Enable +Debug logging in the Status and Interface settings window and share the relevant parts of the log here using [ code ] sections.
Post Reply
cliffi
Newbie
Newbie
Posts: 3
Joined: November 9th, 2010, 4:33 pm

UnicodeEncodeError since upgrading to 0.55

Post by cliffi »

Version: 0.55
OS: Windows XP Pro Sp3
Install-type: Windows installer
Skin (if applicable): Plush
Firewall Software: None
Are you using IPV6? no

Since upgrading from 0.54 to 0.55 i get an Postprocessing Error with every file i download. Here some lines from the logfile.
Downgrading (installing in the same Directory) to 0.54 solves the problem. Any Ideas?

2010-11-09 21:59:42,809::ERROR::[postproc:441] Nachbearbeitung von colin hay fehlgeschlagen
2010-11-09 21:59:42,809::INFO::[postproc:444] Traceback:
Traceback (most recent call last):
  File "sabnzbd\postproc.pyo", line 409, in run
  File "sabnzbd\emailer.pyo", line 171, in endjob
  File "Cheetah\Template.pyo", line 1229, in __init__
  File "Cheetah\Template.pyo", line 1523, in _compile
  File "Cheetah\Template.pyo", line 782, in compile
UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 4158: ordinal not in range(128)
2010-11-09 21:59:42,920::INFO::[postproc:470] Cleaning up colin hay
2010-11-09 21:59:42,950::INFO::[postproc:134] Saving postproc queue
2010-11-09 21:59:42,950::INFO::[downloader:357] Post-processing finished, resuming download
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: UnicodeEncodeError since upgrading to 0.55

Post by shypike »

Every download? Sounds a bit unlikely.
Any specific NZB? Because such issues usually have to do with files containing non US-ASCII characters.
Do you have German as skin language?
cliffi
Newbie
Newbie
Posts: 3
Joined: November 9th, 2010, 4:33 pm

Re: UnicodeEncodeError since upgrading to 0.55

Post by cliffi »

yes, every download since the update, but the Downloads are ok, i just dont get an email anymore.
I just check out the Skin language.

edit: skin is plush-aqua, language is german

just did a simple check with a simple mp3, same behaviour:


2010-11-09 22:53:58,309::INFO::[postproc:315] Running unpack_magic on mp3-2
2010-11-09 22:53:58,309::INFO::[postproc:317] unpack_magic finished on mp3-2
2010-11-09 22:53:58,325::ERROR::[postproc:441] Nachbearbeitung von mp3-2 fehlgeschlagen
2010-11-09 22:53:58,341::INFO::[postproc:444] Traceback:
Traceback (most recent call last):
 File "sabnzbd\postproc.pyo", line 409, in run
 File "sabnzbd\emailer.pyo", line 171, in endjob
 File "Cheetah\Template.pyo", line 1229, in __init__
 File "Cheetah\Template.pyo", line 1523, in _compile
 File "Cheetah\Template.pyo", line 782, in compile
UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 4154: ordinal not in range(128)
2010-11-09 22:53:58,450::INFO::[postproc:470] Cleaning up mp3-2
2010-11-09 22:53:58,450::INFO::[postproc:134] Saving postproc queue
2010-11-09 22:53:58,450::INFO::[downloader:357] Post-processing finished, resuming download

Edit2: after disabling of the Email Notification i dont get no error anymore.

is that helpfull in any way?

okok, a last Edit for today: thats the output of trying to send a testmail:

500 Internal Server Error

The server encountered an unexpected condition which prevented it from fulfilling the request.

Traceback (most recent call last):
  File "cherrypy\_cprequest.pyo", line 618, in respond
  File "cherrypy\_cpdispatch.pyo", line 25, in __call__
  File "sabnzbd\interface.pyo", line 2568, in testmail
  File "sabnzbd\emailer.pyo", line 171, in endjob
  File "Cheetah\Template.pyo", line 1229, in __init__
  File "Cheetah\Template.pyo", line 1523, in _compile
  File "Cheetah\Template.pyo", line 782, in compile
UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 4158: ordinal not in range(128)
Last edited by cliffi on November 9th, 2010, 5:15 pm, edited 1 time in total.
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: UnicodeEncodeError since upgrading to 0.55

Post by shypike »

OK, that's useful info.
It looks like the creation of the email is crashing.
Because you have German as skin language it will pick a German email template.
You make a work-around by overwriting the file "c:\program files\SABnzbd\language\email-de-de.tmpl"
with the file "c:\program files\SABnzbd\language\email-us-en.tmpl".
This will make your email English again.

I think I know enough to fix this.
cliffi
Newbie
Newbie
Posts: 3
Joined: November 9th, 2010, 4:33 pm

Re: UnicodeEncodeError since upgrading to 0.55

Post by cliffi »

ok, here the log with the german template:
2010-11-09 23:07:25,982::INFO::[interface:2561] Sending testmail
2010-11-09 23:07:25,997::INFO::[_cplogging:55] [09/Nov/2010:23:07:25] HTTP .. more stuff
2010-11-09 23:07:25,997::DEBUG::[_cplogging:55] [09/Nov/2010:23:07:25] HTTP Traceback (most recent call last):
  File "cherrypy\_cprequest.pyo", line 618, in respond
  File "cherrypy\_cpdispatch.pyo", line 25, in __call__
  File "sabnzbd\interface.pyo", line 2568, in testmail
  File "sabnzbd\emailer.pyo", line 171, in endjob
  File "Cheetah\Template.pyo", line 1229, in __init__
  File "Cheetah\Template.pyo", line 1523, in _compile
  File "Cheetah\Template.pyo", line 782, in compile
UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 4158: ordinal not in range(128)

and switching to english, as u said:
2010-11-09 23:11:45,825::INFO::[interface:2561] Sending testmail
2010-11-09 23:11:49,482::INFO::[emailer:114] Notification e-mail succesfully sent


this works for me, thanks for your fast help!! and keep up the good work!!!
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: UnicodeEncodeError since upgrading to 0.55

Post by shypike »

The cause is a bug in the Cheetah module we use to handle the email templates.
I upgraded the module and the problem is gone.
The fix will be included in 0.5.6 (within a week or so).
andypandyswe
Newbie
Newbie
Posts: 10
Joined: May 14th, 2012, 2:46 am

Re: UnicodeEncodeError since upgrading to 0.55

Post by andypandyswe »

Hijacking this thread as I have a similar problem.
I'm not getting this error for all NZB's, only a few.

The error messages say it's an empty NZB
When I try to run the NZB again from the queue I get:


Traceback (most recent call last):
File "/volume1/@appstore/sab2/SABnzbd-0.6.15/cherrypy/_cprequest.py", line 618, in respond
cherrypy.response.body = self.handler()
File "/volume1/@appstore/sab2/SABnzbd-0.6.15/cherrypy/_cpdispatch.py", line 25, in __call__
return self.callable(*self.args, **self.kwargs)
File "/volume1/@appstore/sab2/SABnzbd-0.6.15/sabnzbd/interface.py", line 426, in retry
del_hist_job(job, del_files=True)
File "/volume1/@appstore/sab2/SABnzbd-0.6.15/sabnzbd/api.py", line 1413, in del_hist_job
remove_all(path, recursive=True)
File "/volume1/@appstore/sab2/SABnzbd-0.6.15/sabnzbd/misc.py", line 1155, in remove_all
if os.path.exists(path):
File "/var/packages/baseutils/target/utils/lib/python2.6/genericpath.py", line 18, in exists
st = os.stat(path)
UnicodeEncodeError: 'ascii' codec can't encode character u'\xf6' in position 35: ordinal not in range(128)

But this morning I tried yet again, got the same error message but the file started downloading...

I have swedish language but have made no changes to any skin-settings. Running on Synology DS1512+
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: UnicodeEncodeError since upgrading to 0.55

Post by shypike »

Do the NZB names have accented characters?
andypandyswe
Newbie
Newbie
Posts: 10
Joined: May 14th, 2012, 2:46 am

Re: UnicodeEncodeError since upgrading to 0.55

Post by andypandyswe »

No, doesn't appear to be... Can I send you some log entries?

Any help is greatly appreciated.

Regards

Andy
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: UnicodeEncodeError since upgrading to 0.55

Post by shypike »

Sure, preferably also the problematic NZB files.
[email protected]
Please also add the URl of this post.
andypandyswe
Newbie
Newbie
Posts: 10
Joined: May 14th, 2012, 2:46 am

Re: UnicodeEncodeError since upgrading to 0.55

Post by andypandyswe »

Ok, sorry I already PM'ed you... I'll try and put it together when I get home.

/A
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: UnicodeEncodeError since upgrading to 0.55

Post by shypike »

The earlier poster had an issue with email templates.
Does the problem occur at the end of a job, when trying to send an email?
You'll see that I said that the Cheetah module was the cause of the problem.
Now for complete packages for OSX and Windows, we control which software is used,
so for those the issue has been solved a long time ago.
On embedded platforms we have no control.
It looks like you're using an "embedded" system (like a NAS).
Where did you get the required Python and its modules?
Are you using a ready-made package?
Post Reply