Пример #1
0
 def test_extension_wrapper(self):
     pykd.loadDump(TEST_DUMP)
     b_l = 0
     with Extension_Wrapper(ADRENO_EXT) as ew:
         str = ew.call_function("evtlog")
         b_l = len(str)
     self.assertNotEqual(b_l, 0)
Пример #2
0
 def test_generate_html_table_from_dict(self):
     pykd.loadDump(TEST_DUMP)
     alon_dict = always_on_worker()
     log_loc = generate_timestamp_folder()
     generate_html_table_from_dict(alon_dict, log_loc)
     log_loc = generate_timestamp_folder(r'c:\temp\test', 'event_log')
     generate_html_table_from_dict(alon_dict, log_loc)
     self.assertEqual('','')
Пример #3
0
 def test_adreno_worker(self):
     pykd.loadDump(TEST_DUMP)
     adreno_dict = adreno_worker()
     self.assertNotEqual(adreno_dict, None)
Пример #4
0
 def test_always_on_worker(self):
     pykd.loadDump(TEST_DUMP)
     alon_dict = always_on_worker()
     self.assertNotEqual(alon_dict, None)
def init_debugging():
    loadDump(sys.argv[1])
    load_extensions()
    init_symbols()
Пример #6
0
</html>
"""

LOGGER_DICT = {
        'adreno' : adreno_worker,
        'always on' :  always_on_worker
    }

_NT_SYMBOL_PATH = '''CACHE*C:\symbols;SRV*\\wpsymbol01\symbol01;
                    SRV*\\wpsymbol01\symbol02;SRV*\\wpsymbol01\symbol03;
                    SRV*\\wpsymbol01\symbol04;SRV*\\wpsymbol01\symbol05;
                    SRV*http://msdl.microsoft.com/download/symbols'''

WINDBG_SESSION_TIME_FORMAT = r'%b  %d %H:%M:%S.%f %Y' 


if __name__ == "__main__":
    try:
        # setup symbol path
        os.environ["_NT_SYMBOL_PATH"] = _NT_SYMBOL_PATH
        lr_args = Log_Reducer_Args()
        lr_args.dbg_args_parser(parser.parse_args())
        if lr_args._dump_path:
            pykd.loadDump(lr_args._dump_path)
        log_output_location = get_sorted_logs(*(lr_args._loggers), file_types=lr_args._file_types, storage_path = lr_args._storage_path)
        if os.path.isdir(log_output_location):
            import subprocess
            subprocess.Popen(r'explorer /select, {0}'.format(log_output_location))
    except Exception, err:
        pykd.dprintln('failure... %s\n' %str(err))