MCPcopy Create free account
hub / github.com/idank/explainshell / RecordingExecutor

Class RecordingExecutor

tests/extraction/test_runner.py:629–643  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

627 real_executor = concurrent.futures.ThreadPoolExecutor
628
629 class RecordingExecutor:
630 # Fresh class per test invocation, so this list is also fresh.
631 instances: list["RecordingExecutor"] = []
632
633 def __init__(self, max_workers: int) -> None:
634 self._executor = real_executor(max_workers=max_workers)
635 self.submit_count = 0
636 RecordingExecutor.instances.append(self)
637
638 def submit(self, fn, *args, **kwargs):
639 self.submit_count += 1
640 return self._executor.submit(fn, *args, **kwargs)
641
642 def shutdown(self, wait: bool = True, cancel_futures: bool = False) -> None:
643 self._executor.shutdown(wait=wait, cancel_futures=cancel_futures)
644
645 files = [
646 "/fake/a.1.gz",

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected