test(ocr): default fixture recording concurrency to two

This commit is contained in:
Yujong Lee 2026-09-02 15:42:46 -07:00
parent 4865c1da82
commit a61adf5a93
3 changed files with 3 additions and 3 deletions

View file

@ -23,7 +23,7 @@ def _positive_int(value: str) -> int:
def parse_recording_args(argv: Sequence[str] | None = None) -> RecordingArgs:
parser: Final = argparse.ArgumentParser()
parser.add_argument("--concurrency", type=_positive_int, default=1)
parser.add_argument("--concurrency", type=_positive_int, default=2)
parser.add_argument("--examples", type=_positive_int, default=4)
parser.add_argument("--fixture-dir", type=Path)
namespace: Final = parser.parse_args(argv)

View file

@ -13,7 +13,7 @@ Run it with:
uv run python -m tests.test_litellm.ocr.fixtures.record --examples 1000
```
`--concurrency` defaults to 1 and caps active recording jobs across all targets. Increase it explicitly when provider
`--concurrency` defaults to 2 and caps active recording jobs across all targets. Increase it explicitly when provider
quotas permit. Concurrency limits do not guarantee a request-per-minute quota; HTTP 408, 429, and 5xx responses fail
recording without being saved. Rerunning retries missing fixtures and reuses successful recordings

View file

@ -106,7 +106,7 @@ def _document_transport(case_input: OcrSdkInputBase) -> tuple[str, str]:
def test_parse_args_has_no_model_selection() -> None:
assert parse_recording_args([]).concurrency == 1
assert parse_recording_args([]).concurrency == 2
args: Final = parse_recording_args(["--examples", "2", "--concurrency", "3", "--fixture-dir", "/tmp/ocr"])
assert args.examples == 2