Modify

Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#8459 closed defect (duplicate)

error under Japanese environment

Reported by: okamototk Owned by: Takanori Suzuki
Priority: high Component: WorkflowEditorPlugin
Severity: major Keywords:
Cc: Trac Release: 0.12

Description

Thansk for nice plugin.

I tried workfloweditor with trac0.12 and ubuntu. Then encording error occured.

Use utf-8 instead of internal encoding fixed this problem.

diff -r 9647cfe2514c resource/plugins/workfloweditorplugin/workfloweditor/workfloweditor_admin.py
--- a/resource/plugins/workfloweditorplugin/workfloweditor/workfloweditor_admin.py      Sun Jan 30 09:10:20 2011 +0900
+++ b/resource/plugins/workfloweditorplugin/workfloweditor/workfloweditor_admin.py      Wed Feb 02 07:48:41 2011 +0900
@@ -118,7 +118,7 @@
         stream = template.generate()
         default_config = stream.render('text')
         
-        page_param['workflow_default_config'] = default_config
+        page_param['workflow_default_config'] = default_config.decode('utf-8')
 
 
 class WorkflowChangeHandler(Component):

best reagards,

Takaashi Okamoto

Attachments (0)

Change History (7)

comment:1 Changed 14 years ago by okamototk

Resolution: invalid
Status: newclosed

Sorry, I lost sitecustomize.py configuration for ubuntu.

When I add following description at /etc/python2.6/sitecustomize.py, workfloweditorplugin work fine.

import sys, os
sys.setdefaultencoding("utf8")

best regards,

Takashi Okamoto

comment:2 in reply to:  1 Changed 14 years ago by Jun Omae

Replying to okamototk:

Sorry, I lost sitecustomize.py configuration for ubuntu.

When I add following description at /etc/python2.6/sitecustomize.py, workfloweditorplugin work fine.

The user must change sitecustomize.py? I think that it is not good.

The same issue has been reported. I have posted the another patch. comment:ticket:5901:1.

comment:3 Changed 14 years ago by Ryan J Ollos

Resolution: invalid
Status: closedreopened

comment:4 Changed 14 years ago by Ryan J Ollos

Resolution: duplicate
Status: reopenedclosed

Duplicate of #5901.

comment:5 Changed 14 years ago by Ryan J Ollos

I'm going to apply the patch in #5901, but I'm having trouble reproducing the issue, so if someone can send the specific workflow test that reproduces the error, that would be a big help. Please test the latest checkin as well.

comment:6 Changed 14 years ago by Ryan J Ollos

(In [9976]) Fixed UnicodeDecode error. Thanks to jun66j5 for the patch. Refs #5901, #8459.

comment:7 Changed 14 years ago by Ryan J Ollos

(In [9977]) Merge [9976] into 0.11 branch. Fixes #5901. Refs #8459.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Takanori Suzuki.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.