OrderedDict copy method don't copy items order

Issue #1377 resolved
Anonymous created an issue

Hi,

Example :

    >>> from sqlalchemy.util import OrderedDict
    >>> my_ordered_dict = OrderedDict()
    >>> my_ordered_dict["zzz"]("zzz") = 1
    >>> my_ordered_dict["aaa"]("aaa") = 2
    >>> my_ordered_dict.keys()
    ['aaa']('zzz',)

    >>> copy_ordered_dict = my_ordered_dict.copy()
    >>> copy_ordered_dict.keys()
    ['zzz']('aaa',)

Error : OrderedDict copy method don't copy items order.

Regards, Stephane

Comments (3)

  1. Log in to comment