FreeBSD Bugzilla – Attachment 205321 Details for
Bug 238543
www/pycarddav: Syncing a contact with UTF-8 characters fails
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
svn diff to include Oliver's patch in the port
py27-pycarddav-0.7.0_2.diff (text/plain), 2.37 KB, created by
Samir Noir
on 2019-06-25 05:27:41 UTC
(
hide
)
Description:
svn diff to include Oliver's patch in the port
Filename:
MIME Type:
Creator:
Samir Noir
Created:
2019-06-25 05:27:41 UTC
Size:
2.37 KB
patch
obsolete
>Index: Makefile >=================================================================== >--- Makefile (revision 505070) >+++ Makefile (working copy) >@@ -2,7 +2,7 @@ > > PORTNAME= pycarddav > PORTVERSION= 0.7.0 >-PORTREVISION= 1 >+PORTREVISION= 2 > CATEGORIES= www python > MASTER_SITES= CHEESESHOP > PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} >Index: files/patch-pycarddav_model.py >=================================================================== >--- files/patch-pycarddav_model.py (nonexistent) >+++ files/patch-pycarddav_model.py (working copy) >@@ -0,0 +1,46 @@ >+--- pycarddav/model.py.orig 2014-02-04 23:38:46 UTC >++++ pycarddav/model.py >+@@ -27,6 +27,7 @@ The pycarddav abstract model and tools for VCard handl >+ from __future__ import print_function >+ >+ import base64 >++import chardet >+ import logging >+ import sys >+ from collections import defaultdict >+@@ -197,8 +198,17 @@ class VCard(defaultdict): >+ >+ @property >+ def name(self): >+- return unicode(self['N'][0][0]) if self['N'] else '' >++ #return unicode(self['N'][0][0]) if self['N'] else '' >++ if self['N']: >++ if type(self['N'][0][0]) is unicode: >++ return self['N'][0][0] >++ else: >++ return unicode(self['N'][0][0], chardet.detect(self['N'][0][0])['encoding']) >++ else: >++ return '' >+ >++ #return unicode(self['N'][0][0], chardet.detect(self['N'][0][0])['encoding']) if self['N'] else '' >++ >+ @name.setter >+ def name(self, value): >+ if not self['N']: >+@@ -207,7 +217,14 @@ class VCard(defaultdict): >+ >+ @property >+ def fname(self): >+- return unicode(self['FN'][0][0]) if self['FN'] else '' >++ #return unicode(self['FN'][0][0]) if self['FN'] else '' >++ if self['FN']: >++ if type(self['FN'][0][0]) is unicode: >++ return self['FN'][0][0] >++ else: >++ return unicode(self['FN'][0][0], chardet.detect(self['FN'][0][0])['encoding']) >++ else: >++ return '' >+ >+ @fname.setter >+ def fname(self, value): >+ > >Property changes on: files/patch-pycarddav_model.py >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
samir
:
maintainer-approval+
Actions:
View
|
Diff
Attachments on
bug 238543
:
205028
| 205321 |
205686