<commit_before>"""Two Way Ordered DICTionary for Python.

Attributes:
    _DEFAULT_OBJECT (object): Object that it's used as a default parameter.

"""

import sys
import collections


__all__ = ["TwoWayOrderedDict"]

__version__ = "1.1"

__license__ = "Unlicense"


_DEFAULT_OBJECT = object()


########## Custom views to mimic Python3 view objects ##########
# See: https://docs.python.org/3/library/stdtypes.html#dict-views

class DictKeysView(collections.KeysView):

    def __init__(self, data):
        super(DictKeysView, self).__init__(data)
        self.__data = data

    def __repr__(self):
        return "dict_keys({data})".format(data=list(self))

    def __contains__(self, key):
        return key in [key for key in self.__data]


class DictValuesView(collections.ValuesView):

    def __init__(self, data):
        super(DictValuesView, self).__init__(data)
        self.__data = data
<commit_msg>Bump version<commit_after>"""Two Way Ordered DICTionary for Python.

Attributes:
    _DEFAULT_OBJECT (object): Object that it's used as a default parameter.

"""

import sys
import collections


__all__ = ["TwoWayOrderedDict"]

__version__ = "1.2"

__license__ = "Unlicense"


_DEFAULT_OBJECT = object()


########## Custom views to mimic Python3 view objects ##########
# See: https://docs.python.org/3/library/stdtypes.html#dict-views

class DictKeysView(collections.KeysView):

    def __init__(self, data):
        super(DictKeysView, self).__init__(data)
        self.__data = data

    def __repr__(self):
        return "dict_keys({data})".format(data=list(self))

    def __contains__(self, key):
        return key in [key for key in self.__data]


class DictValuesView(collections.ValuesView):

    def __init__(self, data):
        super(DictValuesView, self).__init__(data)
        self.__data = data

{'fraction_non_alphanumeric': 0.1291735084838533, 'fraction_numerical': 0.004378762999452655, 'mean_word_length': 3.8617021276595747, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5641061', 'n_tokens_mistral': 585, 'n_tokens_neox': 562, 'n_words': 143}