ports/125327: [PATCH] deskutils/gcalcli: fix unicode supporting
Yi-Jheng Lin
yzlin at cs.nctu.edu.tw
Sun Jul 6 05:30:09 UTC 2008
>Number: 125327
>Category: ports
>Synopsis: [PATCH] deskutils/gcalcli: fix unicode supporting
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Sun Jul 06 05:30:08 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator: Yi-Jheng Lin
>Release: FreeBSD 7.0-RELEASE-p1 amd64
>Organization:
NCTU CS
>Environment:
System: FreeBSD stucgi 7.0-RELEASE-p1 FreeBSD 7.0-RELEASE-p1 #0: Thu Apr 17 15:56:39 CST 2008
>Description:
[DESCRIBE CHANGES]
In Python's default setting, the default string encoding is 'ascii'. The gcalcli shows "UnicodeEncodeError" when dealing with non-ASCII strings.
This problem would occur when the event title or content includes non-ASCII characters.
I also sent this patch to the author, Eric Davis <insanum at gmail.com>, and hope it will be fixed in next release.
Added file(s):
- files/patch-gcalcli
Port maintainer (lwhsu at FreeBSD.org) is cc'd.
Generated with FreeBSD Port Tools 0.77
>How-To-Repeat:
>Fix:
--- gcalcli-1.4_1.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/deskutils/gcalcli/files/patch-gcalcli /amd/account/gcs/96/9655630/dev/ports/deskutils/gcalcli/files/patch-gcalcli
--- /usr/ports/deskutils/gcalcli/files/patch-gcalcli 1970-01-01 08:00:00.000000000 +0800
+++ /amd/account/gcs/96/9655630/dev/ports/deskutils/gcalcli/files/patch-gcalcli 2008-07-06 12:32:55.000000000 +0800
@@ -0,0 +1,33 @@
+--- gcalcli.orig 2008-07-06 12:29:27.000000000 +0800
++++ gcalcli 2008-07-06 12:31:38.000000000 +0800
+@@ -195,25 +195,25 @@
+ def PrintErrMsg(msg):
+ if CLR.useColor:
+ sys.stdout.write(str(CLR_BRRED()))
+- sys.stdout.write(msg)
++ sys.stdout.write(unicode(msg, 'UTF-8'))
+ sys.stdout.write(str(CLR_NRM()))
+ else:
+- sys.stdout.write(msg)
++ sys.stdout.write(unicode(msg, 'UTF-8'))
+
+
+ def PrintMsg(color, msg):
+ if CLR.useColor:
+ sys.stdout.write(str(color))
+- sys.stdout.write(msg)
++ sys.stdout.write(unicode(msg, 'UTF-8'))
+ sys.stdout.write(str(CLR_NRM()))
+ else:
+- sys.stdout.write(msg)
++ sys.stdout.write(unicode(msg, 'UTF-8'))
+
+
+ def DebugPrint(msg):
+ return
+ sys.stdout.write(str(CLR_YLW()))
+- sys.stdout.write(msg)
++ sys.stdout.write(unicode(msg, 'UTF-8'))
+ sys.stdout.write(str(CLR_NRM()))
+
+
--- gcalcli-1.4_1.patch ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list