<commit_before>from __future__ import print_function
from __future__ import absolute_import

# System modules
import sys

# Third-party modules
import six

# LLDB Modules
import lldb
from .lldbtest import *
from . import lldbutil

if sys.platform.startswith('win32'):
    # llvm.org/pr22274: need a pexpect replacement for windows
    class PExpectTest(object):
        pass
else:
    import pexpect

    class PExpectTest(TestBase):

        NO_DEBUG_INFO_TESTCASE = True
        PROMPT = "(lldb) "

        def expect_prompt(self):
            self.child.expect_exact(self.PROMPT)

        def launch(self, executable=None, timeout=30, dimensions=None):
            logfile = sys.stdout.buffer if self.TraceOn() else None
            args = ['--no-lldbinit', '--no-use-colors']
            for cmd in self.setUpCommands():<commit_msg>[test] Make sys.stdout compatible with both Python 2 & 3<commit_after>from __future__ import print_function
from __future__ import absolute_import

# System modules
import sys

# Third-party modules
import six

# LLDB Modules
import lldb
from .lldbtest import *
from . import lldbutil

if sys.platform.startswith('win32'):
    # llvm.org/pr22274: need a pexpect replacement for windows
    class PExpectTest(object):
        pass
else:
    import pexpect

    class PExpectTest(TestBase):

        NO_DEBUG_INFO_TESTCASE = True
        PROMPT = "(lldb) "

        def expect_prompt(self):
            self.child.expect_exact(self.PROMPT)

        def launch(self, executable=None, timeout=30, dimensions=None):
            logfile = getattr(sys.stdout, 'buffer',
                              sys.stdout) if self.TraceOn() else None
            args = ['--no-lldbinit', '--no-use-colors']
            for cmd in self.setUpCommands():
{'fraction_non_alphanumeric': 0.09157716223855286, 'fraction_numerical': 0.011305822498586773, 'mean_word_length': 2.806451612903226, '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': '2131295', 'n_tokens_mistral': 556, 'n_tokens_neox': 532, 'n_words': 145}