<commit_before>import sys

if sys.version_info.major == 3:
    long = int


class Flag(long):
    def __new__(cls, name, value):
        return super(Flag, cls).__new__(cls, value)

    def __init__(self, name, value):
        self.name = name

    def __repr__(self):
        return "{0}({1})".format(self.name, hex(self))

    __str__ = __repr__

   # Fix pickling with protocol 2
    def __getnewargs__(self, *args):
        return self.name, long(self)


class StrFlag(str):
    def __new__(cls, name, value):
        if isinstance(value, cls):
            return value
        return super(StrFlag, cls).__new__(cls, value)<commit_msg>Flag repr does not print long 'L' at the end of hex value<commit_after>import sys

if sys.version_info.major == 3:
    long = int


class Flag(long):
    def __new__(cls, name, value):
        return super(Flag, cls).__new__(cls, value)

    def __init__(self, name, value):
        self.name = name

    def __repr__(self):
        return "{0}({1:#x})".format(self.name, self)

    __str__ = __repr__

   # Fix pickling with protocol 2
    def __getnewargs__(self, *args):
        return self.name, long(self)


class StrFlag(str):
    def __new__(cls, name, value):
        if isinstance(value, cls):
            return value
        return super(StrFlag, cls).__new__(cls, value)
{'fraction_non_alphanumeric': 0.12102874432677761, 'fraction_numerical': 0.006051437216338881, 'mean_word_length': 2.7908309455587395, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, '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': '5756421', 'n_tokens_mistral': 441, 'n_tokens_neox': 425, 'n_words': 123}