UTF encoding problem in 0.8beta1

Questions and bug reports for Beta releases should be posted here.
Forum rules
Help us help you:
  • 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
bcsc
Newbie
Newbie
Posts: 3
Joined: October 23rd, 2015, 7:36 am

UTF encoding problem in 0.8beta1

Post by bcsc »

After I change to the chinese language, there sames to be a prolem:
Maybe the mail template for chinese in utf-8 was not fit.

I clicked "test email" but failed:

Code: Select all

2015-10-23 20:25:53,364::INFO::[api:694] Sending testmail
2015-10-23 20:25:53,369::INFO::[_cplogging:216] [23/Oct/2015:20:25:53] HTTP 
Request Headers:
  REFERER: http://localhost:8080/sabnzbd/config/notify/
  HOST: localhost:8080
  CONNECTION: keep-alive
  Remote-Addr: ::1
  ACCEPT: */*
  USER-AGENT: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.155 Safari/537.36
  X-REQUESTED-WITH: XMLHttpRequest
  ACCEPT-LANGUAGE: zh-CN,zh;q=0.8
  ACCEPT-ENCODING: gzip, deflate, sdch
  COOKIE: plushQueuePerPage=9999999; plushHistPerPage=9999999; smplrefresh=5; plushContainerWidth=100%25; plushMultiOps=1; plushNoTopMenu=0; plushContainerWidth=100%25; plushMultiOps=1; plushNoTopMenu=0; plushHistPerPage=9999999
2015-10-23 20:25:53,369::ERROR::[_cplogging:216] [23/Oct/2015:20:25:53] HTTP 
Traceback (most recent call last):
  File "cherrypy\_cprequest.pyo", line 670, in respond
  File "cherrypy\lib\encoding.pyo", line 217, in __call__
  File "cherrypy\_cpdispatch.pyo", line 61, in __call__
  File "sabnzbd\interface.pyo", line 420, in tapi
  File "sabnzbd\api.pyo", line 100, in api_handler
  File "sabnzbd\api.pyo", line 701, in _api_test_email
  File "sabnzbd\emailer.pyo", line 254, in endjob
  File "sabnzbd\emailer.pyo", line 208, in send_with_template
  File "Cheetah\Template.pyo", line 1259, in __init__
  File "Cheetah\Template.pyo", line 1553, in _compile
  File "Cheetah\Template.pyo", line 743, in compile
  File "Cheetah\Compiler.pyo", line 1660, in compile
  File "Cheetah\Parser.pyo", line 1489, in parse
  File "Cheetah\Parser.pyo", line 1613, in eatDirective
  File "Cheetah\Parser.pyo", line 2587, in eatIf
  File "Cheetah\Parser.pyo", line 1159, in getExpressionParts
ParseError: 

Line ending expected
Line 12, column 41

Line|Cheetah Code
----|-------------------------------------------------------------
9   |To: $to
10  |From: $from
11  |Date: $date
12  |Subject: SABnzbd 已<!--#if $status then \"完成\" else \"失败\" #-->任务 $name
                                             ^
13  |X-priority: 5
14  |X-MS-priority: 5
15  |## 到主体部分时,必须要有空行!

BUT it works fine when I changed to EN.
Last edited by bcsc on October 23rd, 2015, 9:23 am, edited 1 time in total.
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: UTF encoding problem in 0.8beta1

Post by shypike »

I'll test, but my Chinese is very bad :(
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: UTF encoding problem in 0.8beta1

Post by shypike »

The Chinese translator made a few typos in the email templates.
Will be fixed in Beta2.
Thanks for the tip.
Post Reply