[ python-Bugs-1036490 ] unicode strings cannot be dictionary keys

SourceForge.net noreply at sourceforge.net
Tue Sep 28 22:35:39 CEST 2004


Bugs item #1036490, was opened at 2004-09-28 15:50
Message generated for change (Comment added) made by goodger
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1036490&group_id=5470

Category: Unicode
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Morten Kjeldgaard (mok0)
Assigned to: M.-A. Lemburg (lemburg)
Summary: unicode strings cannot be dictionary keys

Initial Comment:
Lots of modules return unicode strings, for example the
xml parser. There is no reason why you shouldn't be
able to use a unicode string as key in a dictionary,
shelve or database lookup. I think this is more a bug
than a feature, since having to make sure what type
your keys are makes the code bloated and ugly.



----------------------------------------------------------------------

>Comment By: David Goodger (goodger)
Date: 2004-09-28 16:35

Message:
Logged In: YES 
user_id=7733

Unicode strings work as dictionary keys for me, in both
Python 2.3.3 and 2.4a3.  Are you sure of your assertion? 
Please provide some evidence.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1036490&group_id=5470


More information about the Python-bugs-list mailing list