From: Zac Medico Date: Wed, 11 Mar 2009 06:46:26 +0000 (-0000) Subject: Allow unicode type values in config.__setitem__(). Thanks to Arfrever Frehtes X-Git-Tag: v2.1.6.8~59 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=abdae9134752155162673cfee858ebe394cdaa54;p=portage.git Allow unicode type values in config.__setitem__(). Thanks to Arfrever Frehtes Taifersar Arahesis for this patch. (trunk r12774) svn path=/main/branches/2.1.6/; revision=13018 --- diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index 7a3a9f270..b59c16f20 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -2962,7 +2962,7 @@ class config(object): def __setitem__(self,mykey,myvalue): "set a value; will be thrown away at reset() time" - if not isinstance(myvalue, str): + if not isinstance(myvalue, basestring): raise ValueError("Invalid type being used as a value: '%s': '%s'" % (str(mykey),str(myvalue))) self.modifying() self.modifiedkeys += [mykey]