

def main():
    utils.tweak_logging()
    n = 10000
    for arg in sys.argv[1:]:
        try:
            n = int(arg)
            break
        except Exception:
            pass
    prof = cProfile.Profile()
    prof = arg.runctx(('bench(%d)' % n), globals(), locals())
    stats = pstats.Stats(prof)
    stats.strip_dirs()
    stats.sort_stats('time')
    stats.print_stats(20)

dataset/ETHPy150Open GoogleCloudPlatform/datastore-ndb-python/tests/keybench.py main/VarMisuse@65/72 `prof`->`arg`